I've created a provider hosted-app for SharePoint and I've added a Web Part into the App to be able to view my app from the SharePoint host web.
In the app web of the project, I've included various javascript libraries :
- jQuery
- Angular and ngRoute
- Trackpad scrol emulator and Isotope.js.
- and Isotope.js
I deploy the app, and I place the web part into a SharePoint page. I can see my app working like a charm.
Now, if I refresh the page or I navigate and come back to see my web part, the library Isotope.js isn't loaded anymore (like it were kept in cache) but my app doesn't work anymore.
I found out that if I clear the cache of the browser, I can make it works normally.
I also found a good post about this here
but my scripts are not hosted on the host web but into the App web.
My questions is : why the others js libraries still working and not Isotope ? Besides the knowledge of this library, it should be the same for each js file of my app... Moreover, I disabled the MDS (Minimal Download Strategy) so pages are not kept in cache.
Thank you for any tips, we never stop to learn things on SP.
EDIT : When I debug the init of isotope with the Web browser toolkit JS debugger, it will WORK!! but not in normal execution. Is this need a delay to load something ...mh ...