bug: Error: ATTempted to assign to readonly property on ion-slide
Type: bug
Platform: ios 8 webview
i have this error. it fire on ios simulator and real device.
Error: Attempted to assign to readonly property.
ChildScope@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:22509:23
$new@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:22517:40
boundTranscludeFn@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:15919:40
controllersBoundTransclude@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:16583:35
ngRepeatAction@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:33329:26
$watchCollectionAction@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:22937:21
$digest@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:23070:31
$apply@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:23333:31
http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:25059:42
completeOutstandingRequest@http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:13732:15
http://10.5.44.212:8100/lib/ionic/js/ionic.bundle.js:14112:33
my ionic version is 1.0.1
this error appear when i have a ion-slide with more than one image and i switch between views (with cache: false). It appear randomly. it's not a blocking error but somethink crash view app. not solution jet need help!
Same thing here. It's ionic-slide with ng-repeats inside of it that seems to causes this. I also have view caching turned off.
ok i found the solution. It's a safari mobile bug related to angularJs. To solve it we need to rewrite all code like this:
object.$$a = 5;
to this:
var __webkitAssign__$$a = '$$a';
object[__webkitAssign__$$a] = 5;
The npm repo has a fantastic utility that help us.
https://www.npmjs.com/package/webkit-assign It rewrite the ionic bundle for safari bug and IT WORK PERFECT!.
Thanks that worked.
yeaaaa!
Is this still an issue with angular 1.4?
@mhartington I just encountered this issue and I updated to Ionic 1.1.0 with Angular 1.4 to see if it would fix the problem but it still persists on iOS8.4 iPhone 6 sim.
So this is an issue still? Could you provide a codepen to test against?
problem is here in ionic 1.1 and angular 1.4.*, patched as above in my post and it worked.
I am able to webkit-assign ionic bundle and it works just fine, but I am not able to get it to work with the minified version of ionic bundle. I get angular not defined.. @mrtomrichy , @gimox , any ideas?
follow this guide:
- http://blog.ionic.io/minifying-your-source-code/
- https://www.airpair.com/ionic-framework/posts/production-ready-apps-with-ionic-framework
you need some trick to minify angular.
ty @gimox
thanks a lot @gimox. Your solution solved my problem as well. I am using ionic 1.1.1 and 1.0.0-rc.05 and angular 1.2.28
Hello! Is this still an issue with the latest version of ionic?
Hello! Thanks for opening an issue with us! Since it has been a little while since there was any activity on this issue i will be closing it, but feel free to respond back if your still having the issue! Thanks again!
+1 still getting this on iOS v8 with Ionic 1.4.9