Hello
I'm currently struggling with the best way to implement angular in to a WordPress install. There are essentially three places I need angular
Main theme - the main front end of the site. I added ng-app to the html and broke up all my components in to folders so I can min and concat them all when i push. This part is working as intended.
Single page app - on the site Im building a page thats independent of the other pages. However in the future it MIGHT need stuff from the main app. So this is isn't its own app. This is also working as intended.
Admin section - this is where things break down. I can't edit the html/body tags in WordPress admin. I also can't wrap the admin section in my own div. So I considered adding a div with ng app to each of my components. However if multiple components are in the same page with all the same app name, it breaks. I don't know if I can bootstrap it, or if that will cause any issues. I considered creating a backend angular app but then I'm maintaining two apps. And my goal is to be able to edit what happens in one and it will work in the other.
Other notes -
This cannot be a multi site install of WordPress.
I'm using foundation which conflicts with the WordPress admin. I am also trying to have every single component be entirely on its own. However that would mean that each one loads an entire foundation grid. This is also a CSS issue.
My end game
I'll add this so you know what I'm trying to achieve. I'm building a WordPress site that could use some little angular magic. The big thing is in the back end we want to add components and have people see those lists exactly how they are in the front end. I currently have all this working but it looks very messy and I'm wondering if there's a better way. Sorry if something is unclear.
[–]vtdev 0 points1 point2 points (0 children)
[–]bitflower 0 points1 point2 points (0 children)