/** * @license * Copyright 2021 Google LLC * SPDX-License-Identifier: Apache-2.0 */ /** * @fileoverview Load this file in a '); // Load dependency graph info from build/deps.js. To update // deps.js, run `npm run build:deps`. document.write(''); // Msg loading kludge. This should go away once #5409 and/or // #1895 are fixed. // Load messages into a temporary Blockly.Msg object, deleting it // afterwards (after saving the messages!) window.Blockly = {Msg: Object.create(null)}; document.write(''); document.write(` `); document.write(` `); } else { // The below code is necessary for a few reasons: // - We need an absolute path instead of relative path because the // advanced_playground the and regular playground are in different folders. // - We need to get the root directory for blockly because it is // different for github.io, appspot and local. const files = [ 'blockly_compressed.js', 'msg/messages.js', 'blocks_compressed.js', 'dart_compressed.js', 'javascript_compressed.js', 'lua_compressed.js', 'php_compressed.js', 'python_compressed.js', ]; // We need to load Blockly in compiled mode. const hostName = window.location.host.replaceAll('.', '\\.'); const matches = new RegExp(hostName + '\\/(.*)tests').exec(window.location.href); const root = matches && matches[1] ? matches[1] : ''; // Load blockly_compressed.js et al. using '); } } })();