-
Notifications
You must be signed in to change notification settings - Fork 467
Update doesn't reload changed files correctly #2
Comments
Hi. I'll look into your test project, thanks. Right now I have created empty Ionic project as in documentation, and it worked fine: both css and html files are updated. Later will add it as an example to this repo. But maybe for more complicated examples it doesn't work properly (with side navigation). Will test it. |
Ok, got it. If i run Now the problem is, that I just can run the function with a button after the update. Because your |
Hi. Well, your solution can help, but this didn't work for android (in Cordova), because if then you will press on back button - you will return to the old page, which is wrong. So instead, it reloads the page on the native side. Why it doesn't work for you- don't know yet. I'm few days off, will continue with Ionic support on Wednesday. Will see how it will go. But thanks for your tip :) |
Done some testing, and it seems that this is a caching issue: UIWebView caches css files, and simple refresh doesn't help. If you, for example, force kill the app and launch it - cache is cleaned and everything is fine. Or if you add version number in the css file path like so: <link href="css/style.css?ver=1" rel="stylesheet"> But those are all hacks. The existing refresh way works, but not always. Found another solution, but need to test it more. This is an iOS only issue, work's fine on Android. |
Should be fixed with the next release |
First of all, thanks for making this plugin.. |
@kittugit thanks. Did you use version from npm, or from master branch on github? If from npm - then yes, it is a caching problem on iOS. Should be fixed, if you use version from github. Didn't release new stable version yet. |
Hi, everything seems to work fine. It finds the changed files, downloads it. I also can see, how the app get's reloaded, but the css changes doesn't appear.
I use Ionic and did follow the ionic guide in your readme. Because I have almost no idea about Objective-c and xCode i also don't have an idea on how to debug this thing.
I forked your project and added a folder
example/ionic
which you maybe can test, if you don't already have one seted up.In this example i did not build any chcp files.
Can it be that it does save the downloaded files on the wrong location, and because of that it still loads the old style.css file?
The text was updated successfully, but these errors were encountered: