[英]AngularJS - Dynamically adding views along with their routes and controllers
I am building an application where I'll be getting JSON file containing content. 我正在构建一个应用程序,将在其中获取包含内容的JSON文件。 From that JSON, I will create a view(html), bind it to a controller and route that are to be created when I receive the JSON.
从该JSON,我将创建一个view(html),将其绑定到控制器,并路由接收到JSON时要创建的控制器。 It will be a list of items where each item leads to a different view, controller and route.
这将是一个项目列表,其中每个项目都导致不同的视图,控制器和路线。
I need help in implementing this dynamic behavior in the application. 我需要在应用程序中实现这种动态行为的帮助。
Much appreciated! 非常感激!
EDIT: 编辑:
I forgot to mention that this is to be implemented in an Ionic Application 我忘了提到这将在离子应用程序中实现
Just a quick thought... 只是想了一下...
XMLHttpRequest
XMLHttpRequest
调用JSON angular.bootstrap
More angular.bootstrap
更多
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.