- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can see my consolelog entries from init.apps.js. Please what is the correct way to modify index_user_scripts.js so I may write to consolelog.
- Tags:
- HTML5
- Intel® XDK
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
use
console.log("hello world");
or sometimes easier/quicker
alert("hello world");
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I think the way it's supposed to work is to set app.LOG to 'true' if you want to see logs from app.consoleLog(), and set it to 'false' if you don't. You can change this anywhere in your code to go back and forth between the two choices. To be safest, you might want to refer to it as window.app.LOG, and then log things with window.app.consoleLog().
app.consoleLog should act just like console.log, except that it will be a no-op if app.LOG is not 'true'.
Does that help?
Dale
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page