view src/bootstrap-feature-extraction-worker.js @ 310:103cc6f63da1

The existence of a window object was screwing up something a recent update in RxJs introduced where it figures out what environment it is in. This is so brittle.
author Lucas Thompson <dev@lucas.im>
date Fri, 12 May 2017 16:48:51 +0100
parents 8f2b2aed0df1
children
line wrap: on
line source
/**
 * Created by lucas on 01/12/2016.
 */
let window = {};
importScripts('/inline.bundle.js'); // provides webpackJsonp
const webpackJsonp = window['webpackJsonp'];
importScripts('/scripts.bundle.js'); // needs webpackJsonp, hence above - provides RequireJS
window = null; // now we have a reference to webpackJsonp, get rid of window
importScripts('/polyfills.bundle.js'); // provides the compiled FeatureExtractionWorker

new (require('feature-extraction-worker'))(self, requirejs);