зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1434025 - Update Debugger Frontend v12. r=jdescottes
MozReview-Commit-ID: H7ti3ZopbZC --HG-- rename : devtools/client/debugger/new/test/mochitest/examples/reload/doc_reload.html => devtools/client/debugger/new/test/mochitest/examples/reload/doc-reload.html extra : rebase_source : 2c79781fa31664ccc793b14c097411d12335f6dc
This commit is contained in:
Родитель
ffc69d5c96
Коммит
ae8b90234b
|
@ -1,9 +1,9 @@
|
|||
This is the debugger.html project output.
|
||||
See https://github.com/devtools-html/debugger.html
|
||||
|
||||
Version v11.0
|
||||
Comparison: https://github.com/devtools-html/debugger.html/compare/release-10...release-11
|
||||
Commit: https://github.com/devtools-html/debugger.html/commit/4ef9b879ef7b51430e4acdadfd24a8d7e9f64c82
|
||||
Version 12.0
|
||||
Comparison: https://github.com/devtools-html/debugger.html/compare/release-11...release-12
|
||||
Commit: https://github.com/devtools-html/debugger.html/commit/5f7ecfe
|
||||
|
||||
Packages:
|
||||
- babel-plugin-transform-es2015-modules-commonjs @6.26.0
|
||||
|
|
|
@ -1122,6 +1122,95 @@ html[dir="rtl"] .managed-tree .tree .node > div {
|
|||
.managed-tree .tree-node button {
|
||||
position: fixed;
|
||||
}
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
.tree {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.tree.inline {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.tree.nowrap {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.tree.noselect {
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.tree button {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.tree .tree-node {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.tree .tree-node:not(.focused):hover {
|
||||
background-color: var(--theme-selection-background-hover);
|
||||
}
|
||||
|
||||
.tree-indent {
|
||||
display: inline-block;
|
||||
width: 12px;
|
||||
margin-inline-start: 5px;
|
||||
border-inline-start: 1px solid #A2D1FF;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
/* Align with expandables siblings (where we have the arrow) */
|
||||
.tree-node[data-expandable="false"] .tree-indent:last-of-type {
|
||||
margin-inline-end: 15px;
|
||||
}
|
||||
|
||||
/* For non expandable root nodes, we don't have .tree-indent elements, so we declare
|
||||
the margin on the start of the node */
|
||||
.tree-node[data-expandable="false"][aria-level="0"] {
|
||||
padding-inline-start: 15px
|
||||
}
|
||||
|
||||
.tree .tree-node[data-expandable="true"] {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.tree .tree-node.focused {
|
||||
color: white;
|
||||
background-color: var(--theme-selection-background, #0a84ff);
|
||||
}
|
||||
|
||||
.tree-node.focused .arrow svg {
|
||||
fill: currentColor;
|
||||
}
|
||||
|
||||
.tree-node:hover img {
|
||||
background-color: var(--theme-content-color3);
|
||||
}
|
||||
|
||||
.arrow svg {
|
||||
fill: var(--theme-splitter-color, #9B9B9B);
|
||||
transition: transform 0.125s ease;
|
||||
width: 10px;
|
||||
margin-inline-end: 5px;
|
||||
transform: rotate(-90deg);
|
||||
}
|
||||
|
||||
html[dir="rtl"] .arrow svg,
|
||||
.arrow svg:dir(rtl),
|
||||
.arrow svg:-moz-locale-dir(rtl) {
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
|
||||
.arrow.expanded.expanded svg {
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at <http://mozilla.org/MPL/2.0/>. */
|
||||
|
@ -1409,6 +1498,10 @@ html[dir="rtl"] .managed-tree .tree .node > div {
|
|||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.sources-list .tree:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.sources-list .managed-tree {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
|
@ -2060,6 +2153,13 @@ html .toggle-button.end.vertical svg {
|
|||
color: var(--theme-body-color);
|
||||
}
|
||||
|
||||
/******************************************************************************/
|
||||
/* Length bubble for arraylikes and maplikes */
|
||||
|
||||
.objectLengthBubble {
|
||||
color: var(--null-color);
|
||||
}
|
||||
|
||||
/******************************************************************************/
|
||||
|
||||
.objectLeftBrace,
|
||||
|
@ -2070,7 +2170,7 @@ html .toggle-button.end.vertical svg {
|
|||
}
|
||||
|
||||
/******************************************************************************/
|
||||
/* Cycle reference*/
|
||||
/* Cycle reference */
|
||||
|
||||
.objectBox-Reference {
|
||||
font-weight: bold;
|
||||
|
@ -2149,91 +2249,6 @@ html .toggle-button.end.vertical svg {
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
.tree {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.tree.inline {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.tree.nowrap {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.tree.noselect {
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.tree button {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.tree .tree-node {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.tree-indent {
|
||||
display: inline-block;
|
||||
width: 12px;
|
||||
margin-inline-start: 5px;
|
||||
border-inline-start: 1px solid #A2D1FF;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
/* Align with expandables siblings (where we have the arrow) */
|
||||
.tree-node[data-expandable="false"] .tree-indent:last-of-type {
|
||||
margin-inline-end: 15px;
|
||||
}
|
||||
|
||||
/* For non expandable root nodes, we don't have .tree-indent elements, so we declare
|
||||
the margin on the start of the node */
|
||||
.tree-node[data-expandable="false"][aria-level="0"] {
|
||||
padding-inline-start: 15px
|
||||
}
|
||||
|
||||
.tree .tree-node[data-expandable="true"] {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.tree .tree-node:not(.focused):hover {
|
||||
background-color: #F0F9FE;
|
||||
}
|
||||
|
||||
.tree .tree-node.focused {
|
||||
color: white;
|
||||
background-color: var(--theme-selection-background, #0a84ff);
|
||||
}
|
||||
|
||||
.tree-node.focused .arrow svg {
|
||||
fill: currentColor;
|
||||
}
|
||||
|
||||
.arrow svg {
|
||||
fill: var(--theme-splitter-color, #9B9B9B);
|
||||
transition: transform 0.125s ease;
|
||||
width: 10px;
|
||||
margin-inline-end: 5px;
|
||||
transform: rotate(-90deg);
|
||||
}
|
||||
|
||||
html[dir="rtl"] .arrow svg,
|
||||
.arrow svg:dir(rtl),
|
||||
.arrow svg:-moz-locale-dir(rtl) {
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
|
||||
.arrow.expanded.expanded svg {
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
.tree.object-inspector .node.object-node {
|
||||
display: inline-block;
|
||||
}
|
||||
|
@ -3025,6 +3040,10 @@ html .breakpoints-list .breakpoint.paused {
|
|||
.expression-input {
|
||||
max-width: 50%;
|
||||
}
|
||||
|
||||
.expressions-list .tree:focus {
|
||||
outline: none;
|
||||
}
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at <http://mozilla.org/MPL/2.0/>. */
|
||||
|
@ -3614,6 +3633,10 @@ img.ignore-exceptions {
|
|||
padding-inline-start: 4px;
|
||||
}
|
||||
|
||||
.scopes-list .tree:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.scopes-list .function-signature {
|
||||
display: inline-block;
|
||||
}
|
||||
|
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -15,6 +15,14 @@ support-files =
|
|||
examples/sourcemaps3/bundle.js.map
|
||||
examples/sourcemaps3/sorted.js
|
||||
examples/sourcemaps3/test.js
|
||||
examples/sourcemaps-reload/v1.bundle.js
|
||||
examples/sourcemaps-reload/v1.bundle.js.map
|
||||
examples/sourcemaps-reload/v2.bundle.js
|
||||
examples/sourcemaps-reload/v2.bundle.js.map
|
||||
examples/sourcemaps-reload/v3.bundle.js
|
||||
examples/sourcemaps-reload/v3.bundle.js.map
|
||||
examples/sourcemaps-reload/doc-sourcemaps-reload.html
|
||||
examples/sourcemaps-reload/sjs_code_reload.sjs
|
||||
examples/wasm-sourcemaps/average.js
|
||||
examples/wasm-sourcemaps/average.wasm
|
||||
examples/wasm-sourcemaps/average.wasm.map
|
||||
|
@ -25,7 +33,8 @@ support-files =
|
|||
examples/sum/sum.min.js.map
|
||||
examples/reload/code_reload_1.js
|
||||
examples/reload/code_reload_2.js
|
||||
examples/reload/doc_reload.html
|
||||
examples/reload/doc-reload.html
|
||||
examples/reload/sjs_code_reload.sjs
|
||||
examples/doc-async.html
|
||||
examples/doc-asm.html
|
||||
examples/doc-content-script-sources.html
|
||||
|
@ -63,7 +72,6 @@ support-files =
|
|||
examples/script-switching-02.js
|
||||
examples/script-switching-01.js
|
||||
examples/times2.js
|
||||
examples/reload/sjs_code_reload.sjs
|
||||
|
||||
[browser_dbg-asm.js]
|
||||
[browser_dbg-async-stepping.js]
|
||||
|
@ -115,6 +123,7 @@ skip-if = os == "win" # Bug 1393121
|
|||
skip-if = true # regular failures during release in Bug 1415300
|
||||
[browser_dbg-search-project.js]
|
||||
[browser_dbg-sourcemaps.js]
|
||||
[browser_dbg-sourcemaps-reload.js]
|
||||
[browser_dbg-sourcemaps-reloading.js]
|
||||
[browser_dbg-sourcemaps2.js]
|
||||
[browser_dbg-sourcemaps3.js]
|
||||
|
|
|
@ -18,10 +18,11 @@ async function waitForBreakpoint(dbg, location) {
|
|||
}
|
||||
|
||||
add_task(async function() {
|
||||
const dbg = await initDebugger("reload/doc_reload.html", "sjs_code_reload");
|
||||
|
||||
const dbg = await initDebugger("reload/doc-reload.html");
|
||||
await waitForSource(dbg, "sjs_code_reload");
|
||||
await selectSource(dbg, "sjs_code_reload");
|
||||
await waitForSelectedSource(dbg, "sjs_code_reload");
|
||||
|
||||
await addBreakpoint(dbg, "sjs_code_reload", 2);
|
||||
|
||||
await reload(dbg, "sjs_code_reload");
|
||||
|
|
|
@ -0,0 +1,59 @@
|
|||
/* Any copyright is dedicated to the Public Domain.
|
||||
http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
/*
|
||||
* Test reloading:
|
||||
* 1. reload the source
|
||||
* 2. re-sync breakpoints
|
||||
*/
|
||||
|
||||
async function waitForBreakpoint(dbg, location) {
|
||||
return waitForState(
|
||||
dbg,
|
||||
state => {
|
||||
return dbg.selectors.getBreakpoint(dbg.getState(), location);
|
||||
},
|
||||
"Waiting for breakpoint"
|
||||
);
|
||||
}
|
||||
|
||||
function getBreakpoints(dbg) {
|
||||
const breakpoints = dbg.selectors.getBreakpoints(dbg.getState());
|
||||
return breakpoints.valueSeq().toJS();
|
||||
}
|
||||
|
||||
add_task(async function() {
|
||||
const dbg = await initDebugger("doc-minified.html");
|
||||
|
||||
await navigate(dbg, "sourcemaps-reload/doc-sourcemaps-reload.html", "v1");
|
||||
|
||||
await waitForSource(dbg, "v1");
|
||||
await selectSource(dbg, "v1");
|
||||
|
||||
await addBreakpoint(dbg, "v1", 6);
|
||||
let breakpoint = getBreakpoints(dbg)[0];
|
||||
is(breakpoint.location.line, 6);
|
||||
|
||||
let syncBp = waitForDispatch(dbg, "SYNC_BREAKPOINT");
|
||||
await reload(dbg);
|
||||
|
||||
await waitForPaused(dbg);
|
||||
await syncBp;
|
||||
assertDebugLine(dbg, 72);
|
||||
breakpoint = getBreakpoints(dbg)[0];
|
||||
|
||||
is(breakpoint.location.line, 9);
|
||||
is(breakpoint.generatedLocation.line, 73);
|
||||
|
||||
await resume(dbg);
|
||||
syncBp = waitForDispatch(dbg, "SYNC_BREAKPOINT", 2);
|
||||
await selectSource(dbg, "v1");
|
||||
await addBreakpoint(dbg, "v1", 13);
|
||||
|
||||
await reload(dbg);
|
||||
await waitForSource(dbg, "v1");
|
||||
await syncBp;
|
||||
await waitForSelectedSource(dbg, "v1");
|
||||
|
||||
is(getBreakpoints(dbg).length, 0, "No breakpoints");
|
||||
});
|
|
@ -1,6 +1,10 @@
|
|||
/* Any copyright is dedicated to the Public Domain.
|
||||
* http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
async function waitForBreakpointCount(dbg, count) {
|
||||
return waitForState(dbg, state => dbg.selectors.getBreakpoints(state).size === count)
|
||||
}
|
||||
|
||||
add_task(async function() {
|
||||
// NOTE: the CORS call makes the test run times inconsistent
|
||||
requestLongerTimeout(2);
|
||||
|
@ -22,12 +26,14 @@ add_task(async function() {
|
|||
// should not move anywhere.
|
||||
await addBreakpoint(dbg, entrySrc, 13);
|
||||
is(getBreakpoints(getState()).size, 1, "One breakpoint exists");
|
||||
|
||||
ok(
|
||||
getBreakpoint(getState(), { sourceId: entrySrc.id, line: 13 }),
|
||||
"Breakpoint has correct line"
|
||||
);
|
||||
|
||||
await addBreakpoint(dbg, entrySrc, 5);
|
||||
|
||||
await addBreakpoint(dbg, entrySrc, 15);
|
||||
await disableBreakpoint(dbg, entrySrc, 15);
|
||||
|
||||
|
@ -38,6 +44,7 @@ add_task(async function() {
|
|||
await waitForPaused(dbg);
|
||||
assertPausedLocation(dbg);
|
||||
|
||||
await waitForBreakpointCount(dbg, 3);
|
||||
is(getBreakpoints(getState()).size, 3, "Three breakpoints exist");
|
||||
|
||||
ok(
|
||||
|
|
|
@ -12,7 +12,9 @@ async function waitForSourceCount(dbg, i) {
|
|||
}
|
||||
|
||||
function getLabel(dbg, index) {
|
||||
return findElement(dbg, "sourceNode", index).textContent.trim();
|
||||
return findElement(dbg, "sourceNode", index)
|
||||
.textContent.trim()
|
||||
.replace(/^[\s\u200b]*/g, "");
|
||||
}
|
||||
|
||||
add_task(async function() {
|
||||
|
@ -27,5 +29,5 @@ add_task(async function() {
|
|||
|
||||
await waitForSourceCount(dbg, 3);
|
||||
|
||||
is(getLabel(dbg, 3), "evaled.js", "the eval script exists");
|
||||
is(getLabel(dbg, 3), "evaled.js", "evaled exists");
|
||||
});
|
||||
|
|
|
@ -17,7 +17,9 @@ async function assertSourceCount(dbg, count) {
|
|||
}
|
||||
|
||||
function getLabel(dbg, index) {
|
||||
return findElement(dbg, "sourceNode", index).textContent.trim();
|
||||
return findElement(dbg, "sourceNode", index)
|
||||
.textContent.trim()
|
||||
.replace(/^[\s\u200b]*/g, "");
|
||||
}
|
||||
|
||||
add_task(async function() {
|
||||
|
@ -62,5 +64,9 @@ add_task(async function() {
|
|||
});
|
||||
|
||||
await waitForSourceCount(dbg, 9);
|
||||
is(getLabel(dbg, 7), "math.min.js", "The dynamic script exists");
|
||||
is(
|
||||
getLabel(dbg, 7),
|
||||
"math.min.js",
|
||||
"math.min.js - The dynamic script exists"
|
||||
);
|
||||
});
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"plugins": ["transform-async-to-generator"]
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
### Steps to Rebuild
|
||||
|
||||
1. make changes to v1.js, v2.js, v3.js
|
||||
2. run `yarn` to install webpack & babel
|
||||
3. run `webpack`
|
||||
4. change `sources` reference in `v2.bundle.js.map` to `v1.js`
|
||||
5. change `sources` reference in `v3.bundle.js.map` to `v1.js`
|
|
@ -0,0 +1,15 @@
|
|||
<!-- Any copyright is dedicated to the Public Domain.
|
||||
http://creativecommons.org/publicdomain/zero/1.0/ -->
|
||||
<!doctype html>
|
||||
|
||||
<html>
|
||||
<script src="sjs_code_reload.sjs?foo"></script>
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<title>Empty test page 1</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
</body>
|
||||
|
||||
</html>
|
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
"name": "sourcemaps-reload",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "sorted.js",
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"keywords": [],
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"dependencies": {},
|
||||
"devDependencies": {
|
||||
"babel-core": "^6.26.0",
|
||||
"babel-loader": "^7.1.2",
|
||||
"babel-preset-es2015": "^6.24.1",
|
||||
"webpack": "^3.7.1"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,36 @@
|
|||
/* Any copyright is dedicated to the Public Domain.
|
||||
* http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
/* globals getState, setState */
|
||||
/* exported handleRequest */
|
||||
|
||||
"use strict";
|
||||
|
||||
const NUM_FILES = 3;
|
||||
|
||||
function _getUrl(request, counter) {
|
||||
const { scheme, host, path } = request;
|
||||
|
||||
const index = Math.ceil(counter / 2);
|
||||
const showMap = false ;//(counter % 2) === 1
|
||||
const newPath = path.substr(0, path.lastIndexOf("/") + 1);
|
||||
const url = `${scheme}://${host}${newPath}/v${index}.bundle.js${showMap ? '.map' : ''}`;
|
||||
return url
|
||||
}
|
||||
|
||||
function handleRequest(request, response) {
|
||||
response.setHeader("Cache-Control", "no-cache, no-store, must-revalidate");
|
||||
response.setHeader("Pragma", "no-cache");
|
||||
response.setHeader("Expires", "0");
|
||||
response.setHeader("Access-Control-Allow-Origin", "*", false);
|
||||
response.setHeader("Content-Type", "text/javascript", false);
|
||||
|
||||
// Redirect to a different file each time.
|
||||
let counter = (+getState("counter") || 1) % ( 2 * NUM_FILES + 1);
|
||||
|
||||
const newUrl = _getUrl(request, counter);
|
||||
|
||||
response.setStatusLine(request.httpVersion, 302, "Found");
|
||||
response.setHeader("Location", newUrl);
|
||||
setState("counter", "" + ++counter);
|
||||
}
|
|
@ -0,0 +1,89 @@
|
|||
/******/ (function(modules) { // webpackBootstrap
|
||||
/******/ // The module cache
|
||||
/******/ var installedModules = {};
|
||||
/******/
|
||||
/******/ // The require function
|
||||
/******/ function __webpack_require__(moduleId) {
|
||||
/******/
|
||||
/******/ // Check if module is in cache
|
||||
/******/ if(installedModules[moduleId]) {
|
||||
/******/ return installedModules[moduleId].exports;
|
||||
/******/ }
|
||||
/******/ // Create a new module (and put it into the cache)
|
||||
/******/ var module = installedModules[moduleId] = {
|
||||
/******/ i: moduleId,
|
||||
/******/ l: false,
|
||||
/******/ exports: {}
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // Execute the module function
|
||||
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
||||
/******/
|
||||
/******/ // Flag the module as loaded
|
||||
/******/ module.l = true;
|
||||
/******/
|
||||
/******/ // Return the exports of the module
|
||||
/******/ return module.exports;
|
||||
/******/ }
|
||||
/******/
|
||||
/******/
|
||||
/******/ // expose the modules object (__webpack_modules__)
|
||||
/******/ __webpack_require__.m = modules;
|
||||
/******/
|
||||
/******/ // expose the module cache
|
||||
/******/ __webpack_require__.c = installedModules;
|
||||
/******/
|
||||
/******/ // define getter function for harmony exports
|
||||
/******/ __webpack_require__.d = function(exports, name, getter) {
|
||||
/******/ if(!__webpack_require__.o(exports, name)) {
|
||||
/******/ Object.defineProperty(exports, name, {
|
||||
/******/ configurable: false,
|
||||
/******/ enumerable: true,
|
||||
/******/ get: getter
|
||||
/******/ });
|
||||
/******/ }
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
||||
/******/ __webpack_require__.n = function(module) {
|
||||
/******/ var getter = module && module.__esModule ?
|
||||
/******/ function getDefault() { return module['default']; } :
|
||||
/******/ function getModuleExports() { return module; };
|
||||
/******/ __webpack_require__.d(getter, 'a', getter);
|
||||
/******/ return getter;
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // Object.prototype.hasOwnProperty.call
|
||||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
/******/ })
|
||||
/************************************************************************/
|
||||
/******/ ([
|
||||
/* 0 */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
let foo = (() => {
|
||||
var _ref = _asyncToGenerator(function* () {
|
||||
yield bar();
|
||||
console.log("YO");
|
||||
});
|
||||
|
||||
return function foo() {
|
||||
return _ref.apply(this, arguments);
|
||||
};
|
||||
})();
|
||||
|
||||
function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; }
|
||||
|
||||
function bar() {
|
||||
return new Promise(resolve => setTimeout(resolve, 100));
|
||||
}
|
||||
|
||||
/***/ })
|
||||
/******/ ]);
|
||||
//# sourceMappingURL=v1.bundle.js.map
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"sources":["webpack:///webpack/bootstrap 8bcf0d04c821a99f6859","webpack:///./v1.js"],"names":["bar","console","log","foo","Promise","resolve","setTimeout"],"mappings":";AAAA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,mCAA2B,0BAA0B,EAAE;AACvD,yCAAiC,eAAe;AAChD;AACA;AACA;;AAEA;AACA,8DAAsD,+DAA+D;;AAErH;AACA;;AAEA;AACA;;;;;;;;+BCzDA,aAAqB;AACnB,UAAMA,KAAN;AACAC,YAAQC,GAAR,CAAY,IAAZ;AACD,G;;kBAHcC,G;;;;;;;AAJf,SAASH,GAAT,GAAe;AACb,SAAO,IAAII,OAAJ,CAAYC,WAAWC,WAAWD,OAAX,EAAoB,GAApB,CAAvB,CAAP;AACD,C","file":"v1.bundle.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 0);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 8bcf0d04c821a99f6859","function bar() {\n return new Promise(resolve => setTimeout(resolve, 100))\n}\n\nasync function foo() {\n await bar();\n console.log(\"YO\")\n}\n\n\n\n// WEBPACK FOOTER //\n// ./v1.js"],"sourceRoot":""}
|
|
@ -0,0 +1,8 @@
|
|||
function bar() {
|
||||
return new Promise(resolve => setTimeout(resolve, 100))
|
||||
}
|
||||
|
||||
async function foo() {
|
||||
await bar();
|
||||
console.log("YO")
|
||||
}
|
|
@ -0,0 +1,92 @@
|
|||
/******/ (function(modules) { // webpackBootstrap
|
||||
/******/ // The module cache
|
||||
/******/ var installedModules = {};
|
||||
/******/
|
||||
/******/ // The require function
|
||||
/******/ function __webpack_require__(moduleId) {
|
||||
/******/
|
||||
/******/ // Check if module is in cache
|
||||
/******/ if(installedModules[moduleId]) {
|
||||
/******/ return installedModules[moduleId].exports;
|
||||
/******/ }
|
||||
/******/ // Create a new module (and put it into the cache)
|
||||
/******/ var module = installedModules[moduleId] = {
|
||||
/******/ i: moduleId,
|
||||
/******/ l: false,
|
||||
/******/ exports: {}
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // Execute the module function
|
||||
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
||||
/******/
|
||||
/******/ // Flag the module as loaded
|
||||
/******/ module.l = true;
|
||||
/******/
|
||||
/******/ // Return the exports of the module
|
||||
/******/ return module.exports;
|
||||
/******/ }
|
||||
/******/
|
||||
/******/
|
||||
/******/ // expose the modules object (__webpack_modules__)
|
||||
/******/ __webpack_require__.m = modules;
|
||||
/******/
|
||||
/******/ // expose the module cache
|
||||
/******/ __webpack_require__.c = installedModules;
|
||||
/******/
|
||||
/******/ // define getter function for harmony exports
|
||||
/******/ __webpack_require__.d = function(exports, name, getter) {
|
||||
/******/ if(!__webpack_require__.o(exports, name)) {
|
||||
/******/ Object.defineProperty(exports, name, {
|
||||
/******/ configurable: false,
|
||||
/******/ enumerable: true,
|
||||
/******/ get: getter
|
||||
/******/ });
|
||||
/******/ }
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
||||
/******/ __webpack_require__.n = function(module) {
|
||||
/******/ var getter = module && module.__esModule ?
|
||||
/******/ function getDefault() { return module['default']; } :
|
||||
/******/ function getModuleExports() { return module; };
|
||||
/******/ __webpack_require__.d(getter, 'a', getter);
|
||||
/******/ return getter;
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // Object.prototype.hasOwnProperty.call
|
||||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 1);
|
||||
/******/ })
|
||||
/************************************************************************/
|
||||
/******/ ([
|
||||
/* 0 */,
|
||||
/* 1 */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
let foo = (() => {
|
||||
var _ref = _asyncToGenerator(function* () {
|
||||
yield bar();
|
||||
console.log("YO");
|
||||
});
|
||||
|
||||
return function foo() {
|
||||
return _ref.apply(this, arguments);
|
||||
};
|
||||
})();
|
||||
|
||||
function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; }
|
||||
|
||||
function bar() {
|
||||
return new Promise(resolve => setTimeout(resolve, 100));
|
||||
}
|
||||
|
||||
console.log("HEY");
|
||||
|
||||
/***/ })
|
||||
/******/ ]);
|
||||
//# sourceMappingURL=v2.bundle.js.map
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"sources":["webpack:///webpack/bootstrap 8bcf0d04c821a99f6859","webpack:///./v1.js"],"names":["bar","console","log","foo","Promise","resolve","setTimeout"],"mappings":";AAAA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,mCAA2B,0BAA0B,EAAE;AACvD,yCAAiC,eAAe;AAChD;AACA;AACA;;AAEA;AACA,8DAAsD,+DAA+D;;AAErH;AACA;;AAEA;AACA;;;;;;;;;+BCtDA,aAAqB;AACnB,UAAMA,KAAN;AACAC,YAAQC,GAAR,CAAY,IAAZ;AACD,G;;kBAHcC,G;;;;;;;AAPf,SAASH,GAAT,GAAe;AACb,SAAO,IAAII,OAAJ,CAAYC,WAAWC,WAAWD,OAAX,EAAoB,GAApB,CAAvB,CAAP;AACD;;AAUDJ,QAAQC,GAAR,CAAY,KAAZ,E","file":"v2.bundle.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 1);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 8bcf0d04c821a99f6859","function bar() {\n return new Promise(resolve => setTimeout(resolve, 100))\n}\n\n\n\n\nasync function foo() {\n await bar();\n console.log(\"YO\")\n}\n\nconsole.log(\"HEY\")\n\n\n\n// WEBPACK FOOTER //\n// ./v2.js"],"sourceRoot":""}
|
|
@ -0,0 +1,13 @@
|
|||
function bar() {
|
||||
return new Promise(resolve => setTimeout(resolve, 100))
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
async function foo() {
|
||||
await bar();
|
||||
console.log("YO")
|
||||
}
|
||||
|
||||
console.log("HEY")
|
|
@ -0,0 +1,78 @@
|
|||
/******/ (function(modules) { // webpackBootstrap
|
||||
/******/ // The module cache
|
||||
/******/ var installedModules = {};
|
||||
/******/
|
||||
/******/ // The require function
|
||||
/******/ function __webpack_require__(moduleId) {
|
||||
/******/
|
||||
/******/ // Check if module is in cache
|
||||
/******/ if(installedModules[moduleId]) {
|
||||
/******/ return installedModules[moduleId].exports;
|
||||
/******/ }
|
||||
/******/ // Create a new module (and put it into the cache)
|
||||
/******/ var module = installedModules[moduleId] = {
|
||||
/******/ i: moduleId,
|
||||
/******/ l: false,
|
||||
/******/ exports: {}
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // Execute the module function
|
||||
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
||||
/******/
|
||||
/******/ // Flag the module as loaded
|
||||
/******/ module.l = true;
|
||||
/******/
|
||||
/******/ // Return the exports of the module
|
||||
/******/ return module.exports;
|
||||
/******/ }
|
||||
/******/
|
||||
/******/
|
||||
/******/ // expose the modules object (__webpack_modules__)
|
||||
/******/ __webpack_require__.m = modules;
|
||||
/******/
|
||||
/******/ // expose the module cache
|
||||
/******/ __webpack_require__.c = installedModules;
|
||||
/******/
|
||||
/******/ // define getter function for harmony exports
|
||||
/******/ __webpack_require__.d = function(exports, name, getter) {
|
||||
/******/ if(!__webpack_require__.o(exports, name)) {
|
||||
/******/ Object.defineProperty(exports, name, {
|
||||
/******/ configurable: false,
|
||||
/******/ enumerable: true,
|
||||
/******/ get: getter
|
||||
/******/ });
|
||||
/******/ }
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
||||
/******/ __webpack_require__.n = function(module) {
|
||||
/******/ var getter = module && module.__esModule ?
|
||||
/******/ function getDefault() { return module['default']; } :
|
||||
/******/ function getModuleExports() { return module; };
|
||||
/******/ __webpack_require__.d(getter, 'a', getter);
|
||||
/******/ return getter;
|
||||
/******/ };
|
||||
/******/
|
||||
/******/ // Object.prototype.hasOwnProperty.call
|
||||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 2);
|
||||
/******/ })
|
||||
/************************************************************************/
|
||||
/******/ ({
|
||||
|
||||
/***/ 2:
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
function bar() {
|
||||
return new Promise(resolve => setTimeout(resolve, 100));
|
||||
}
|
||||
|
||||
/***/ })
|
||||
|
||||
/******/ });
|
||||
//# sourceMappingURL=v3.bundle.js.map
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"sources":["webpack:///webpack/bootstrap 8bcf0d04c821a99f6859","webpack:///./v1.js"],"names":["bar","Promise","resolve","setTimeout"],"mappings":";AAAA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,mCAA2B,0BAA0B,EAAE;AACvD,yCAAiC,eAAe;AAChD;AACA;AACA;;AAEA;AACA,8DAAsD,+DAA+D;;AAErH;AACA;;AAEA;AACA;;;;;;;;AC7DA,SAASA,GAAT,GAAe;AACb,SAAO,IAAIC,OAAJ,CAAYC,WAAWC,WAAWD,OAAX,EAAoB,GAApB,CAAvB,CAAP;AACD,C","file":"v3.bundle.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 2);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 8bcf0d04c821a99f6859","function bar() {\n return new Promise(resolve => setTimeout(resolve, 100))\n}\n\n\n\n// WEBPACK FOOTER //\n// ./v3.js"],"sourceRoot":""}
|
|
@ -0,0 +1,3 @@
|
|||
function bar() {
|
||||
return new Promise(resolve => setTimeout(resolve, 100))
|
||||
}
|
|
@ -0,0 +1,26 @@
|
|||
const path = require("path");
|
||||
const webpack = require("webpack");
|
||||
|
||||
module.exports = {
|
||||
entry: {
|
||||
v1: "./v1.js",
|
||||
v2: "./v2.js",
|
||||
v3: "./v3.js"
|
||||
},
|
||||
output: {
|
||||
path: __dirname,
|
||||
filename: "[name].bundle.js"
|
||||
},
|
||||
devtool: "sourcemap",
|
||||
module: {
|
||||
loaders: [
|
||||
{
|
||||
test: /\.js$/,
|
||||
exclude: /node_modules/,
|
||||
loader: "babel-loader"
|
||||
}
|
||||
]
|
||||
},
|
||||
plugins: [
|
||||
]
|
||||
};
|
|
@ -29,6 +29,10 @@ copySourceUri2.accesskey=u
|
|||
setDirectoryRoot.label=Set directory root
|
||||
setDirectoryRoot.accesskey=r
|
||||
|
||||
# LOCALIZATION NOTE (removeDirectoryRoot): This is the text that appears in the
|
||||
# context menu to remove a directory as root directory
|
||||
removeDirectoryRoot.label=Remove directory root
|
||||
|
||||
# LOCALIZATION NOTE (copyFunction): This is the text that appears in the
|
||||
# context menu to copy the function the user selected
|
||||
copyFunction.label=Copy function
|
||||
|
|
Загрузка…
Ссылка в новой задаче