@nrwl/next 15.0.0 → 15.0.1-beta.2

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 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
- # [15.0.0](https://github.com/nrwl/nx/compare/14.8.0...15.0.0) (2022-10-14)
6
+ ## [15.0.1-beta.2](https://github.com/nrwl/nx/compare/15.0.0...15.0.1-beta.2) (2022-10-19)
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": "15.0.0",
3
+ "version": "15.0.1-beta.2",
4
4
  "private": false,
5
5
  "description": "The Next.js plugin for Nx 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. \n\nWhen 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.",
6
6
  "repository": {
@@ -35,13 +35,13 @@
35
35
  },
36
36
  "dependencies": {
37
37
  "@babel/plugin-proposal-decorators": "^7.14.5",
38
- "@nrwl/cypress": "15.0.0",
39
- "@nrwl/devkit": "15.0.0",
40
- "@nrwl/jest": "15.0.0",
41
- "@nrwl/linter": "15.0.0",
42
- "@nrwl/react": "15.0.0",
43
- "@nrwl/webpack": "15.0.0",
44
- "@nrwl/workspace": "15.0.0",
38
+ "@nrwl/cypress": "15.0.1-beta.2",
39
+ "@nrwl/devkit": "15.0.1-beta.2",
40
+ "@nrwl/jest": "15.0.1-beta.2",
41
+ "@nrwl/linter": "15.0.1-beta.2",
42
+ "@nrwl/react": "15.0.1-beta.2",
43
+ "@nrwl/webpack": "15.0.1-beta.2",
44
+ "@nrwl/workspace": "15.0.1-beta.2",
45
45
  "@svgr/webpack": "^6.1.2",
46
46
  "chalk": "4.1.0",
47
47
  "dotenv": "~10.0.0",
@@ -57,5 +57,5 @@
57
57
  "access": "public"
58
58
  },
59
59
  "types": "./index.d.ts",
60
- "gitHead": "59db3017b85cdc253ec4fb94af8667e897833025"
60
+ "gitHead": "ccc98e3252e9f7e8d805edc9d0820b6c86b68559"
61
61
  }
@@ -1,3 +1,3 @@
1
1
  import { Tree } from '@nrwl/devkit';
2
2
  import { NormalizedSchema } from './normalize-options';
3
- export declare function addJest(host: Tree, options: NormalizedSchema): Promise<() => void>;
3
+ export declare function addJest(host: Tree, options: NormalizedSchema): Promise<import("@nrwl/devkit").GeneratorCallback>;
@@ -4,12 +4,6 @@
4
4
  "$id": "NxNextApp",
5
5
  "title": "Create a Next.js Application for Nx",
6
6
  "description": "Create a Next.js Application for Nx.",
7
- "examples": [
8
- {
9
- "command": "nx g app myapp --directory=myorg",
10
- "description": "Generate `apps/myorg/myapp` and `apps/myorg/myapp-e2e`"
11
- }
12
- ],
13
7
  "type": "object",
14
8
  "properties": {
15
9
  "name": {
@@ -126,5 +120,6 @@
126
120
  "default": false
127
121
  }
128
122
  },
129
- "required": []
123
+ "required": [],
124
+ "examplesFile": "../../../docs/application-examples.md"
130
125
  }
@@ -6,6 +6,8 @@ interface Schema {
6
6
  style: SupportedStyles;
7
7
  directory?: string;
8
8
  flat?: boolean;
9
+ pascalCaseFiles?: boolean;
10
+ pascalCaseDirectory?: boolean;
9
11
  }
10
12
  export declare function componentGenerator(host: Tree, options: Schema): Promise<import("@nrwl/devkit").GeneratorCallback>;
11
13
  export default componentGenerator;
@@ -21,7 +21,7 @@ function getDirectory(host, options) {
21
21
  */
22
22
  function componentGenerator(host, options) {
23
23
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
24
- const componentInstall = yield (0, react_1.componentGenerator)(host, Object.assign(Object.assign({}, options), { directory: getDirectory(host, options), pascalCaseFiles: false, classComponent: false, routing: false }));
24
+ const componentInstall = yield (0, react_1.componentGenerator)(host, Object.assign(Object.assign({}, options), { directory: getDirectory(host, options), classComponent: false, routing: false }));
25
25
  const styledInstall = (0, styles_1.addStyleDependencies)(host, options.style);
26
26
  return (0, run_tasks_in_serial_1.runTasksInSerial)(styledInstall, componentInstall);
27
27
  });
@@ -1 +1 @@
1
- {"version":3,"file":"component.js","sourceRoot":"","sources":["../../../../../../packages/next/src/generators/component/component.ts"],"names":[],"mappings":";;;;AAAA,yCAAqE;AAErE,uCAA4E;AAC5E,2FAAqF;AACrF,+CAA0D;AAU1D,SAAS,YAAY,CAAC,IAAU,EAAE,OAAe;IAC/C,MAAM,SAAS,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IACpC,MAAM,WAAW,GAAG,SAAS,CAAC,GAAG,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,WAAW,CAAC;IAE/D,OAAO,OAAO,CAAC,SAAS;QACtB,CAAC,CAAC,OAAO,CAAC,SAAS;QACnB,CAAC,CAAC,WAAW,KAAK,aAAa;YAC/B,CAAC,CAAC,YAAY;YACd,CAAC,CAAC,SAAS,CAAC;AAChB,CAAC;AAED;;;GAGG;AACH,SAAsB,kBAAkB,CAAC,IAAU,EAAE,OAAe;;QAClE,MAAM,gBAAgB,GAAG,MAAM,IAAA,0BAAuB,EAAC,IAAI,kCACtD,OAAO,KACV,SAAS,EAAE,YAAY,CAAC,IAAI,EAAE,OAAO,CAAC,EACtC,eAAe,EAAE,KAAK,EACtB,cAAc,EAAE,KAAK,EACrB,OAAO,EAAE,KAAK,IACd,CAAC;QAEH,MAAM,aAAa,GAAG,IAAA,6BAAoB,EAAC,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC;QAEhE,OAAO,IAAA,sCAAgB,EAAC,aAAa,EAAE,gBAAgB,CAAC,CAAC;IAC3D,CAAC;CAAA;AAZD,gDAYC;AAED,kBAAe,kBAAkB,CAAC;AACrB,QAAA,kBAAkB,GAAG,IAAA,2BAAkB,EAAC,kBAAkB,CAAC,CAAC"}
1
+ {"version":3,"file":"component.js","sourceRoot":"","sources":["../../../../../../packages/next/src/generators/component/component.ts"],"names":[],"mappings":";;;;AAAA,yCAAqE;AAErE,uCAA4E;AAC5E,2FAAqF;AACrF,+CAA0D;AAY1D,SAAS,YAAY,CAAC,IAAU,EAAE,OAAe;IAC/C,MAAM,SAAS,GAAG,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IACpC,MAAM,WAAW,GAAG,SAAS,CAAC,GAAG,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,WAAW,CAAC;IAE/D,OAAO,OAAO,CAAC,SAAS;QACtB,CAAC,CAAC,OAAO,CAAC,SAAS;QACnB,CAAC,CAAC,WAAW,KAAK,aAAa;YAC/B,CAAC,CAAC,YAAY;YACd,CAAC,CAAC,SAAS,CAAC;AAChB,CAAC;AAED;;;GAGG;AACH,SAAsB,kBAAkB,CAAC,IAAU,EAAE,OAAe;;QAClE,MAAM,gBAAgB,GAAG,MAAM,IAAA,0BAAuB,EAAC,IAAI,kCACtD,OAAO,KACV,SAAS,EAAE,YAAY,CAAC,IAAI,EAAE,OAAO,CAAC,EACtC,cAAc,EAAE,KAAK,EACrB,OAAO,EAAE,KAAK,IACd,CAAC;QAEH,MAAM,aAAa,GAAG,IAAA,6BAAoB,EAAC,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC;QAEhE,OAAO,IAAA,sCAAgB,EAAC,aAAa,EAAE,gBAAgB,CAAC,CAAC;IAC3D,CAAC;CAAA;AAXD,gDAWC;AAED,kBAAe,kBAAkB,CAAC;AACrB,QAAA,kBAAkB,GAAG,IAAA,2BAAkB,EAAC,kBAAkB,CAAC,CAAC"}
@@ -5,16 +5,6 @@
5
5
  "title": "Create a React Component for Next",
6
6
  "description": "Create a React Component for Next.",
7
7
  "type": "object",
8
- "examples": [
9
- {
10
- "command": "nx g component my-component --project=mylib",
11
- "description": "Generate a component in the `mylib` library"
12
- },
13
- {
14
- "command": "nx g component my-component --project=mylib --classComponent",
15
- "description": "Generate a class component in the `mylib` library"
16
- }
17
- ],
18
8
  "properties": {
19
9
  "project": {
20
10
  "type": "string",
@@ -96,7 +86,20 @@
96
86
  "type": "boolean",
97
87
  "description": "Create component at the source root rather than its own directory.",
98
88
  "default": false
89
+ },
90
+ "pascalCaseFiles": {
91
+ "type": "boolean",
92
+ "description": "Use pascal case component file name (e.g. `App.tsx`).",
93
+ "alias": "P",
94
+ "default": false
95
+ },
96
+ "pascalCaseDirectory": {
97
+ "type": "boolean",
98
+ "description": "Use pascal case directory name (e.g. `App/App.tsx`).",
99
+ "alias": "R",
100
+ "default": false
99
101
  }
100
102
  },
101
- "required": ["name", "project"]
103
+ "required": ["name", "project"],
104
+ "examplesFile": "../../../docs/component-examples.md"
102
105
  }
@@ -4,12 +4,6 @@
4
4
  "$id": "NxNextCustomServer",
5
5
  "title": "Add custom server",
6
6
  "description": "Add a custom server to existing Next.js application.",
7
- "examples": [
8
- {
9
- "command": "nx g custom-server my-app",
10
- "description": "Add a custom server to existing Next.js app."
11
- }
12
- ],
13
7
  "type": "object",
14
8
  "properties": {
15
9
  "project": {
@@ -30,5 +24,6 @@
30
24
  "description": "The compiler used to build the custom server."
31
25
  }
32
26
  },
33
- "required": ["project"]
27
+ "required": ["project"],
28
+ "examplesFile": "../../../docs/custom-server-examples.md"
34
29
  }
@@ -5,16 +5,6 @@
5
5
  "title": "Create a React Library for Nx",
6
6
  "description": "Create a React Library for an Nx workspace.",
7
7
  "type": "object",
8
- "examples": [
9
- {
10
- "command": "nx g lib mylib --directory=myapp",
11
- "description": "Generate `libs/myapp/mylib`"
12
- },
13
- {
14
- "command": "nx g lib mylib --appProject=myapp",
15
- "description": "Generate a library with routes and add them to `myapp`"
16
- }
17
- ],
18
8
  "properties": {
19
9
  "name": {
20
10
  "type": "string",
@@ -157,5 +147,6 @@
157
147
  "type": "boolean"
158
148
  }
159
149
  },
160
- "required": ["name"]
150
+ "required": ["name"],
151
+ "examplesFile": "../../../docs/library-examples.md"
161
152
  }
@@ -5,12 +5,6 @@
5
5
  "title": "Create a Page for Next",
6
6
  "description": "Create a Page for Next.",
7
7
  "type": "object",
8
- "examples": [
9
- {
10
- "command": "nx g page my-new-page --project=my-app",
11
- "description": "Generate a page in the my-app application"
12
- }
13
- ],
14
8
  "properties": {
15
9
  "project": {
16
10
  "type": "string",
@@ -98,5 +92,6 @@
98
92
  "default": false
99
93
  }
100
94
  },
101
- "required": ["name", "project"]
95
+ "required": ["name", "project"],
96
+ "examplesFile": "../../../docs/page-examples.md"
102
97
  }