- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We use require.js to manage javascript code modules, and we are no longer able to use the XDK in Simulate mode. The simulate feature uses a javascript file called app-host.js which implements its own 'require' object that lives in the global namespace. As a result, any calls to require.js will fail.
- Tags:
- HTML5
- Intel® XDK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for reporting this. We are working on releasing a hotfix soon that includes the fix for this issue. But in the meantime, as a workaround you can do the following in your current installation of Intel XDK to patch it and continue working:
1 - Make sure that the XDK is closed, and open the file components/server/simulator/cordova-simulate/src/server/sim-files.js in an editor. According to your operating system, you can find that file in the following path:
- MAC: /Applications/Intel XDK.app/Contents/Resources/app.nw/
- Windows: C:\Users\<your-user>\AppData\Local\Intel\XDK\xdk\
- Linux:
- Installed as root: /opt/intel/XDK/xdk/
- Installed as user: ~/intel/XDK/xdk/
2 - Replace the line 142, that looks like this,
var b = browserify({ paths: getBrowserifySearchPaths(hostType), debug: false });
with the following snippet:
var b = browserify({ paths: getBrowserifySearchPaths(hostType), debug: false, exports: false, // needed to prevent browserify to override hasExports option by set it to true hasExports: false });
3 - Save the changes, and start the XDK.
This should fix the issue. Please, let us know if you have any trouble on patching it, and if it works for you.
Thanks.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the feedback, I'll let the appropriate engineer know.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for reporting this. We are working on releasing a hotfix soon that includes the fix for this issue. But in the meantime, as a workaround you can do the following in your current installation of Intel XDK to patch it and continue working:
1 - Make sure that the XDK is closed, and open the file components/server/simulator/cordova-simulate/src/server/sim-files.js in an editor. According to your operating system, you can find that file in the following path:
- MAC: /Applications/Intel XDK.app/Contents/Resources/app.nw/
- Windows: C:\Users\<your-user>\AppData\Local\Intel\XDK\xdk\
- Linux:
- Installed as root: /opt/intel/XDK/xdk/
- Installed as user: ~/intel/XDK/xdk/
2 - Replace the line 142, that looks like this,
var b = browserify({ paths: getBrowserifySearchPaths(hostType), debug: false });
with the following snippet:
var b = browserify({ paths: getBrowserifySearchPaths(hostType), debug: false, exports: false, // needed to prevent browserify to override hasExports option by set it to true hasExports: false });
3 - Save the changes, and start the XDK.
This should fix the issue. Please, let us know if you have any trouble on patching it, and if it works for you.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Confirmed. This patch worked perfectly. Many thanks.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page