asp.net mvc - How to make an existing AngularJS SPA plugable to other projects -


i have angularjs app (myapp) used own asp.net mvc app. angularjs working in app. other mvc apps want add-on (plugin). possible without modifying original angularjs app, , been intrusive other apps?

i thought this:

  1. distribute myapp.js in-house cdn included bundleconfig.cs other apps
  2. add <div data-ng-app="myapp"> in pages of other apps original angularjs can injected.

far many unknowns how app configured precise answer module can dependency injected module.

for simplicity sake assume have templates needed run app converted javascript strings , use $templatecache() register them , code app in 1 file able inject module theirs , use whatever components have available.

all need script tag points @ location app file ... , location server, cdn or local download directory


Comments

Popular posts from this blog

how to insert data php javascript mysql with multiple array session 2 -

multithreading - Exception in Application constructor -

windows - CertCreateCertificateContext returns CRYPT_E_ASN1_BADTAG / 8009310b -