-
11 Dec 2012 9:09 AM #1
Unanswered: Warning on Mobile browser but not in Desktop browser
Unanswered: Warning on Mobile browser but not in Desktop browser
Using remote debugging in chrome was testing a sencha touch mvc application in android mobile.
When application loads in the desktop browser there was no warning in the developer tool's console. But when same app was loaded in the the mobile browser it logs many warnings such as provided below
the main reason why i was bothered by this warning is a doubt as objects are created multiple times in mobile device which must not happen. to remove the warning i can remove the ID and provide itemId, but that will hide the warnings but will not control the duplicate object creations .Code:[WARN][Ext.Component#constructor] Registering a component with a id (`viewport`) which has already been used. Please ensure the existing component has been destroyed (`Ext.Component#destroy()`.
Is my doubt is correct or ignore the warning
-
13 Dec 2012 5:52 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,641
- Vote Rating
- 434
- Answers
- 3107
You are using the id config (which I would recommend against) and you are using the same one twice. You need to make sure all instances have unique ids which is why I would just let the framework do.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
13 Dec 2012 6:17 AM #3
Thanks mitchellsimoens,
The problem is there is only one element, but it is some how initiated twice. Most of the view are being loaded twice but cant able to find out the reason. But cant understand why this happening only in mobile browser but not in desktop browser.
Is there any way to find this bug in the code?


Reply With Quote