@nrwl/next 14.3.5 → 14.4.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/CHANGELOG.md +1 -1
- package/package.json +9 -9
- package/src/executors/build/lib/create-package-json.js +2 -2
- package/src/executors/build/lib/create-package-json.js.map +1 -1
- package/src/generators/application/lib/add-linting.js +4 -1
- package/src/generators/application/lib/add-linting.js.map +1 -1
- package/src/generators/application/lib/create-application-files.helpers.js +1 -1
- package/tailwind.d.ts +2 -6
- package/tailwind.js +3 -25
- package/tailwind.js.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,6 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
# [14.4.0-beta.1](https://github.com/nrwl/nx/compare/14.3.6...14.4.0-beta.1) (2022-06-24)
|
|
7
7
|
|
|
8
8
|
**Note:** Version bump only for package @nrwl/next
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nrwl/next",
|
|
3
|
-
"version": "14.
|
|
3
|
+
"version": "14.4.0-beta.1",
|
|
4
4
|
"description": "When using Next.js in Nx, you get the out-of-the-box support for TypeScript, Cypress, and Jest. No need to configure anything: watch mode, source maps, and typings just work.\n\nThe Next.js plugin contains executors and generators for managing Next.js applications and libraries within an Nx workspace. It provides:\n\n\n- Scaffolding for creating, building, serving, linting, and testing Next.js applications.\n\n- Integration with building, serving, and exporting a Next.js application.\n\n- Integration with React libraries within the workspace.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,13 +34,13 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@babel/plugin-proposal-decorators": "^7.14.5",
|
|
37
|
-
"@nrwl/cypress": "14.
|
|
38
|
-
"@nrwl/devkit": "14.
|
|
39
|
-
"@nrwl/jest": "14.
|
|
40
|
-
"@nrwl/linter": "14.
|
|
41
|
-
"@nrwl/react": "14.
|
|
42
|
-
"@nrwl/web": "14.
|
|
43
|
-
"@nrwl/workspace": "14.
|
|
37
|
+
"@nrwl/cypress": "14.4.0-beta.1",
|
|
38
|
+
"@nrwl/devkit": "14.4.0-beta.1",
|
|
39
|
+
"@nrwl/jest": "14.4.0-beta.1",
|
|
40
|
+
"@nrwl/linter": "14.4.0-beta.1",
|
|
41
|
+
"@nrwl/react": "14.4.0-beta.1",
|
|
42
|
+
"@nrwl/web": "14.4.0-beta.1",
|
|
43
|
+
"@nrwl/workspace": "14.4.0-beta.1",
|
|
44
44
|
"@svgr/webpack": "^6.1.2",
|
|
45
45
|
"chalk": "4.1.0",
|
|
46
46
|
"eslint-config-next": "^12.1.0",
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
"url-loader": "^4.1.1",
|
|
51
51
|
"webpack-merge": "^5.8.0"
|
|
52
52
|
},
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "5b905140089128a21e5e77081958ae7fe6ba14bf"
|
|
54
54
|
}
|
|
@@ -19,12 +19,12 @@ function createPackageJson(options, context) {
|
|
|
19
19
|
if (!packageJson.devDependencies) {
|
|
20
20
|
packageJson.devDependencies = {};
|
|
21
21
|
}
|
|
22
|
-
const nrwlWorkspaceNode = depGraph.
|
|
22
|
+
const nrwlWorkspaceNode = depGraph.externalNodes['npm:@nrwl/workspace'];
|
|
23
23
|
if (nrwlWorkspaceNode) {
|
|
24
24
|
packageJson.dependencies['@nrwl/workspace'] =
|
|
25
25
|
nrwlWorkspaceNode.data.version;
|
|
26
26
|
}
|
|
27
|
-
const typescriptNode = depGraph.
|
|
27
|
+
const typescriptNode = depGraph.externalNodes['npm:typescript'];
|
|
28
28
|
if (typescriptNode) {
|
|
29
29
|
packageJson.dependencies['typescript'] = typescriptNode.data.version;
|
|
30
30
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-package-json.js","sourceRoot":"","sources":["../../../../../../../packages/next/src/executors/build/lib/create-package-json.ts"],"names":[],"mappings":";;;;AACA,yCAA6C;AAC7C,yCAAsD;AACtD,2FAA6G;AAG7G,SAAsB,iBAAiB,CACrC,OAAgC,EAChC,OAAwB;;QAExB,MAAM,QAAQ,GAAG,IAAA,+BAAsB,GAAE,CAAC;QAC1C,MAAM,WAAW,GAAG,IAAA,uCAAmB,EAAC,OAAO,CAAC,WAAW,EAAE,QAAQ,EAAE;YACrE,IAAI,EAAE,OAAO,CAAC,IAAI;YAClB,WAAW,EAAE,OAAO,CAAC,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,UAAU;SACxE,CAAC,CAAC;QACH,IAAI,CAAC,WAAW,CAAC,OAAO,EAAE;YACxB,WAAW,CAAC,OAAO,GAAG,EAAE,CAAC;SAC1B;QACD,WAAW,CAAC,OAAO,CAAC,KAAK,GAAG,YAAY,CAAC;QACzC,IAAI,CAAC,WAAW,CAAC,eAAe,EAAE;YAChC,WAAW,CAAC,eAAe,GAAG,EAAE,CAAC;SAClC;QACD,MAAM,iBAAiB,GAAG,QAAQ,CAAC,
|
|
1
|
+
{"version":3,"file":"create-package-json.js","sourceRoot":"","sources":["../../../../../../../packages/next/src/executors/build/lib/create-package-json.ts"],"names":[],"mappings":";;;;AACA,yCAA6C;AAC7C,yCAAsD;AACtD,2FAA6G;AAG7G,SAAsB,iBAAiB,CACrC,OAAgC,EAChC,OAAwB;;QAExB,MAAM,QAAQ,GAAG,IAAA,+BAAsB,GAAE,CAAC;QAC1C,MAAM,WAAW,GAAG,IAAA,uCAAmB,EAAC,OAAO,CAAC,WAAW,EAAE,QAAQ,EAAE;YACrE,IAAI,EAAE,OAAO,CAAC,IAAI;YAClB,WAAW,EAAE,OAAO,CAAC,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,UAAU;SACxE,CAAC,CAAC;QACH,IAAI,CAAC,WAAW,CAAC,OAAO,EAAE;YACxB,WAAW,CAAC,OAAO,GAAG,EAAE,CAAC;SAC1B;QACD,WAAW,CAAC,OAAO,CAAC,KAAK,GAAG,YAAY,CAAC;QACzC,IAAI,CAAC,WAAW,CAAC,eAAe,EAAE;YAChC,WAAW,CAAC,eAAe,GAAG,EAAE,CAAC;SAClC;QACD,MAAM,iBAAiB,GAAG,QAAQ,CAAC,aAAa,CAAC,qBAAqB,CAAC,CAAC;QAExE,IAAI,iBAAiB,EAAE;YACrB,WAAW,CAAC,YAAY,CAAC,iBAAiB,CAAC;gBACzC,iBAAiB,CAAC,IAAI,CAAC,OAAO,CAAC;SAClC;QAED,MAAM,cAAc,GAAG,QAAQ,CAAC,aAAa,CAAC,gBAAgB,CAAC,CAAC;QAChE,IAAI,cAAc,EAAE;YAClB,WAAW,CAAC,YAAY,CAAC,YAAY,CAAC,GAAG,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC;SACtE;QAED,IAAA,sBAAa,EAAC,GAAG,OAAO,CAAC,UAAU,eAAe,EAAE,WAAW,CAAC,CAAC;IACnE,CAAC;CAAA;AA7BD,8CA6BC"}
|
|
@@ -20,7 +20,10 @@ function addLinting(host, options) {
|
|
|
20
20
|
if (options.linter === linter_1.Linter.EsLint) {
|
|
21
21
|
const reactEslintJson = (0, react_1.createReactEslintJson)(options.appProjectRoot, options.setParserOptionsProject);
|
|
22
22
|
(0, devkit_1.updateJson)(host, (0, devkit_1.joinPathFragments)(options.appProjectRoot, '.eslintrc.json'), () => {
|
|
23
|
+
// Turn off @next/next/no-html-link-for-pages since there is an issue with nextjs throwing linting errors
|
|
24
|
+
// TODO(nicholas): remove after Vercel updates nextjs linter to only lint ["*.ts", "*.tsx", "*.js", "*.jsx"]
|
|
23
25
|
var _a, _b, _c;
|
|
26
|
+
reactEslintJson.rules = Object.assign({ '@next/next/no-html-link-for-pages': 'off' }, reactEslintJson.rules);
|
|
24
27
|
// Find the override that handles both TS and JS files.
|
|
25
28
|
const commonOverride = (_a = reactEslintJson.overrides) === null || _a === void 0 ? void 0 : _a.find((o) => ['*.ts', '*.tsx', '*.js', '*.jsx'].every((ext) => o.files.includes(ext)));
|
|
26
29
|
if (commonOverride) {
|
|
@@ -43,7 +46,7 @@ function addLinting(host, options) {
|
|
|
43
46
|
reactEslintJson.extends = [reactEslintJson.extends];
|
|
44
47
|
}
|
|
45
48
|
// add next.js configuration
|
|
46
|
-
reactEslintJson.extends.
|
|
49
|
+
reactEslintJson.extends.unshift(...['next', 'next/core-web-vitals']);
|
|
47
50
|
// remove nx/react plugin, as it conflicts with the next.js one
|
|
48
51
|
reactEslintJson.extends = reactEslintJson.extends.filter((name) => name !== 'plugin:@nrwl/nx/react');
|
|
49
52
|
reactEslintJson.extends.unshift('plugin:@nrwl/nx/react-typescript');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"add-linting.js","sourceRoot":"","sources":["../../../../../../../packages/next/src/generators/application/lib/add-linting.ts"],"names":[],"mappings":";;;;AAAA,yCAA4D;AAC5D,yCAMsB;AACtB,uCAA6E;AAE7E,2FAAqF;AAErF,SAAsB,UAAU,CAC9B,IAAU,EACV,OAAyB;;QAEzB,MAAM,QAAQ,GAAG,MAAM,IAAA,6BAAoB,EAAC,IAAI,EAAE;YAChD,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,OAAO,EAAE,OAAO,CAAC,WAAW;YAC5B,aAAa,EAAE;gBACb,IAAA,0BAAiB,EAAC,OAAO,CAAC,cAAc,EAAE,mBAAmB,CAAC;aAC/D;YACD,kBAAkB,EAAE,CAAC,GAAG,OAAO,CAAC,cAAc,uBAAuB,CAAC;YACtE,UAAU,EAAE,IAAI;SACjB,CAAC,CAAC;QAEH,IAAI,OAAO,CAAC,MAAM,KAAK,eAAM,CAAC,MAAM,EAAE;YACpC,MAAM,eAAe,GAAG,IAAA,6BAAqB,EAC3C,OAAO,CAAC,cAAc,EACtB,OAAO,CAAC,uBAAuB,CAChC,CAAC;YACF,IAAA,mBAAU,EACR,IAAI,EACJ,IAAA,0BAAiB,EAAC,OAAO,CAAC,cAAc,EAAE,gBAAgB,CAAC,EAC3D,GAAG,EAAE
|
|
1
|
+
{"version":3,"file":"add-linting.js","sourceRoot":"","sources":["../../../../../../../packages/next/src/generators/application/lib/add-linting.ts"],"names":[],"mappings":";;;;AAAA,yCAA4D;AAC5D,yCAMsB;AACtB,uCAA6E;AAE7E,2FAAqF;AAErF,SAAsB,UAAU,CAC9B,IAAU,EACV,OAAyB;;QAEzB,MAAM,QAAQ,GAAG,MAAM,IAAA,6BAAoB,EAAC,IAAI,EAAE;YAChD,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,OAAO,EAAE,OAAO,CAAC,WAAW;YAC5B,aAAa,EAAE;gBACb,IAAA,0BAAiB,EAAC,OAAO,CAAC,cAAc,EAAE,mBAAmB,CAAC;aAC/D;YACD,kBAAkB,EAAE,CAAC,GAAG,OAAO,CAAC,cAAc,uBAAuB,CAAC;YACtE,UAAU,EAAE,IAAI;SACjB,CAAC,CAAC;QAEH,IAAI,OAAO,CAAC,MAAM,KAAK,eAAM,CAAC,MAAM,EAAE;YACpC,MAAM,eAAe,GAAG,IAAA,6BAAqB,EAC3C,OAAO,CAAC,cAAc,EACtB,OAAO,CAAC,uBAAuB,CAChC,CAAC;YACF,IAAA,mBAAU,EACR,IAAI,EACJ,IAAA,0BAAiB,EAAC,OAAO,CAAC,cAAc,EAAE,gBAAgB,CAAC,EAC3D,GAAG,EAAE;gBACH,yGAAyG;gBACzG,4GAA4G;;gBAE5G,eAAe,CAAC,KAAK,mBACnB,mCAAmC,EAAE,KAAK,IACvC,eAAe,CAAC,KAAK,CACzB,CAAC;gBACF,uDAAuD;gBACvD,MAAM,cAAc,GAAG,MAAA,eAAe,CAAC,SAAS,0CAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAC3D,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,CA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ACF,CAAC;SACH;QAED,MAAM,WAAW,GAAG,IAAA,qCAA4B,EAC9C,IAAI,EACJ,+BAAuB,CAAC,YAAY,EACpC,+BAAuB,CAAC,eAAe,CACxC,CAAC;QAEF,OAAO,IAAA,sCAAgB,EAAC,QAAQ,EAAE,WAAW,CAAC,CAAC;IACjD,CAAC;CAAA;AAlFD,gCAkFC"}
|
|
@@ -155,7 +155,7 @@ function createAppJsx(name) {
|
|
|
155
155
|
</svg>
|
|
156
156
|
</a>
|
|
157
157
|
<a
|
|
158
|
-
href="https://nx.dev/tutorial/01-create-application?utm_source=nx-project"
|
|
158
|
+
href="https://nx.dev/react-tutorial/01-create-application?utm_source=nx-project"
|
|
159
159
|
target="_blank"
|
|
160
160
|
rel="noreferrer"
|
|
161
161
|
className="list-item-link"
|
package/tailwind.d.ts
CHANGED
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
* @param dirPath workspace relative directory path that will be used to infer the parent project and dependencies
|
|
4
|
-
* @param fileGlobPattern pass a custom glob pattern to be used
|
|
5
|
-
*/
|
|
6
|
-
export declare function createGlobPatternsForDependencies(dirPath: string, fileGlobPattern?: string): string[];
|
|
1
|
+
import { createGlobPatternsForDependencies } from '@nrwl/react/tailwind';
|
|
2
|
+
export { createGlobPatternsForDependencies };
|
package/tailwind.js
CHANGED
|
@@ -1,29 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.createGlobPatternsForDependencies = void 0;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
* @param dirPath workspace relative directory path that will be used to infer the parent project and dependencies
|
|
8
|
-
* @param fileGlobPattern pass a custom glob pattern to be used
|
|
9
|
-
*/
|
|
10
|
-
function createGlobPatternsForDependencies(dirPath, fileGlobPattern = '/**/!(*.stories|*.spec).{tsx,jsx,js}') {
|
|
11
|
-
try {
|
|
12
|
-
return (0, generate_globs_1.createGlobPatternsForDependencies)(dirPath, fileGlobPattern);
|
|
13
|
-
}
|
|
14
|
-
catch (_a) {
|
|
15
|
-
/**
|
|
16
|
-
* It should not be possible to reach this point when the utility is invoked as part of the normal
|
|
17
|
-
* lifecycle of Nx executors. However, other tooling, such as the VSCode Tailwind IntelliSense plugin
|
|
18
|
-
* or JetBrains editors such as WebStorm, may execute the tailwind.config.js file in order to provide
|
|
19
|
-
* autocomplete features, for example.
|
|
20
|
-
*
|
|
21
|
-
* In order to best support that use-case, we therefore do not hard error when the ProjectGraph is
|
|
22
|
-
* fundamently unavailable in this tailwind-specific context.
|
|
23
|
-
*/
|
|
24
|
-
console.warn('\n[createGlobPatternsForDependencies] WARNING: There was no ProjectGraph available to read from, returning an empty array of glob patterns\n');
|
|
25
|
-
return [];
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
exports.createGlobPatternsForDependencies = createGlobPatternsForDependencies;
|
|
4
|
+
// Re-exporting for convenience and backwards compatibility.
|
|
5
|
+
const tailwind_1 = require("@nrwl/react/tailwind");
|
|
6
|
+
Object.defineProperty(exports, "createGlobPatternsForDependencies", { enumerable: true, get: function () { return tailwind_1.createGlobPatternsForDependencies; } });
|
|
29
7
|
//# sourceMappingURL=tailwind.js.map
|
package/tailwind.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tailwind.js","sourceRoot":"","sources":["../../../packages/next/tailwind.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"tailwind.js","sourceRoot":"","sources":["../../../packages/next/tailwind.ts"],"names":[],"mappings":";;;AAAA,4DAA4D;AAC5D,mDAAyE;AAChE,kHADA,4CAAiC,OACA"}
|