text stringlengths 14 100k | source stringclasses 1
value | repo stringclasses 810
values | language stringclasses 13
values |
|---|---|---|---|
<|fim_suffix|>bar";
export const foo = 1;
export const bar = 1;
<|fim_prefix|>export * f<|fim_middle|>rom "fs";
export * from "./reexport-foo";
export * from "./reexport-<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>/bar";
<|fim_prefix|>export * from "path";
export * f<|fim_middle|>rom ".<|endoftext|> | fim | webpack/webpack | javascript |
export * from "./foo";
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|> { default as func2 } from './function-esm';
var module = "should not conflict",
define = "should not conflict",
require = "should not conflict",
exports = "should not conflict",
globalName = "should not conflict";
console.log.bind(console, module, define, require, exports, globalName);
<|fim_prefix|... | fim | webpack/webpack | javascript |
<|fim_suffix|>s MyClass {
getValue() {
return "my-class";
}
}
export default MyClass;
export { a, b };
<|fim_prefix|>const a = 10;
const<|fim_middle|> b = 20;
clas<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>;
<|fim_prefix|>exports = {
name: "expor<|fim_middle|>ts-shortcut-cjs"
}<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>"bar";
<|fim_prefix|>export cons<|fim_middle|>t foo = <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>;
}
<|fim_prefix|>module.exports = function t<|fim_middle|>est() {
return 3<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>ort default function test() {
return 4;
}
<|fim_prefix|>e<|fim_middle|>xp<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>export * from "<|fim_suffix|>ine = "should not conflict",
require = "should not conflict",
exports = "should not conflict",
globalName = "should not conflict";
console.log.bind(console, module, define, require, exports, globalName);
<|fim_middle|>./a";
export default "default-value";
export var b = "b"... | fim | webpack/webpack | javascript |
<|fim_prefix|>export<|fim_suffix|>-named";
var module = "should not conflict",
define = "should not conflict",
require = "should not conflict",
exports = "should not conflict",
globalName = "should not conflict";
console.log.bind(console, module, define, require, exports, globalName);
<|fim_middle|> * from "./a";
... | fim | webpack/webpack | javascript |
<|fim_suffix|>ould not conflict",
require = "should not conflict",
exports = "should not conflict",
globalName = "should not conflict";
console.log.bind(console, module, define, require, exports, globalName);
<|fim_prefix|>expor<|fim_middle|>t * as NS from "./index.js";
var module = "should not conflict",
define =... | fim | webpack/webpack | javascript |
<|fim_suffix|>l-a";
<|fim_prefix|>export const nonExternalA = "non-e<|fim_middle|>xterna<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>ternal";
<|fim_prefix|>export<|fim_middle|> default "non-ex<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>module.exports.foo = "foo";
module.exports = {
name: "overrides-<|fim_suffix|>js"
};
<|fim_middle|>exports-c<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>efine-module-property-cjs");
module.exports.name = "reexport-define-module-property-cjs";
<|fim_prefix|>mo<|fim_middle|>dule.exports = require("./d<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>e
this.name<|fim_prefix|>exports.name
mo<|fim_middle|>dule.nam<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict<|fim_suffix|>ule.exports.noTests = true;
<|fim_middle|>";
mod<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>
iife: true
},
resolve: {
alias: {
external: "./non-external",
"external-named": "./non-external-named"
}
}
},
{
output: {
uniqueName: "commonjs2-external",
filename: "commonjs2-external.js",
library: {
type: "commonjs2"
},
iife: false
},
externals: ["exte... | fim | webpack/webpack | javascript |
import MyClass, {a, b} from "library-commonjs";
it("should get exports from systemjs library (" + NAME + ")", function() {
expect(new MyClass().getValue()).toBe("my-class")
expect(a).toBe(10);
expect(b).toBe(20);
});
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
const System = require("../../../helpers/fakeSyste<|fim_suffix|>pe.System.setRequire(scope.require);
},
afterExecute() {
delete global.webpackChunk;
System.execute("(anonym)");
}
};
<|fim_middle|>m");
module.exports = {
beforeExecute: () => {
System.init();
},
moduleScope(scope... | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
const path = require("path");
<|fim_suffix|>ry: "./system-external-commonjs.js",
output: {
library: {
type: "system"
}
},
externals: {
"library-commonjs": path.resolve(
testPath,
"../0-create-library/system-commonjs.js"
)
},
plugins: [
new webpack.Define... | fim | webpack/webpack | javascript |
<|fim_prefix|>import MyClass, {a, b} from "library-commonjs";
it("should get exports fr<|fim_suffix|>nction() {
expect(new MyClass().getValue()).toBe("my-class")
expect(a).toBe(10);
expect(b).toBe(20);
});
<|fim_middle|>om systemjs library (" + NAME + ")", fu<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>ystem = System;
scope.System.setRequire(scope.require);
},
afterExecute() {
delete global.webpackChunk;
System.execute("(anonym)");
}
};
<|fim_prefix|>"use strict";
const System = require("../../../helpers/fakeSystem");
module.exports = {
beforeExecute: () => {
System.init();
},
modu<|fim_... | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
const path = require("path");
const webpack = require("../../../../");
/** @type {(env: Env, options: TestOptions) => import("../../../../").Configuration[]} */
module.exports = (env, { testPath }) => [
{
entry: "./system-external-commonjs.js",
output: {
library: {
type: "syste... | fim | webpack/webpack | javascript |
<|fim_prefix|>import MyClass, {a, b}<|fim_suffix|>yClass().getValue()).toBe("my-class")
expect(a).toBe(10);
expect(b).toBe(20);
});
<|fim_middle|> from "library-esm";
it("should get exports from systemjs library (" + NAME + ")", function() {
expect(new M<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>ire);
},
afterExecute() {
delete global.webpackChunk;
System.execute("(anonym)");
}
};
<|fim_prefix|>"use strict";
const System = require("../../../helpers/fakeSystem<|fim_middle|>");
module.exports = {
beforeExecute: () => {
System.init();
},
moduleScope(scope) {
scope.System = System;
... | fim | webpack/webpack | javascript |
<|fim_suffix|>ary/system-esm.js")
},
plugins: [
new webpack.DefinePlugin({
NAME: JSON.stringify("systemjs with external from ES module format")
})
]
}
];
<|fim_prefix|>"use strict";<|fim_middle|>
const path = require("path");
const webpack = require("../../../../");
/** @type {(env: Env, options: Tes... | fim | webpack/webpack | javascript |
<|fim_suffix|>ary (" + NAME + ")", function() {
expect(new MyClass().getValue()).toBe("my-class")
expect(a).toBe(10);
expect(b).toBe(20);
});
<|fim_prefix|>import MyClass, {a,<|fim_middle|> b} from "library-esm";
it("should get exports from systemjs libr<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>em = System;
scope.System.setRequire(scope.require);
},
afterExecute() {
delete global.webpackChunk;
System.execute("(anonym)");
}
};
<|fim_prefix|>"use strict";
const System = require("../../../helpers/fakeSystem");
<|fim_middle|>module.exports = {
beforeExecute: () => {
System.init();
},
... | fim | webpack/webpack | javascript |
"use strict";
const path = require("path");
const webpack = require("../../../../");
/** @type {(env: Env, options: TestOptions) => import("../../../../").Configuration[]} */
module.exports = (env, { testPath }) => [
{
entry: "./system-external-esm.js",
output: {
library: {
type: "system"
}
},
exte... | fim | webpack/webpack | javascript |
<|fim_suffix|>t(d).toBe("default-value");
});
<|fim_prefix|>import d from "library";
it("should tree-shake other exports <|fim_middle|>from library (" + NAME + ")", function() {
expec<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>import d from "library";
var data =<|fim_suffix|>brary");
it("should get default export from library (" + NAME + ")", function() {
expect(data).toBe("default-value");
expect(d).toBe("default-value");
});
<|fim_middle|> require("li<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|> expect(foo).toBe(1);
expect(bar).toBe(1);
expect(readFile).toBe(fs.readFile);
expect(resolve).toBe(path.resolve);
});
<|fim_prefix|>import { readFile, foo, bar, resolve } from "library";
import fs from "fs"
import path from "path"
it("should handle external module correctly with star reexports", () ... | fim | webpack/webpack | javascript |
<|fim_suffix|>tchObject({
foo: "foo",
name: "define-this-exports-cjs"
});
expect(lib8_foo).toBe("foo");
expect(lib8_name).toBe("define-this-exports-cjs");
}
);
<|fim_prefix|>// class-commonjs
import lib1 from "lib1";
// exports-shortcut-cjs
import lib2 from "lib2";
// overrides-exports-cjs
import lib3 from... | fim | webpack/webpack | javascript |
import d from "library";
import { a, b, external, MyClass1, MyClass2, func1, func2 } from "library";
import * as imoprtStar from "library";
it(
"should be able to import harmony exports from library (" + NAME + ")",
function () {
expect(d).toBe("default-value");
expect(a).toBe("a");
expect(b).toBe("b");
expe... | fim | webpack/webpack | javascript |
<|fim_prefix|>import d from "library";
import { a, b, external } from "library";
import * as imoprtStar from "library";
it(
"should be able to import harmony exports from library (" + NAME + ")",
function () {
expect(d).toBe("default-value");
expect(a).toBe("a");
<|fim_suffix|>(["external"]);
expect(external)... | fim | webpack/webpack | javascript |
<|fim_prefix|>import * as mod from "library";
it("<|fim_suffix|>t(mod).toMatchObject({ a: "a" });
});
<|fim_middle|>should tree-shake other exports from library (" + NAME + ") and export only 'a'", function() {
expec<|endoftext|> | fim | webpack/webpack | javascript |
"use strict";
module.exports = {
moduleScope(scope) {
scope.define = (factory) => {
scope.module.exports = factory();
};
},
afterExecute() {
delete global.webpackChunk;
}
};
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>eProperty("b", "b");
});
<|fim_prefix|>var data = require("library");
it("should be able get items from library (" + NAME + ")", function() {
expect(data).toHaveProperty("default", "default-value");
expect(dat<|fim_middle|>a).toHaveProperty("a", "a");
expect(data).toHav<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>var getData = require("library");
it("should be able get items from library (" + NAME + ")", function() {
const d = getData();
expect(d).toHaveProp<|fim_suffix|>b", "b");
});
<|fim_middle|>erty("x");
expect(d.x).toHaveProperty("y");
const data = d.x.y;
expect(data).toHaveProperty("default", "default... | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @typedef {import("../../../../").Compiler} Compiler */
/** @typedef {import("../../../../").Compilation} Compilation */
const path = require("path");
const webpack = require("../../../../");
const supportsAsync = require("../../../helpers/supportsAsync");
/** @type {(env: Env, options... | fim | webpack/webpack | javascript |
it("should run", function() {
});<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";<|fim_suffix|>;
<|fim_middle|>
/** @type {import("../../../../").Configuration} */
module.exports = {
output: {
libraryTarget: "this"
}
}<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>it("should define global object with property", function() {
expect(a["b"]<|fim_suffix|>oBeDefined();
});
<|fim_middle|>).t<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|><|fim_prefix|>"use strict";
/** @type {import("../../../../").Configuration} */
module.exports = {
output: {
library: ["a<|fim_middle|>", "b"]
}
};
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>'window' object", function() {
expect(window["a"]["b"]).toBeDefined();
});
<|fim_prefix|>it("shou<|fim_middle|>ld define property in <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>web",
output: {
library: ["a", "b"],
libraryTarget: "window"
}
};
<|fim_prefix|>"use strict";
/** @type {import("../../../<|fim_middle|>../").Configuration} */
module.exports = {
target: "<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>roperties_env"]).toEqual("1");
expect(Object.keys(process.env).length).toBeGreaterThan(1);
});
module.exports = {
assign_properties_env: "1"
}
<|fim_prefix|>it("should define global object with property", function() {
ex<|fim_middle|>pect(process.env["assign_p<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>gn-properties"
}
};
<|fim_prefix|>"use strict";
/** @type {import("../../../../").Configura<|fim_middle|>tion} */
module.exports = {
output: {
library: ["process", "env"],
libraryTarget: "assi<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>it("should run", function() {
});
it("should have exported", function(done) {
setTimeout(function() {
expect(exported.object).toBe(module.exports.object);
expect(exported.second).toBe(module.exports.second);
done();
}, 1)<|fim_suffix|> delete global.object;
delete global.second;
});
<|fim_middl... | fim | webpack/webpack | javascript |
<|fim_suffix|>*/
module.exports = {
output: {
libraryTarget: "global"
}
};
<|fim_prefix|>"use strict";
/** @type {import(".<|fim_middle|>./../../../").Configuration} <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>h(/exports(\[|\.)/g).length).toBe(4)
})
<|fim_prefix|>const f<|fim_middle|>s = require("fs")
export const foo1 = () => {}
export const foo2 = () => {}
const bar = "bar";
export default bar
it("should success compile and work",()=>{
const output = fs.readFileSync(__filename).toString();
expect(output.ma... | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @type {import("../../<|fim_suffix|>rary: { type: "commonjs-static" }
}
};
<|fim_middle|>../../").Configuration} */
module.exports = {
target: "node",
output: {
lib<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>e).toBe(true);
});
<|fim_prefix|>
it('should compile', () => {});
it('should handle <|fim_middle|>external modules with concatenation and caching', () => {
// This test ensures serialization works with caching enabled
expect(tru<|endoftext|> | fim | webpack/webpack | javascript |
import { HomeLayout as aaa } from 'externals0';
const { HomeLayout = 123 } = {};
console.log({ HomeLayout });
{
const { HomeLayout = aaa } = {};
console.log({ HomeLayout });
}
(() => {
{
const { HomeLayout = aaa } = {};
console.log({ HomeLayout });
}
})()
{
const { external_externa... | fim | webpack/webpack | javascript |
"use strict";
module.exports = {
findBundle() {
return ["main.js"];
}
};
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>'
{
const HomeLayout_0 = 'HomeLayout_0';
HomeLayout_0;
}
aaa;
a_0;
a_2;
defaultValue;
namespace;<|fim_prefix|>// re export
export { a } from 'externals0'
// named import
import { a as a_2, HomeLayout as aaa } from 'externals1'
import { a as a_0 } from 'externals0'
// default import
import defau... | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @type {import("../../../../types").Configuration} */
module.exports = {
cache: {
type: "memory" // Enable memory cache to test serialization
},
mode: "none",
entry: { main: "./index.js", test: "./test.js" },
output: {
module: true,
library: {
type: <|fim_suffix|>apshot();
... | fim | webpack/webpack | javascript |
export const lib3 = 'commonjs-static'
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>export<|fim_suffix|>default "null"
it("should compile and run", () => {
// avoid `No tests exported by test case`
expect(true).toBe(true)
});<|fim_middle|> const lib2 = 'modern-module'
export <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>import React from 'reac<|fim_suffix|>avoid `No tests exported by test case`
expect(true).toBe(true)
});
<|fim_middle|>t';
const foo = "module"
export default 'module'
export { React, foo }
it("should compile and run", () => {
// <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>it("should compile and ru<|fim_suffix|>rsion)).toBe(true);
expect(libModernModule.default).toBe("modern-module");
expect(libCommonjsStatic.default).toBe("commonjs-static");
});
<|fim_middle|>n", () => {
expect(libModule.default).toBe("module");
expect(libModule.foo).toBe("module");
expect(Boolean... | fim | webpack/webpack | javascript |
<|fim_suffix|>= require("../../../helpers/supportsRequireInModule");
module.exports = () => supportsRequireInModule();
<|fim_prefix|>"use strict";
const supportsRequ<|fim_middle|>ireInModule <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>equire("./bundle2.js");
let libModule = { default: lib1Default, foo, React };
let libModernModule = { default: lib2};
let libCommonjsStatic = { default: lib3 };
`
}),
{
apply(compiler) {
compiler.hooks.done.tap(
{
name: "disable-provided-export",
sta... | fim | webpack/webpack | javascript |
<|fim_suffix|>t be executed");
});
<|fim_prefix|>it("should error", function () <|fim_middle|>{
throw new Error("should no<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>port("../../../../").Configuration} */
module.exports = {
output: {
library: ["123-hello world", "hello world"]
}
};
<|fim_prefix|>"use stri<|fim_middle|>ct";
/** @type {im<|endoftext|> | fim | webpack/webpack | javascript |
it("should don't have variable name conflict", function() {
expect(true).toBe(true);
});
const i = 1;
export default "test";
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @type {import("../../../../").Configuration<|fim_suffix|>ports = {
mode: "production",
output: {
library: {
type: "commonjs"
}
}
};
<|fim_middle|>} */
module.ex<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>rt const ids = ["collision"];
export const modules = { "collision": true };
<|fim_prefix|>it("should don't <|fim_middle|>have variable name conflict", function() {
expect(true).toBe(true);
});
export const id = "collision";
expo<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>main.mjs"];
}
};
<|fim_prefix|>"use strict";
module.exports = {
findBundle() {
return [<|fim_middle|>"<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @t<|fim_suffix|>ion: {
runtimeChunk: "single" // any value other than `false`
}
};
<|fim_middle|>ype {import("../../../../").Configuration} */
module.exports = {
experiments: { outputModule: true },
output: {
filename: "[name].mjs",
library: { type: "module" }
},
optimizat<|e... | fim | webpack/webpack | javascript |
<|fim_prefix|>Object.defineProperty(exports, "_<|fim_suffix|> true });
exports.main = main;
function main() {}
// commonjs bailout
if(this){}
it("Should work when exports are unprovided", function() {
expect(true).toBe(true);
});
<|fim_middle|>_esModule", { value:<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @type {import("../../../../").Configuration} */
module.exports = {
output: {
library: {
type: "commo<|fim_suffix|>static"
}
}
};
<|fim_middle|>njs-<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>
it('should compile', () =><|fim_suffix|>uld handle external modules with concatenation and caching', () => {
// This test ensures serialization works with caching enabled
expect(true).toBe(true);
});
<|fim_middle|> {});
it('sho<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>t { HomeLayout = aaa } = {};
console.log({ HomeLayout });
}
(() => {
{
const { HomeLayout = aaa } = {};
console.log({ HomeLayout });
}
})()
{
const { external_externals3_namespaceObject = "111" } = {}
console.log({ external_externals3_namespaceObject });
}
exp... | fim | webpack/webpack | javascript |
<|fim_suffix|>trict";
module.exports = {
findBundle() {
return ["main.js"];
}
};
<|fim_prefix|>"<|fim_middle|>use s<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|> 'externals3'
// side effect only import
import 'externals4'
export { HomeLayout } from './lib'
{
const HomeLayout_0 = 'HomeLayout_0';
HomeLayout_0;
}
aaa;
a_0;
a_2;
defaultValue;
namespace;<|fim_prefix|>// re export
export { a } from 'externals0'
// named import
import { a as a_2, HomeLayout ... | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
/** @type {import("../../../../types").Configuration} */
module.exports = {
cache: {
type: "memory" // Enable memory cache to test serialization
},
mode: "none",
entry: { main: "./index.js", test: "./test.js" },
output: {
module: true,
library: {
type: "modern-module"
},
f... | fim | webpack/webpack | javascript |
<|fim_suffix|>my-class");
});
<|fim_prefix|>import { myClass } from "./s<|fim_middle|>tyle.custom";
it("should work", function() {
expect(myClass).toBe("<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>{Error} */ (e));
return;
}
if (!source) {
callback(new Error("Didn't get a result from child compiler"));
return;
}
callback(null, source);
}
<|fim_prefix|>/** @typedef {import("../../../../").Compiler} Compiler */
/** @typedef {import("../../../../").Compilation} Compilation */
/** @type {im... | fim | webpack/webpack | javascript |
export default function(name) {
return name;
}
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>,
rules: [
{
test: /\.custom$/i,
loader: require.resolve("./loader")
}
]
},
experiments: {
outputModule: true
}
};
<|fim_prefix|>"use strict"<|fim_middle|>;
/** @type {import("../../../../").Configuration} */
module.exports = {
mode: "production",
target: "web",
output: {
modu... | fim | webpack/webpack | javascript |
<|fim_suffix|>",
bar: "bar"
};
<|fim_prefix|>export cons<|fim_middle|>t inner = {
foo: "foo<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>import { foo, bar } from "external";
it("sho<|fim_suffix|>external.mjs', 'inner'])", function () {
expect(foo).toBe("foo");
expect(bar).toBe("bar");
});
<|fim_middle|>uld have the correct export for array-style external request (e.g. external: ['./<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
const fs = require("fs");
const path = require("path");
const webpack = require("../../../../");
/** @type {webpack.Configuration} */
module.exports = {
mode: "production",
entry: "./index.js",
output: {
module: true,
library: {
type: "module"
}
},
experiments: {
outputModu... | fim | webpack/webpack | javascript |
<|fim_suffix|>1").foo;
<|fim_prefix|>module.exports = requ<|fim_middle|>ire("./foo<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>import { a as concat2_a, b as concat2_b, c as concat2_c } from "./concat2";
export <|fim_suffix|>cat2_b;
export const c = "concat1~" + concat2_c;
<|fim_middle|>const a = "concat1~" + concat2_a;
export const b = "concat1~" + con<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>t const a = "concat2~" + external_a;
export const b = "concat2~" + external_b;
export const c = "concat2~" + external_c;
<|fim_prefix|>import { a as external_a, b as external_b, c as external_c } from "ex<|fim_middle|>ternal";
expor<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>pect(cjs).toBe("foo1~foo2~foo3~foo4");
});
<|fim_prefix|>// This concat module has size `4`
import { <|fim_middle|>a, b, c } from "./concat1";
// Create one shared concat module that exist in multiple chunks
import cjs from "./cjs-concat";
it("should generate correct specifier pointed to import binding ... | fim | webpack/webpack | javascript |
<|fim_prefix|>// This concat module has size `3`
import { a, b, c } from "./concat2";
//<|fim_suffix|>ding / 2", function () {
expect(a).toBe("concat2~external-a");
expect(b).toBe("concat2~external-b");
expect(c).toBe("concat2~external-c");
expect(cjs).toBe("foo1~foo2~foo3~foo4");
});
<|fim_middle|> Create one sha... | fim | webpack/webpack | javascript |
<|fim_prefix|>export const a = "external-a"
export const b = "external-b"
export const c <|fim_suffix|>"
<|fim_middle|>= "external-c<|endoftext|> | fim | webpack/webpack | javascript |
// This concat module has size `4`
import foo2 from "./foo2";
export const foo = "foo1~" + foo2;
<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>default "foo2~" + foo3;
<|fim_prefix|>import foo3 f<|fim_middle|>rom "./foo3";
export <|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>import foo4 <|fim_suffix|>4";
export default "foo3~" + foo4;
<|fim_middle|>from "./foo<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|> "foo4"
<|fim_prefix|>export defau<|fim_middle|>lt<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_suffix|>mjs", "entry2.mjs"];
}
};
<|fim_prefix|>"use strict";
module.exports = {
findBundle() {
return<|fim_middle|> ["entry1.<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>"use strict";
const fs = require("fs");
const path = require("path");
const webpack = require("../../../../");
/** @type {webpack.Configuration} */
module.exports = {
mode: "production",
entry: { entry1: "./entry1.js", entry<|fim_suffix|>er.webpack.Compilation.PROCESS_ASSETS_STAGE_ADDITIONAL
},
... | fim | webpack/webpack | javascript |
<|fim_prefix|>export * from "./baz<|fim_suffix|>t bar = "bar"
<|fim_middle|>"
export cons<|endoftext|> | fim | webpack/webpack | javascript |
<|fim_prefix|>export const baz =<|fim_suffix|>"baz"
<|fim_middle|> <|endoftext|> | fim | webpack/webpack | javascript |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.