@nrwl/next 15.9.2 → 16.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/babel.js +1 -12
- package/babel.js.map +1 -1
- package/executors.json +12 -12
- package/generators.json +2 -70
- package/index.d.ts +1 -6
- package/index.js +1 -12
- package/index.js.map +1 -1
- package/package.json +7 -30
- package/plugins/with-less.d.ts +1 -2
- package/plugins/with-less.js +1 -75
- package/plugins/with-less.js.map +1 -1
- package/plugins/with-nx.d.ts +1 -15
- package/plugins/with-nx.js +1 -274
- package/plugins/with-nx.js.map +1 -1
- package/plugins/with-stylus.d.ts +1 -2
- package/plugins/with-stylus.js +1 -75
- package/plugins/with-stylus.js.map +1 -1
- package/tailwind.d.ts +1 -2
- package/tailwind.js +2 -4
- package/tailwind.js.map +1 -1
- package/README.md +0 -63
- package/migrations.json +0 -306
- package/src/executors/build/build.impl.d.ts +0 -6
- package/src/executors/build/build.impl.js +0 -62
- package/src/executors/build/build.impl.js.map +0 -1
- package/src/executors/build/compat.d.ts +0 -2
- package/src/executors/build/compat.js +0 -6
- package/src/executors/build/compat.js.map +0 -1
- package/src/executors/build/lib/check-project.d.ts +0 -1
- package/src/executors/build/lib/check-project.js +0 -13
- package/src/executors/build/lib/check-project.js.map +0 -1
- package/src/executors/build/lib/create-next-config-file.d.ts +0 -3
- package/src/executors/build/lib/create-next-config-file.js +0 -15
- package/src/executors/build/lib/create-next-config-file.js.map +0 -1
- package/src/executors/build/lib/update-package-json.d.ts +0 -3
- package/src/executors/build/lib/update-package-json.js +0 -24
- package/src/executors/build/lib/update-package-json.js.map +0 -1
- package/src/executors/build/schema.json +0 -68
- package/src/executors/export/compat.d.ts +0 -2
- package/src/executors/export/compat.js +0 -6
- package/src/executors/export/compat.js.map +0 -1
- package/src/executors/export/export.impl.d.ts +0 -6
- package/src/executors/export/export.impl.js +0 -53
- package/src/executors/export/export.impl.js.map +0 -1
- package/src/executors/export/schema.json +0 -30
- package/src/executors/server/compat.d.ts +0 -2
- package/src/executors/server/compat.js +0 -6
- package/src/executors/server/compat.js.map +0 -1
- package/src/executors/server/lib/custom-server.d.ts +0 -2
- package/src/executors/server/lib/custom-server.js +0 -15
- package/src/executors/server/lib/custom-server.js.map +0 -1
- package/src/executors/server/lib/default-server.d.ts +0 -6
- package/src/executors/server/lib/default-server.js +0 -34
- package/src/executors/server/lib/default-server.js.map +0 -1
- package/src/executors/server/lib/tsnode-register.d.ts +0 -1
- package/src/executors/server/lib/tsnode-register.js +0 -23
- package/src/executors/server/lib/tsnode-register.js.map +0 -1
- package/src/executors/server/schema.json +0 -61
- package/src/executors/server/server.impl.d.ts +0 -7
- package/src/executors/server/server.impl.js +0 -120
- package/src/executors/server/server.impl.js.map +0 -1
- package/src/generators/application/application.d.ts +0 -4
- package/src/generators/application/application.js +0 -45
- package/src/generators/application/application.js.map +0 -1
- package/src/generators/application/files/.babelrc__tmpl__ +0 -21
- package/src/generators/application/files/index.d.ts__tmpl__ +0 -18
- package/src/generators/application/files/next-env.d.ts__tmpl__ +0 -5
- package/src/generators/application/files/next.config.js__tmpl__ +0 -70
- package/src/generators/application/files/pages/__fileName__.module.__style__ +0 -1
- package/src/generators/application/files/pages/__fileName__.tsx__tmpl__ +0 -28
- package/src/generators/application/files/pages/_app.tsx__tmpl__ +0 -18
- package/src/generators/application/files/pages/_document.tsx__tmpl__ +0 -33
- package/src/generators/application/files/pages/styles.__stylesExt____tmpl__ +0 -1
- package/src/generators/application/files/public/.gitkeep +0 -0
- package/src/generators/application/files/specs/__fileName__.spec.tsx__tmpl__ +0 -11
- package/src/generators/application/files/tsconfig.json__tmpl__ +0 -18
- package/src/generators/application/lib/add-cypress.d.ts +0 -3
- package/src/generators/application/lib/add-cypress.js +0 -18
- package/src/generators/application/lib/add-cypress.js.map +0 -1
- package/src/generators/application/lib/add-jest.d.ts +0 -3
- package/src/generators/application/lib/add-jest.js +0 -36
- package/src/generators/application/lib/add-jest.js.map +0 -1
- package/src/generators/application/lib/add-linting.d.ts +0 -3
- package/src/generators/application/lib/add-linting.js +0 -66
- package/src/generators/application/lib/add-linting.js.map +0 -1
- package/src/generators/application/lib/add-project.d.ts +0 -3
- package/src/generators/application/lib/add-project.js +0 -59
- package/src/generators/application/lib/add-project.js.map +0 -1
- package/src/generators/application/lib/create-application-files.d.ts +0 -3
- package/src/generators/application/lib/create-application-files.helpers.d.ts +0 -2
- package/src/generators/application/lib/create-application-files.helpers.js +0 -785
- package/src/generators/application/lib/create-application-files.helpers.js.map +0 -1
- package/src/generators/application/lib/create-application-files.js +0 -34
- package/src/generators/application/lib/create-application-files.js.map +0 -1
- package/src/generators/application/lib/create-next-server-files.d.ts +0 -3
- package/src/generators/application/lib/create-next-server-files.js +0 -57
- package/src/generators/application/lib/create-next-server-files.js.map +0 -1
- package/src/generators/application/lib/normalize-options.d.ts +0 -13
- package/src/generators/application/lib/normalize-options.js +0 -33
- package/src/generators/application/lib/normalize-options.js.map +0 -1
- package/src/generators/application/lib/set-defaults.d.ts +0 -3
- package/src/generators/application/lib/set-defaults.js +0 -14
- package/src/generators/application/lib/set-defaults.js.map +0 -1
- package/src/generators/application/lib/update-jest-config.d.ts +0 -3
- package/src/generators/application/lib/update-jest-config.js +0 -16
- package/src/generators/application/lib/update-jest-config.js.map +0 -1
- package/src/generators/application/schema.d.ts +0 -20
- package/src/generators/application/schema.json +0 -131
- package/src/generators/component/component.d.ts +0 -15
- package/src/generators/component/component.js +0 -34
- package/src/generators/component/component.js.map +0 -1
- package/src/generators/component/schema.json +0 -119
- package/src/generators/custom-server/custom-server.d.ts +0 -4
- package/src/generators/custom-server/custom-server.js +0 -79
- package/src/generators/custom-server/custom-server.js.map +0 -1
- package/src/generators/custom-server/files/server/main.ts__tmpl__ +0 -46
- package/src/generators/custom-server/files/tsconfig.server.json__tmpl__ +0 -15
- package/src/generators/custom-server/schema.d.ts +0 -4
- package/src/generators/custom-server/schema.json +0 -30
- package/src/generators/init/init.d.ts +0 -5
- package/src/generators/init/init.js +0 -49
- package/src/generators/init/init.js.map +0 -1
- package/src/generators/init/schema.d.ts +0 -7
- package/src/generators/init/schema.json +0 -39
- package/src/generators/library/library.d.ts +0 -5
- package/src/generators/library/library.js +0 -73
- package/src/generators/library/library.js.map +0 -1
- package/src/generators/library/schema.d.ts +0 -26
- package/src/generators/library/schema.json +0 -162
- package/src/generators/page/page.d.ts +0 -5
- package/src/generators/page/page.js +0 -27
- package/src/generators/page/page.js.map +0 -1
- package/src/generators/page/schema.d.ts +0 -13
- package/src/generators/page/schema.json +0 -107
- package/src/migrations/update-12-10-0/fix-page-dir-for-eslint.d.ts +0 -3
- package/src/migrations/update-12-10-0/fix-page-dir-for-eslint.js +0 -34
- package/src/migrations/update-12-10-0/fix-page-dir-for-eslint.js.map +0 -1
- package/src/migrations/update-12-8-0/remove-styled-jsx-babel-plugin.d.ts +0 -3
- package/src/migrations/update-12-8-0/remove-styled-jsx-babel-plugin.js +0 -26
- package/src/migrations/update-12-8-0/remove-styled-jsx-babel-plugin.js.map +0 -1
- package/src/migrations/update-13-0-0/update-emotion-setup.d.ts +0 -3
- package/src/migrations/update-13-0-0/update-emotion-setup.js +0 -39
- package/src/migrations/update-13-0-0/update-emotion-setup.js.map +0 -1
- package/src/migrations/update-13-0-0/update-to-webpack-5.d.ts +0 -3
- package/src/migrations/update-13-0-0/update-to-webpack-5.js +0 -32
- package/src/migrations/update-13-0-0/update-to-webpack-5.js.map +0 -1
- package/src/migrations/update-13-0-3/fix-less.d.ts +0 -3
- package/src/migrations/update-13-0-3/fix-less.js +0 -27
- package/src/migrations/update-13-0-3/fix-less.js.map +0 -1
- package/src/migrations/update-13-1-1/enable-swc.d.ts +0 -3
- package/src/migrations/update-13-1-1/enable-swc.js +0 -46
- package/src/migrations/update-13-1-1/enable-swc.js.map +0 -1
- package/src/migrations/update-14-0-0/add-default-development-configurations.d.ts +0 -3
- package/src/migrations/update-14-0-0/add-default-development-configurations.js +0 -36
- package/src/migrations/update-14-0-0/add-default-development-configurations.js.map +0 -1
- package/src/migrations/update-14-4-3/add-dev-output-path.d.ts +0 -3
- package/src/migrations/update-14-4-3/add-dev-output-path.js +0 -24
- package/src/migrations/update-14-4-3/add-dev-output-path.js.map +0 -1
- package/src/migrations/update-14-5-3/add-gitignore-entry.d.ts +0 -3
- package/src/migrations/update-14-5-3/add-gitignore-entry.js +0 -15
- package/src/migrations/update-14-5-3/add-gitignore-entry.js.map +0 -1
- package/src/migrations/update-14-5-3/update-dev-output-path.d.ts +0 -3
- package/src/migrations/update-14-5-3/update-dev-output-path.js +0 -29
- package/src/migrations/update-14-5-3/update-dev-output-path.js.map +0 -1
- package/src/migrations/update-14-5-7/update-next-eslint.d.ts +0 -3
- package/src/migrations/update-14-5-7/update-next-eslint.js +0 -32
- package/src/migrations/update-14-5-7/update-next-eslint.js.map +0 -1
- package/src/migrations/update-15-8-8/add-style-packages.d.ts +0 -3
- package/src/migrations/update-15-8-8/add-style-packages.js +0 -28
- package/src/migrations/update-15-8-8/add-style-packages.js.map +0 -1
- package/src/utils/add-gitignore-entry.d.ts +0 -2
- package/src/utils/add-gitignore-entry.js +0 -18
- package/src/utils/add-gitignore-entry.js.map +0 -1
- package/src/utils/config-invalid-function.fixture.d.ts +0 -0
- package/src/utils/config-invalid-function.fixture.js +0 -2
- package/src/utils/config-invalid-function.fixture.js.map +0 -1
- package/src/utils/config-not-a-function.fixture.d.ts +0 -0
- package/src/utils/config-not-a-function.fixture.js +0 -2
- package/src/utils/config-not-a-function.fixture.js.map +0 -1
- package/src/utils/config.d.ts +0 -4
- package/src/utils/config.fixture.d.ts +0 -0
- package/src/utils/config.fixture.js +0 -4
- package/src/utils/config.fixture.js.map +0 -1
- package/src/utils/config.js +0 -65
- package/src/utils/config.js.map +0 -1
- package/src/utils/constants.d.ts +0 -1
- package/src/utils/constants.js +0 -5
- package/src/utils/constants.js.map +0 -1
- package/src/utils/create-copy-plugin.d.ts +0 -2
- package/src/utils/create-copy-plugin.js +0 -63
- package/src/utils/create-copy-plugin.js.map +0 -1
- package/src/utils/generate-globs.d.ts +0 -5
- package/src/utils/generate-globs.js +0 -30
- package/src/utils/generate-globs.js.map +0 -1
- package/src/utils/styles.d.ts +0 -40
- package/src/utils/styles.js +0 -56
- package/src/utils/styles.js.map +0 -1
- package/src/utils/types.d.ts +0 -57
- package/src/utils/types.js +0 -3
- package/src/utils/types.js.map +0 -1
- package/src/utils/versions.d.ts +0 -9
- package/src/utils/versions.js +0 -13
- package/src/utils/versions.js.map +0 -1
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.fixPageDirForEslint = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function fixPageDirForEslint(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
projects.forEach((project) => {
|
|
10
|
-
var _a, _b;
|
|
11
|
-
const eslintRcJson = (0, devkit_1.joinPathFragments)(project.root, '.eslintrc.json');
|
|
12
|
-
if (host.exists(eslintRcJson)) {
|
|
13
|
-
const config = (0, devkit_1.readJson)(host, eslintRcJson);
|
|
14
|
-
// Ignore non-nextjs projects
|
|
15
|
-
if (!((_a = config === null || config === void 0 ? void 0 : config.extends) === null || _a === void 0 ? void 0 : _a.includes('next')))
|
|
16
|
-
return;
|
|
17
|
-
// Find the override that handles both TS and JS files.
|
|
18
|
-
const commonOverride = (_b = config.overrides) === null || _b === void 0 ? void 0 : _b.find((o) => ['*.ts', '*.tsx', '*.js', '*.jsx'].every((ext) => o.files.includes(ext)));
|
|
19
|
-
if (commonOverride &&
|
|
20
|
-
!commonOverride.rules['@next/next/no-html-link-for-pages']) {
|
|
21
|
-
commonOverride.rules = Object.assign(Object.assign({}, commonOverride.rules), { '@next/next/no-html-link-for-pages': [
|
|
22
|
-
'error',
|
|
23
|
-
`${project.root}/pages`,
|
|
24
|
-
] });
|
|
25
|
-
(0, devkit_1.writeJson)(host, eslintRcJson, config);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
30
|
-
});
|
|
31
|
-
}
|
|
32
|
-
exports.fixPageDirForEslint = fixPageDirForEslint;
|
|
33
|
-
exports.default = fixPageDirForEslint;
|
|
34
|
-
//# sourceMappingURL=fix-page-dir-for-eslint.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fix-page-dir-for-eslint.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-12-10-0/fix-page-dir-for-eslint.ts"],"names":[],"mappings":";;;;AAAA,yCAOsB;AAEtB,SAAsB,mBAAmB,CAAC,IAAU;;QAClD,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;;YAC3B,MAAM,YAAY,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;YACvE,IAAI,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,EAAE;gBAC7B,MAAM,MAAM,GAAG,IAAA,iBAAQ,EAAC,IAAI,EAAE,YAAY,CAAC,CAAC;gBAC5C,6BAA6B;gBAC7B,IAAI,CAAC,CAAA,MAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,OAAO,0CAAE,QAAQ,CAAC,MAAM,CAAC,CAAA;oBAAE,OAAO;gBAE/C,uDAAuD;gBACvD,MAAM,cAAc,GAAG,MAAA,MAAM,CAAC,SAAS,0CAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAClD,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CACzE,CAAC;gBAEF,IACE,cAAc;oBACd,CAAC,cAAc,CAAC,KAAK,CAAC,mCAAmC,CAAC,EAC1D;oBACA,cAAc,CAAC,KAAK,mCACf,cAAc,CAAC,KAAK,KACvB,mCAAmC,EAAE;4BACnC,OAAO;4BACP,GAAG,OAAO,CAAC,IAAI,QAAQ;yBACxB,GACF,CAAC;oBAEF,IAAA,kBAAS,EAAC,IAAI,EAAE,YAAY,EAAE,MAAM,CAAC,CAAC;iBACvC;aACF;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AAjCD,kDAiCC;AAED,kBAAe,mBAAmB,CAAC"}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.removeStyledJsxBabelConfig = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function removeStyledJsxBabelConfig(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
projects.forEach((project) => {
|
|
10
|
-
const babelRcPath = (0, devkit_1.joinPathFragments)(project.root, '.babelrc');
|
|
11
|
-
if (host.exists(babelRcPath)) {
|
|
12
|
-
const babelRcContent = (0, devkit_1.readJson)(host, babelRcPath);
|
|
13
|
-
// check whether next.js project
|
|
14
|
-
if (babelRcContent.presets.includes('next/babel')) {
|
|
15
|
-
babelRcContent.plugins = babelRcContent.plugins.filter((x) => x !== 'styled-jsx/babel');
|
|
16
|
-
// update .babelrc
|
|
17
|
-
(0, devkit_1.writeJson)(host, babelRcPath, babelRcContent);
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
22
|
-
});
|
|
23
|
-
}
|
|
24
|
-
exports.removeStyledJsxBabelConfig = removeStyledJsxBabelConfig;
|
|
25
|
-
exports.default = removeStyledJsxBabelConfig;
|
|
26
|
-
//# sourceMappingURL=remove-styled-jsx-babel-plugin.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"remove-styled-jsx-babel-plugin.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-12-8-0/remove-styled-jsx-babel-plugin.ts"],"names":[],"mappings":";;;;AAAA,yCAOsB;AAEtB,SAAsB,0BAA0B,CAAC,IAAU;;QACzD,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC3B,MAAM,WAAW,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,UAAU,CAAC,CAAC;YAChE,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,EAAE;gBAC5B,MAAM,cAAc,GAAG,IAAA,iBAAQ,EAAC,IAAI,EAAE,WAAW,CAAC,CAAC;gBAEnD,gCAAgC;gBAChC,IAAI,cAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,EAAE;oBACjD,cAAc,CAAC,OAAO,GAAG,cAAc,CAAC,OAAO,CAAC,MAAM,CACpD,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,kBAAkB,CAChC,CAAC;oBAEF,kBAAkB;oBAClB,IAAA,kBAAS,EAAC,IAAI,EAAE,WAAW,EAAE,cAAc,CAAC,CAAC;iBAC9C;aACF;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AArBD,gEAqBC;AAED,kBAAe,0BAA0B,CAAC"}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.updateEmotionSetup = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function updateEmotionSetup(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
projects.forEach((p) => {
|
|
10
|
-
let hasEmotion = false;
|
|
11
|
-
const babelrcPath = `${p.root}/.babelrc`;
|
|
12
|
-
const tsConfigPath = `${p.root}/tsconfig.json`;
|
|
13
|
-
if (host.exists(babelrcPath)) {
|
|
14
|
-
const babelrc = (0, devkit_1.readJson)(host, babelrcPath);
|
|
15
|
-
if (babelrc.presets) {
|
|
16
|
-
for (const [idx, preset] of babelrc.presets.entries()) {
|
|
17
|
-
if (Array.isArray(preset)) {
|
|
18
|
-
if (!preset[0].includes('@nrwl/next/babel'))
|
|
19
|
-
continue;
|
|
20
|
-
const emotionOptions = preset[1]['preset-react'];
|
|
21
|
-
hasEmotion = (emotionOptions === null || emotionOptions === void 0 ? void 0 : emotionOptions.importSource) === '@emotion/react';
|
|
22
|
-
break;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
if (hasEmotion && host.exists(tsConfigPath)) {
|
|
28
|
-
(0, devkit_1.updateJson)(host, tsConfigPath, (json) => {
|
|
29
|
-
json.compilerOptions.jsxImportSource = '@emotion/react';
|
|
30
|
-
return json;
|
|
31
|
-
});
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
exports.updateEmotionSetup = updateEmotionSetup;
|
|
38
|
-
exports.default = updateEmotionSetup;
|
|
39
|
-
//# sourceMappingURL=update-emotion-setup.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-emotion-setup.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-13-0-0/update-emotion-setup.ts"],"names":[],"mappings":";;;;AAAA,yCAMsB;AAEtB,SAAsB,kBAAkB,CAAC,IAAU;;QACjD,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE;YACrB,IAAI,UAAU,GAAG,KAAK,CAAC;YACvB,MAAM,WAAW,GAAG,GAAG,CAAC,CAAC,IAAI,WAAW,CAAC;YACzC,MAAM,YAAY,GAAG,GAAG,CAAC,CAAC,IAAI,gBAAgB,CAAC;YAE/C,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,EAAE;gBAC5B,MAAM,OAAO,GAAG,IAAA,iBAAQ,EAAC,IAAI,EAAE,WAAW,CAAC,CAAC;gBAC5C,IAAI,OAAO,CAAC,OAAO,EAAE;oBACnB,KAAK,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,IAAI,OAAO,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE;wBACrD,IAAI,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE;4BACzB,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,kBAAkB,CAAC;gCAAE,SAAS;4BACtD,MAAM,cAAc,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC;4BACjD,UAAU,GAAG,CAAA,cAAc,aAAd,cAAc,uBAAd,cAAc,CAAE,YAAY,MAAK,gBAAgB,CAAC;4BAC/D,MAAM;yBACP;qBACF;iBACF;aACF;YAED,IAAI,UAAU,IAAI,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,EAAE;gBAC3C,IAAA,mBAAU,EAAC,IAAI,EAAE,YAAY,EAAE,CAAC,IAAI,EAAE,EAAE;oBACtC,IAAI,CAAC,eAAe,CAAC,eAAe,GAAG,gBAAgB,CAAC;oBACxD,OAAO,IAAI,CAAC;gBACd,CAAC,CAAC,CAAC;aACJ;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AA/BD,gDA+BC;AAED,kBAAe,kBAAkB,CAAC"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
let task = undefined;
|
|
10
|
-
projects.forEach((project) => {
|
|
11
|
-
const configPath = (0, devkit_1.joinPathFragments)(project.root, 'next.config.js');
|
|
12
|
-
if (!host.exists(configPath))
|
|
13
|
-
return;
|
|
14
|
-
const content = host.read(configPath).toString();
|
|
15
|
-
let updated = content.replace(/webpack5: false/, 'webpack5: true');
|
|
16
|
-
if (content.match(/@zeit\/next-less/)) {
|
|
17
|
-
updated = updated.replace('@zeit/next-less', 'next-with-less');
|
|
18
|
-
task = (0, devkit_1.addDependenciesToPackageJson)(host, { 'next-with-less': '1.0.1' }, {});
|
|
19
|
-
}
|
|
20
|
-
if (content.match(/@zeit\/next-stylus/)) {
|
|
21
|
-
updated = updated.replace('@zeit/next-stylus', '@nrwl/next/plugins/with-stylus');
|
|
22
|
-
task = (0, devkit_1.addDependenciesToPackageJson)(host, { 'stylus-loader': '6.2.0' }, {});
|
|
23
|
-
}
|
|
24
|
-
host.write(configPath, updated);
|
|
25
|
-
});
|
|
26
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
27
|
-
return task;
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
exports.update = update;
|
|
31
|
-
exports.default = update;
|
|
32
|
-
//# sourceMappingURL=update-to-webpack-5.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-to-webpack-5.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-13-0-0/update-to-webpack-5.ts"],"names":[],"mappings":";;;;AAAA,yCAOsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QACnC,IAAI,IAAI,GAAkC,SAAS,CAAC;QAEpD,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC3B,MAAM,UAAU,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;YAErE,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC;gBAAE,OAAO;YAErC,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,QAAQ,EAAE,CAAC;YACjD,IAAI,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,iBAAiB,EAAE,gBAAgB,CAAC,CAAC;YAEnE,IAAI,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,EAAE;gBACrC,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,iBAAiB,EAAE,gBAAgB,CAAC,CAAC;gBAC/D,IAAI,GAAG,IAAA,qCAA4B,EACjC,IAAI,EACJ,EAAE,gBAAgB,EAAE,OAAO,EAAE,EAC7B,EAAE,CACH,CAAC;aACH;YAED,IAAI,OAAO,CAAC,KAAK,CAAC,oBAAoB,CAAC,EAAE;gBACvC,OAAO,GAAG,OAAO,CAAC,OAAO,CACvB,mBAAmB,EACnB,gCAAgC,CACjC,CAAC;gBACF,IAAI,GAAG,IAAA,qCAA4B,EACjC,IAAI,EACJ,EAAE,eAAe,EAAE,OAAO,EAAE,EAC5B,EAAE,CACH,CAAC;aACH;YAED,IAAI,CAAC,KAAK,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;QAClC,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAExB,OAAO,IAAI,CAAC;IACd,CAAC;CAAA;AAvCD,wBAuCC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
let task = undefined;
|
|
10
|
-
projects.forEach((project) => {
|
|
11
|
-
const configPath = (0, devkit_1.joinPathFragments)(project.root, 'next.config.js');
|
|
12
|
-
if (!host.exists(configPath))
|
|
13
|
-
return;
|
|
14
|
-
const content = host.read(configPath).toString();
|
|
15
|
-
if (content.match(/next-with-less/)) {
|
|
16
|
-
const updated = content.replace('next-with-less', '@nrwl/next/plugins/with-less');
|
|
17
|
-
task = (0, devkit_1.addDependenciesToPackageJson)(host, { 'less-loader': '10.2.0' }, {});
|
|
18
|
-
host.write(configPath, updated);
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
22
|
-
return task;
|
|
23
|
-
});
|
|
24
|
-
}
|
|
25
|
-
exports.update = update;
|
|
26
|
-
exports.default = update;
|
|
27
|
-
//# sourceMappingURL=fix-less.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fix-less.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-13-0-3/fix-less.ts"],"names":[],"mappings":";;;;AAAA,yCAOsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QACnC,IAAI,IAAI,GAAkC,SAAS,CAAC;QAEpD,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC3B,MAAM,UAAU,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;YAErE,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC;gBAAE,OAAO;YAErC,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,QAAQ,EAAE,CAAC;YAEjD,IAAI,OAAO,CAAC,KAAK,CAAC,gBAAgB,CAAC,EAAE;gBACnC,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAC7B,gBAAgB,EAChB,8BAA8B,CAC/B,CAAC;gBACF,IAAI,GAAG,IAAA,qCAA4B,EACjC,IAAI,EACJ,EAAE,aAAa,EAAE,QAAQ,EAAE,EAC3B,EAAE,CACH,CAAC;gBACF,IAAI,CAAC,KAAK,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;aACjC;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAExB,OAAO,IAAI,CAAC;IACd,CAAC;CAAA;AA5BD,wBA4BC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
projects.forEach((project) => {
|
|
10
|
-
const nextConfigPath = (0, devkit_1.joinPathFragments)(project.root, 'next.config.js');
|
|
11
|
-
const jestConfigPath = (0, devkit_1.joinPathFragments)(project.root, 'jest.config.js');
|
|
12
|
-
const babelConfigPath = (0, devkit_1.joinPathFragments)(project.root, '.babelrc');
|
|
13
|
-
const storybookMainPath = (0, devkit_1.joinPathFragments)(project.root, '.storybook/main.js');
|
|
14
|
-
if (!host.exists(nextConfigPath) || !host.exists(jestConfigPath))
|
|
15
|
-
return;
|
|
16
|
-
if (host.exists(babelConfigPath)) {
|
|
17
|
-
if (customBabelConfig(host, babelConfigPath)) {
|
|
18
|
-
devkit_1.logger.info(`NX Custom .babelrc file detected, skipping deletion. You can delete this file yourself to enable SWC: ${babelConfigPath}`);
|
|
19
|
-
}
|
|
20
|
-
else if (host.exists(storybookMainPath)) {
|
|
21
|
-
devkit_1.logger.info(`NX Storybook configuration for project "${project.name}" detected, skipping deletion of .babelrc`);
|
|
22
|
-
}
|
|
23
|
-
else {
|
|
24
|
-
// Deleting custom babel config enables SWC
|
|
25
|
-
host.delete(babelConfigPath);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
const content = host.read(jestConfigPath).toString();
|
|
29
|
-
if (content.match(/:\s+'babel-jest'/)) {
|
|
30
|
-
const updated = content.replace(/:\s+'babel-jest'/, `: ['babel-jest', { presets: ['@nrwl/next/babel'] }]`);
|
|
31
|
-
host.write(jestConfigPath, updated);
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
exports.update = update;
|
|
38
|
-
function customBabelConfig(host, configPath) {
|
|
39
|
-
var _a, _b, _c;
|
|
40
|
-
const json = (0, devkit_1.readJson)(host, configPath);
|
|
41
|
-
return !(((_a = json.presets) === null || _a === void 0 ? void 0 : _a.length) === 1 &&
|
|
42
|
-
((_b = json.presets) === null || _b === void 0 ? void 0 : _b[0]) === '@nrwl/next/babel' &&
|
|
43
|
-
(((_c = json.plugins) === null || _c === void 0 ? void 0 : _c.length) === 0 || !json.plugins));
|
|
44
|
-
}
|
|
45
|
-
exports.default = update;
|
|
46
|
-
//# sourceMappingURL=enable-swc.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"enable-swc.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-13-1-1/enable-swc.ts"],"names":[],"mappings":";;;;AAAA,yCAOsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC3B,MAAM,cAAc,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;YACzE,MAAM,cAAc,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;YACzE,MAAM,eAAe,GAAG,IAAA,0BAAiB,EAAC,OAAO,CAAC,IAAI,EAAE,UAAU,CAAC,CAAC;YACpE,MAAM,iBAAiB,GAAG,IAAA,0BAAiB,EACzC,OAAO,CAAC,IAAI,EACZ,oBAAoB,CACrB,CAAC;YAEF,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC;gBAAE,OAAO;YAEzE,IAAI,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,EAAE;gBAChC,IAAI,iBAAiB,CAAC,IAAI,EAAE,eAAe,CAAC,EAAE;oBAC5C,eAAM,CAAC,IAAI,CACT,yGAAyG,eAAe,EAAE,CAC3H,CAAC;iBACH;qBAAM,IAAI,IAAI,CAAC,MAAM,CAAC,iBAAiB,CAAC,EAAE;oBACzC,eAAM,CAAC,IAAI,CACT,2CAA2C,OAAO,CAAC,IAAI,2CAA2C,CACnG,CAAC;iBACH;qBAAM;oBACL,2CAA2C;oBAC3C,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC;iBAC9B;aACF;YAED,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,QAAQ,EAAE,CAAC;YAErD,IAAI,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,EAAE;gBACrC,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAC7B,kBAAkB,EAClB,qDAAqD,CACtD,CAAC;gBACF,IAAI,CAAC,KAAK,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;aACrC;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AAzCD,wBAyCC;AAED,SAAS,iBAAiB,CAAC,IAAI,EAAE,UAAU;;IACzC,MAAM,IAAI,GAAG,IAAA,iBAAQ,EAAC,IAAI,EAAE,UAAU,CAAC,CAAC;IACxC,OAAO,CAAC,CACN,CAAA,MAAA,IAAI,CAAC,OAAO,0CAAE,MAAM,MAAK,CAAC;QAC1B,CAAA,MAAA,IAAI,CAAC,OAAO,0CAAG,CAAC,CAAC,MAAK,kBAAkB;QACxC,CAAC,CAAA,MAAA,IAAI,CAAC,OAAO,0CAAE,MAAM,MAAK,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAC9C,CAAC;AACJ,CAAC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(tree) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(tree);
|
|
9
|
-
projects.forEach((config, name) => {
|
|
10
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
11
|
-
var _l, _m, _o, _p, _q, _r;
|
|
12
|
-
let shouldUpdate = false;
|
|
13
|
-
if (((_b = (_a = config.targets) === null || _a === void 0 ? void 0 : _a.build) === null || _b === void 0 ? void 0 : _b.executor) === '@nrwl/next:build') {
|
|
14
|
-
shouldUpdate = true;
|
|
15
|
-
(_c = (_l = config.targets.build).defaultConfiguration) !== null && _c !== void 0 ? _c : (_l.defaultConfiguration = 'production');
|
|
16
|
-
(_d = (_m = config.targets.build).configurations) !== null && _d !== void 0 ? _d : (_m.configurations = {});
|
|
17
|
-
(_e = (_o = config.targets.build.configurations).development) !== null && _e !== void 0 ? _e : (_o.development = {});
|
|
18
|
-
}
|
|
19
|
-
if (((_g = (_f = config.targets) === null || _f === void 0 ? void 0 : _f.serve) === null || _g === void 0 ? void 0 : _g.executor) === '@nrwl/next:server') {
|
|
20
|
-
shouldUpdate = true;
|
|
21
|
-
(_h = (_p = config.targets.serve).defaultConfiguration) !== null && _h !== void 0 ? _h : (_p.defaultConfiguration = 'development');
|
|
22
|
-
(_j = (_q = config.targets.serve).configurations) !== null && _j !== void 0 ? _j : (_q.configurations = {});
|
|
23
|
-
(_k = (_r = config.targets.serve.configurations).development) !== null && _k !== void 0 ? _k : (_r.development = {
|
|
24
|
-
buildTarget: `${name}:build:development`,
|
|
25
|
-
dev: true,
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
if (shouldUpdate)
|
|
29
|
-
(0, devkit_1.updateProjectConfiguration)(tree, name, config);
|
|
30
|
-
});
|
|
31
|
-
yield (0, devkit_1.formatFiles)(tree);
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
exports.update = update;
|
|
35
|
-
exports.default = update;
|
|
36
|
-
//# sourceMappingURL=add-default-development-configurations.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"add-default-development-configurations.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-14-0-0/add-default-development-configurations.ts"],"names":[],"mappings":";;;;AAAA,yCAKsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE;;;YAChC,IAAI,YAAY,GAAG,KAAK,CAAC;YACzB,IAAI,CAAA,MAAA,MAAA,MAAM,CAAC,OAAO,0CAAE,KAAK,0CAAE,QAAQ,MAAK,kBAAkB,EAAE;gBAC1D,YAAY,GAAG,IAAI,CAAC;gBACpB,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,EAAC,oBAAoB,uCAApB,oBAAoB,GAAK,YAAY,EAAC;gBAC3D,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,EAAC,cAAc,uCAAd,cAAc,GAAK,EAAE,EAAC;gBAC3C,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,EAAC,WAAW,uCAAX,WAAW,GAAK,EAAE,EAAC;aACxD;YAED,IAAI,CAAA,MAAA,MAAA,MAAM,CAAC,OAAO,0CAAE,KAAK,0CAAE,QAAQ,MAAK,mBAAmB,EAAE;gBAC3D,YAAY,GAAG,IAAI,CAAC;gBACpB,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,EAAC,oBAAoB,uCAApB,oBAAoB,GAAK,aAAa,EAAC;gBAC5D,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,EAAC,cAAc,uCAAd,cAAc,GAAK,EAAE,EAAC;gBAC3C,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,EAAC,WAAW,uCAAX,WAAW,GAAK;oBAClD,WAAW,EAAE,GAAG,IAAI,oBAAoB;oBACxC,GAAG,EAAE,IAAI;iBACV,EAAC;aACH;YAED,IAAI,YAAY;gBAAE,IAAA,mCAA0B,EAAC,IAAI,EAAE,IAAI,EAAE,MAAM,CAAC,CAAC;QACnE,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AA1BD,wBA0BC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(tree) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(tree);
|
|
9
|
-
projects.forEach((config, name) => {
|
|
10
|
-
var _a, _b, _c, _d, _e;
|
|
11
|
-
var _f, _g, _h;
|
|
12
|
-
if (((_b = (_a = config.targets) === null || _a === void 0 ? void 0 : _a.build) === null || _b === void 0 ? void 0 : _b.executor) === '@nrwl/next:build') {
|
|
13
|
-
(_c = (_f = config.targets.build).configurations) !== null && _c !== void 0 ? _c : (_f.configurations = {});
|
|
14
|
-
(_d = (_g = config.targets.build.configurations).development) !== null && _d !== void 0 ? _d : (_g.development = {});
|
|
15
|
-
(_e = (_h = config.targets.build.configurations.development).outputPath) !== null && _e !== void 0 ? _e : (_h.outputPath = (0, devkit_1.joinPathFragments)('tmp', config.sourceRoot));
|
|
16
|
-
(0, devkit_1.updateProjectConfiguration)(tree, name, config);
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
yield (0, devkit_1.formatFiles)(tree);
|
|
20
|
-
});
|
|
21
|
-
}
|
|
22
|
-
exports.update = update;
|
|
23
|
-
exports.default = update;
|
|
24
|
-
//# sourceMappingURL=add-dev-output-path.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"add-dev-output-path.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-14-4-3/add-dev-output-path.ts"],"names":[],"mappings":";;;;AAAA,yCAMsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE;;;YAChC,IAAI,CAAA,MAAA,MAAA,MAAM,CAAC,OAAO,0CAAE,KAAK,0CAAE,QAAQ,MAAK,kBAAkB,EAAE;gBAC1D,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,EAAC,cAAc,uCAAd,cAAc,GAAK,EAAE,EAAC;gBAC3C,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,EAAC,WAAW,uCAAX,WAAW,GAAK,EAAE,EAAC;gBACvD,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,EAAC,UAAU,uCAAV,UAAU,GACxD,IAAA,0BAAiB,EAAC,KAAK,EAAE,MAAM,CAAC,UAAU,CAAC,EAAC;gBAC9C,IAAA,mCAA0B,EAAC,IAAI,EAAE,IAAI,EAAE,MAAM,CAAC,CAAC;aAChD;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AAdD,wBAcC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
const add_gitignore_entry_1 = require("../../utils/add-gitignore-entry");
|
|
7
|
-
function update(tree) {
|
|
8
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
9
|
-
(0, add_gitignore_entry_1.addGitIgnoreEntry)(tree);
|
|
10
|
-
yield (0, devkit_1.formatFiles)(tree);
|
|
11
|
-
});
|
|
12
|
-
}
|
|
13
|
-
exports.update = update;
|
|
14
|
-
exports.default = update;
|
|
15
|
-
//# sourceMappingURL=add-gitignore-entry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"add-gitignore-entry.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-14-5-3/add-gitignore-entry.ts"],"names":[],"mappings":";;;;AAAA,yCAAiD;AACjD,yEAAoE;AAEpE,SAAsB,MAAM,CAAC,IAAU;;QACrC,IAAA,uCAAiB,EAAC,IAAI,CAAC,CAAC;QACxB,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AAHD,wBAGC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(tree) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(tree);
|
|
9
|
-
projects.forEach((config, name) => {
|
|
10
|
-
var _a, _b, _c, _d;
|
|
11
|
-
var _e, _f;
|
|
12
|
-
if (((_b = (_a = config.targets) === null || _a === void 0 ? void 0 : _a.build) === null || _b === void 0 ? void 0 : _b.executor) === '@nrwl/next:build') {
|
|
13
|
-
(_c = (_e = config.targets.build).configurations) !== null && _c !== void 0 ? _c : (_e.configurations = {});
|
|
14
|
-
(_d = (_f = config.targets.build.configurations).development) !== null && _d !== void 0 ? _d : (_f.development = {});
|
|
15
|
-
if (!config.targets.build.configurations.development.outputPath ||
|
|
16
|
-
config.targets.build.configurations.development.outputPath ===
|
|
17
|
-
(0, devkit_1.joinPathFragments)('tmp', config.root)) {
|
|
18
|
-
config.targets.build.configurations.development.outputPath =
|
|
19
|
-
config.root;
|
|
20
|
-
(0, devkit_1.updateProjectConfiguration)(tree, name, config);
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
|
-
yield (0, devkit_1.formatFiles)(tree);
|
|
25
|
-
});
|
|
26
|
-
}
|
|
27
|
-
exports.update = update;
|
|
28
|
-
exports.default = update;
|
|
29
|
-
//# sourceMappingURL=update-dev-output-path.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-dev-output-path.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-14-5-3/update-dev-output-path.ts"],"names":[],"mappings":";;;;AAAA,yCAMsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE;;;YAChC,IAAI,CAAA,MAAA,MAAA,MAAM,CAAC,OAAO,0CAAE,KAAK,0CAAE,QAAQ,MAAK,kBAAkB,EAAE;gBAC1D,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,EAAC,cAAc,uCAAd,cAAc,GAAK,EAAE,EAAC;gBAC3C,YAAA,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,EAAC,WAAW,uCAAX,WAAW,GAAK,EAAE,EAAC;gBACvD,IACE,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,UAAU;oBAC3D,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,UAAU;wBACxD,IAAA,0BAAiB,EAAC,KAAK,EAAE,MAAM,CAAC,IAAI,CAAC,EACvC;oBACA,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,UAAU;wBACxD,MAAM,CAAC,IAAI,CAAC;oBACd,IAAA,mCAA0B,EAAC,IAAI,EAAE,IAAI,EAAE,MAAM,CAAC,CAAC;iBAChD;aACF;QACH,CAAC,CAAC,CAAC;QAEH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AApBD,wBAoBC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.updateNextEslint = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function updateNextEslint(host) {
|
|
7
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
8
|
-
const projects = (0, devkit_1.getProjects)(host);
|
|
9
|
-
projects.forEach((project) => {
|
|
10
|
-
var _a, _b;
|
|
11
|
-
if (((_b = (_a = project.targets) === null || _a === void 0 ? void 0 : _a.build) === null || _b === void 0 ? void 0 : _b.executor) !== '@nrwl/next:build')
|
|
12
|
-
return;
|
|
13
|
-
const eslintPath = `${project.root}/.eslintrc.json`;
|
|
14
|
-
if (!host.exists(eslintPath))
|
|
15
|
-
return;
|
|
16
|
-
(0, devkit_1.updateJson)(host, eslintPath, (eslintConfig) => {
|
|
17
|
-
const nextIgnorePattern = '.next/**/*';
|
|
18
|
-
if (eslintConfig.ignorePatterns.indexOf(nextIgnorePattern) < 0) {
|
|
19
|
-
eslintConfig.ignorePatterns = [
|
|
20
|
-
...eslintConfig.ignorePatterns,
|
|
21
|
-
nextIgnorePattern,
|
|
22
|
-
];
|
|
23
|
-
}
|
|
24
|
-
return eslintConfig;
|
|
25
|
-
});
|
|
26
|
-
});
|
|
27
|
-
yield (0, devkit_1.formatFiles)(host);
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
exports.updateNextEslint = updateNextEslint;
|
|
31
|
-
exports.default = updateNextEslint;
|
|
32
|
-
//# sourceMappingURL=update-next-eslint.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-next-eslint.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-14-5-7/update-next-eslint.ts"],"names":[],"mappings":";;;;AAAA,yCAA0E;AAE1E,SAAsB,gBAAgB,CAAC,IAAU;;QAC/C,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QAEnC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;;YAC3B,IAAI,CAAA,MAAA,MAAA,OAAO,CAAC,OAAO,0CAAE,KAAK,0CAAE,QAAQ,MAAK,kBAAkB;gBAAE,OAAO;YAEpE,MAAM,UAAU,GAAG,GAAG,OAAO,CAAC,IAAI,iBAAiB,CAAC;YAEpD,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC;gBAAE,OAAO;YAErC,IAAA,mBAAU,EAAC,IAAI,EAAE,UAAU,EAAE,CAAC,YAAY,EAAE,EAAE;gBAC5C,MAAM,iBAAiB,GAAG,YAAY,CAAC;gBAEvC,IAAI,YAAY,CAAC,cAAc,CAAC,OAAO,CAAC,iBAAiB,CAAC,GAAG,CAAC,EAAE;oBAC9D,YAAY,CAAC,cAAc,GAAG;wBAC5B,GAAG,YAAY,CAAC,cAAc;wBAC9B,iBAAiB;qBAClB,CAAC;iBACH;gBACD,OAAO,YAAY,CAAC;YACtB,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;QACH,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CAAA;AAvBD,4CAuBC;AAED,kBAAe,gBAAgB,CAAC"}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.update = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const devkit_1 = require("@nrwl/devkit");
|
|
6
|
-
function update(tree) {
|
|
7
|
-
var _a, _b;
|
|
8
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
9
|
-
const projects = (0, devkit_1.getProjects)(tree);
|
|
10
|
-
const missingDeps = {};
|
|
11
|
-
for (const [, config] of projects) {
|
|
12
|
-
if (((_b = (_a = config.targets) === null || _a === void 0 ? void 0 : _a.build) === null || _b === void 0 ? void 0 : _b.executor) === '@nrwl/next:build' &&
|
|
13
|
-
tree.exists((0, devkit_1.joinPathFragments)(config.root, 'next.config.js'))) {
|
|
14
|
-
const nextConfigContent = tree.read((0, devkit_1.joinPathFragments)(config.root, 'next.config.js'), 'utf-8');
|
|
15
|
-
if (nextConfigContent.includes('@nrwl/next/plugins/with-less')) {
|
|
16
|
-
missingDeps['less'] = '3.12.2';
|
|
17
|
-
}
|
|
18
|
-
if (nextConfigContent.includes('@nrwl/next/plugins/with-stylus')) {
|
|
19
|
-
missingDeps['stylus'] = '^0.55.0';
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
return (0, devkit_1.addDependenciesToPackageJson)(tree, {}, missingDeps);
|
|
24
|
-
});
|
|
25
|
-
}
|
|
26
|
-
exports.update = update;
|
|
27
|
-
exports.default = update;
|
|
28
|
-
//# sourceMappingURL=add-style-packages.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"add-style-packages.js","sourceRoot":"","sources":["../../../../../../packages/next/src/migrations/update-15-8-8/add-style-packages.ts"],"names":[],"mappings":";;;;AAAA,yCAKsB;AAEtB,SAAsB,MAAM,CAAC,IAAU;;;QACrC,MAAM,QAAQ,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;QACnC,MAAM,WAAW,GAAG,EAAE,CAAC;QAEvB,KAAK,MAAM,CAAC,EAAE,MAAM,CAAC,IAAI,QAAQ,EAAE;YACjC,IACE,CAAA,MAAA,MAAA,MAAM,CAAC,OAAO,0CAAE,KAAK,0CAAE,QAAQ,MAAK,kBAAkB;gBACtD,IAAI,CAAC,MAAM,CAAC,IAAA,0BAAiB,EAAC,MAAM,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC,EAC7D;gBACA,MAAM,iBAAiB,GAAG,IAAI,CAAC,IAAI,CACjC,IAAA,0BAAiB,EAAC,MAAM,CAAC,IAAI,EAAE,gBAAgB,CAAC,EAChD,OAAO,CACR,CAAC;gBAEF,IAAI,iBAAiB,CAAC,QAAQ,CAAC,8BAA8B,CAAC,EAAE;oBAC9D,WAAW,CAAC,MAAM,CAAC,GAAG,QAAQ,CAAC;iBAChC;gBAED,IAAI,iBAAiB,CAAC,QAAQ,CAAC,gCAAgC,CAAC,EAAE;oBAChE,WAAW,CAAC,QAAQ,CAAC,GAAG,SAAS,CAAC;iBACnC;aACF;SACF;QAED,OAAO,IAAA,qCAA4B,EAAC,IAAI,EAAE,EAAE,EAAE,WAAW,CAAC,CAAC;;CAC5D;AAzBD,wBAyBC;AAED,kBAAe,MAAM,CAAC"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.addGitIgnoreEntry = void 0;
|
|
4
|
-
const ignore_1 = require("ignore");
|
|
5
|
-
function addGitIgnoreEntry(host) {
|
|
6
|
-
if (!host.exists('.gitignore')) {
|
|
7
|
-
return;
|
|
8
|
-
}
|
|
9
|
-
let content = host.read('.gitignore', 'utf-8').trimEnd();
|
|
10
|
-
const ig = (0, ignore_1.default)();
|
|
11
|
-
ig.add(host.read('.gitignore', 'utf-8'));
|
|
12
|
-
if (!ig.ignores('apps/example/.next')) {
|
|
13
|
-
content = `${content}\n\n# Next.js\n.next\n`;
|
|
14
|
-
}
|
|
15
|
-
host.write('.gitignore', content);
|
|
16
|
-
}
|
|
17
|
-
exports.addGitIgnoreEntry = addGitIgnoreEntry;
|
|
18
|
-
//# sourceMappingURL=add-gitignore-entry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"add-gitignore-entry.js","sourceRoot":"","sources":["../../../../../packages/next/src/utils/add-gitignore-entry.ts"],"names":[],"mappings":";;;AACA,mCAA4B;AAE5B,SAAgB,iBAAiB,CAAC,IAAU;IAC1C,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,EAAE;QAC9B,OAAO;KACR;IAED,IAAI,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC,OAAO,EAAE,CAAC;IAEzD,MAAM,EAAE,GAAG,IAAA,gBAAM,GAAE,CAAC;IACpB,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC,CAAC;IAEzC,IAAI,CAAC,EAAE,CAAC,OAAO,CAAC,oBAAoB,CAAC,EAAE;QACrC,OAAO,GAAG,GAAG,OAAO,wBAAwB,CAAC;KAC9C;IAED,IAAI,CAAC,KAAK,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC;AACpC,CAAC;AAfD,8CAeC"}
|
|
File without changes
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config-invalid-function.fixture.js","sourceRoot":"","sources":["../../../../../packages/next/src/utils/config-invalid-function.fixture.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,GAAG,GAAG,EAAE,GAAE,CAAC,CAAC"}
|
|
File without changes
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config-not-a-function.fixture.js","sourceRoot":"","sources":["../../../../../packages/next/src/utils/config-not-a-function.fixture.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,GAAG,KAAK,CAAC"}
|
package/src/utils/config.d.ts
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { Configuration } from 'webpack';
|
|
2
|
-
import { FileReplacement } from './types';
|
|
3
|
-
import { DependentBuildableProjectNode } from '@nrwl/js/src/utils/buildable-libs-utils';
|
|
4
|
-
export declare function createWebpackConfig(workspaceRoot: string, projectRoot: string, fileReplacements?: FileReplacement[], assets?: any, dependencies?: DependentBuildableProjectNode[], libsDir?: string): (a: any, b: any) => Configuration;
|
|
File without changes
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config.fixture.js","sourceRoot":"","sources":["../../../../../packages/next/src/utils/config.fixture.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE;IAC1C,uCACK,MAAM,KACT,OAAO,EAAE,KAAK,EACd,aAAa,EAAE,OAAO,CAAC,OAAO,CAAC,WAAW,IAC1C;AACJ,CAAC,CAAC"}
|