json.worker.js 628 B

123456789101112
  1. /*---------------------------------------------------------------------------------------------
  2. * Copyright (c) Microsoft Corporation. All rights reserved.
  3. * Licensed under the MIT License. See License.txt in the project root for license information.
  4. *--------------------------------------------------------------------------------------------*/
  5. import * as worker from '../../editor/editor.worker.js';
  6. import { JSONWorker } from './jsonWorker.js';
  7. self.onmessage = function () {
  8. // ignore the first message
  9. worker.initialize(function (ctx, createData) {
  10. return new JSONWorker(ctx, createData);
  11. });
  12. };