Opened 6 years ago

Closed 4 years ago

#17541 closed defect (invalid)

Unable to use DOJO in Chrome Packaged Apps

Reported by: lbus Owned by:
Priority: undecided Milestone: tbd
Component: General Version: 1.9.1
Keywords: Cc:
Blocked By: Blocking:

Description

There is currently no known way how to run DOJO apps as Chrome Packaged Apps.

1) Running DOJO app in the background page is not possible due to unsafe evals. Google guys propose to run the application in an iframe sandbox.

2) Running DOJO app in a sandboxed iframe also does not work due to following error:

OPTIONS chrome-extension://mbacficfpdhfhkfgamoopinojpfnidhn/dijit/form/templates/Button.html Origin null is not allowed by Access-Control-Allow-Origin. xhr.js:206
xhr xhr.js:206
getText text.js:8
load text.js:200
injectPlugin dojo.js:1321
(anonymous function) dojo.js:1136
forEach dojo.js:93
resolvePluginLoadQ dojo.js:1129
finishExec dojo.js:1170
execModule dojo.js:1233
(anonymous function) dojo.js:1267
guardCheckComplete dojo.js:1247
checkComplete dojo.js:1262
onLoadCallback dojo.js:1428
onLoad dojo.js:1677

XMLHttpRequest cannot load chrome-extension://mbacficfpdhfhkfgamoopinojpfnidhn/dijit/form/templates/Button.html. Origin null is not allowed by Access-Control-Allow-Origin.

I attach a simple test creating a button in a sandboxed frame.

Please investigate the issue and create a short howto for Google Chrome Apps with Dojo.

Attachments (1)

test_dojo_chrome_sandbox.zip (8.3 KB) - added by lbus 6 years ago.
Test of using Dojo in sandboxed iframe in a Chrome Packaged App

Download all attachments as: .zip

Change History (3)

Changed 6 years ago by lbus

Test of using Dojo in sandboxed iframe in a Chrome Packaged App

comment:1 Changed 5 years ago by lbus

We succeeded to handle CSP issues and run DOJO app as Chrome Packaged App, see https://chrome.google.com/webstore/detail/reqview-desktop/cmbnhmeabefpflildnahpbghcejkblin. So I propose to close this issue. Maybe we can sketch a short tutorial how to do it.

comment:2 Changed 4 years ago by ben hockey

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.