This commit is contained in:
Caleb James DeLisle
2017-08-09 17:37:55 +02:00
parent e49a42db18
commit c304071492
9 changed files with 359 additions and 239 deletions

View File

@@ -1,11 +1,8 @@
// This is stage 1, it can be changed but you must bump the version of the project.
// Note: This must only be loaded from inside of a sandbox-iframe.
define([
'/common/requireconfig.js',
'/common/sframe-channel.js'
], function (RequireConfig, SFrameChannel) {
define(['/common/requireconfig.js'], function (RequireConfig) {
require.config(RequireConfig);
console.log('boot2');
// most of CryptPad breaks if you don't support isArray
if (!Array.isArray) {
Array.isArray = function(arg) { // CRYPTPAD_SHIM
@@ -23,7 +20,5 @@ console.log('boot2');
window.__defineGetter__('localStorage', function () { return mkFakeStore(); });
window.__defineGetter__('sessionStorage', function () { return mkFakeStore(); });
SFrameChannel.init(window.top, function () { });
require([document.querySelector('script[data-bootload]').getAttribute('data-bootload')]);
});