@nx/vue 23.0.0-beta.1 → 23.0.0-beta.3

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/generators.json CHANGED
@@ -29,12 +29,6 @@
29
29
  "x-type": "component",
30
30
  "description": "Create a Vue component."
31
31
  },
32
- "setup-tailwind": {
33
- "factory": "./src/generators/setup-tailwind/setup-tailwind",
34
- "schema": "./src/generators/setup-tailwind/schema.json",
35
- "description": "Set up Tailwind configuration for a project.",
36
- "x-deprecated": "Generating Tailwind configuration is no longer maintained. This generator will be removed in Nx 23."
37
- },
38
32
  "storybook-configuration": {
39
33
  "factory": "./src/generators/storybook-configuration/configuration#storybookConfigurationGeneratorInternal",
40
34
  "schema": "./src/generators/storybook-configuration/schema.json",
package/index.d.ts CHANGED
@@ -5,8 +5,6 @@ export { componentGenerator } from './src/generators/component/component';
5
5
  export { ComponentGeneratorSchema } from './src/generators/component/schema';
6
6
  export { storybookConfigurationGenerator } from './src/generators/storybook-configuration/configuration';
7
7
  export { storiesGenerator, StorybookStoriesSchema, } from './src/generators/stories/stories';
8
- export { setupTailwindGenerator } from './src/generators/setup-tailwind/setup-tailwind';
9
- export { SetupTailwindOptions } from './src/generators/setup-tailwind/schema';
10
8
  export { type InitSchema } from './src/generators/init/schema';
11
9
  export { vueInitGenerator } from './src/generators/init/init';
12
10
  export * from './src/utils/versions';
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../packages/vue/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,wBAAwB,EAAE,MAAM,mCAAmC,CAAC;AAC7E,OAAO,EAAE,+BAA+B,EAAE,MAAM,wDAAwD,CAAC;AACzG,OAAO,EACL,gBAAgB,EAChB,sBAAsB,GACvB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,sBAAsB,EAAE,MAAM,gDAAgD,CAAC;AACxF,OAAO,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AAC9E,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAC9D,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../packages/vue/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,wBAAwB,EAAE,MAAM,mCAAmC,CAAC;AAC7E,OAAO,EAAE,+BAA+B,EAAE,MAAM,wDAAwD,CAAC;AACzG,OAAO,EACL,gBAAgB,EAChB,sBAAsB,GACvB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAC9D,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC"}
package/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.vueInitGenerator = exports.setupTailwindGenerator = exports.storiesGenerator = exports.storybookConfigurationGenerator = exports.componentGenerator = exports.libraryGenerator = exports.applicationGenerator = void 0;
3
+ exports.vueInitGenerator = exports.storiesGenerator = exports.storybookConfigurationGenerator = exports.componentGenerator = exports.libraryGenerator = exports.applicationGenerator = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  tslib_1.__exportStar(require("./src/utils/versions"), exports);
6
6
  var application_1 = require("./src/generators/application/application");
@@ -13,8 +13,6 @@ var configuration_1 = require("./src/generators/storybook-configuration/configur
13
13
  Object.defineProperty(exports, "storybookConfigurationGenerator", { enumerable: true, get: function () { return configuration_1.storybookConfigurationGenerator; } });
14
14
  var stories_1 = require("./src/generators/stories/stories");
15
15
  Object.defineProperty(exports, "storiesGenerator", { enumerable: true, get: function () { return stories_1.storiesGenerator; } });
16
- var setup_tailwind_1 = require("./src/generators/setup-tailwind/setup-tailwind");
17
- Object.defineProperty(exports, "setupTailwindGenerator", { enumerable: true, get: function () { return setup_tailwind_1.setupTailwindGenerator; } });
18
16
  var init_1 = require("./src/generators/init/init");
19
17
  Object.defineProperty(exports, "vueInitGenerator", { enumerable: true, get: function () { return init_1.vueInitGenerator; } });
20
18
  tslib_1.__exportStar(require("./src/utils/versions"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/vue",
3
- "version": "23.0.0-beta.1",
3
+ "version": "23.0.0-beta.3",
4
4
  "private": false,
5
5
  "description": "The Vue plugin for Nx contains executors and generators for managing Vue applications and libraries within an Nx workspace. It provides:\n\n\n- Integration with libraries such as Vitest, Playwright, Cypress, and Storybook.\n\n- Generators for applications, libraries, and more.\n\n- Library build support for publishing packages to npm or other registries.\n\n- Utilities for automatic workspace refactoring.",
6
6
  "repository": {
@@ -30,27 +30,27 @@
30
30
  "migrations": "./migrations.json"
31
31
  },
32
32
  "dependencies": {
33
- "@nx/devkit": "23.0.0-beta.1",
34
- "@nx/eslint": "23.0.0-beta.1",
35
- "@nx/js": "23.0.0-beta.1",
36
- "@nx/vite": "23.0.0-beta.1",
37
- "@nx/vitest": "23.0.0-beta.1",
38
- "@nx/web": "23.0.0-beta.1",
33
+ "@nx/devkit": "23.0.0-beta.3",
34
+ "@nx/eslint": "23.0.0-beta.3",
35
+ "@nx/js": "23.0.0-beta.3",
36
+ "@nx/vite": "23.0.0-beta.3",
37
+ "@nx/vitest": "23.0.0-beta.3",
38
+ "@nx/web": "23.0.0-beta.3",
39
39
  "picomatch": "4.0.4",
40
40
  "semver": "^7.6.3",
41
41
  "tslib": "^2.3.0"
42
42
  },
43
43
  "devDependencies": {
44
- "nx": "23.0.0-beta.1"
44
+ "nx": "23.0.0-beta.3"
45
45
  },
46
46
  "publishConfig": {
47
47
  "access": "public"
48
48
  },
49
49
  "peerDependencies": {
50
- "@nx/cypress": "23.0.0-beta.1",
51
- "@nx/playwright": "23.0.0-beta.1",
52
- "@nx/rsbuild": "23.0.0-beta.1",
53
- "@nx/storybook": "23.0.0-beta.1"
50
+ "@nx/cypress": "23.0.0-beta.3",
51
+ "@nx/playwright": "23.0.0-beta.3",
52
+ "@nx/rsbuild": "23.0.0-beta.3",
53
+ "@nx/storybook": "23.0.0-beta.3"
54
54
  },
55
55
  "peerDependenciesMeta": {
56
56
  "@nx/cypress": {
@@ -1 +1 @@
1
- {"version":3,"file":"add-rsbuild.d.ts","sourceRoot":"","sources":["../../../../../../../packages/vue/src/generators/application/lib/add-rsbuild.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,IAAI,EACT,KAAK,iBAAiB,EAIvB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAG7C,wBAAsB,UAAU,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,gBAAgB,gCAwDrE"}
1
+ {"version":3,"file":"add-rsbuild.d.ts","sourceRoot":"","sources":["../../../../../../../packages/vue/src/generators/application/lib/add-rsbuild.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,IAAI,EACT,KAAK,iBAAiB,EAIvB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAG7C,wBAAsB,UAAU,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,gBAAgB,gCAgDrE"}
@@ -62,10 +62,6 @@ async function addRsbuild(tree, options) {
62
62
  addBuildPlugin(tree, pathToConfigFile, '@rsbuild/plugin-sass', 'pluginSass');
63
63
  deps['@rsbuild/plugin-sass'] = versions.rsbuildPluginSassVersion;
64
64
  }
65
- else if (options.style === 'less') {
66
- addBuildPlugin(tree, pathToConfigFile, '@rsbuild/plugin-less', 'pluginLess');
67
- deps['@rsbuild/plugin-less'] = versions.rsbuildPluginLessVersion;
68
- }
69
65
  addHtmlTemplatePath(tree, pathToConfigFile, './index.html');
70
66
  tasks.push((0, devkit_1.addDependenciesToPackageJson)(tree, {}, deps));
71
67
  return tasks;
@@ -3,7 +3,7 @@ import type { Linter, LinterType } from '@nx/eslint';
3
3
  export interface Schema {
4
4
  directory: string;
5
5
  name?: string;
6
- style: 'none' | 'css' | 'scss' | 'less';
6
+ style: 'none' | 'css' | 'scss';
7
7
  bundler?: 'vite' | 'rsbuild';
8
8
  skipFormat?: boolean;
9
9
  tags?: string;
@@ -37,6 +37,7 @@
37
37
  "type": "string",
38
38
  "default": "css",
39
39
  "alias": "s",
40
+ "enum": ["css", "scss", "none"],
40
41
  "x-prompt": {
41
42
  "message": "Which stylesheet format would you like to use?",
42
43
  "type": "list",
@@ -47,11 +48,7 @@
47
48
  },
48
49
  {
49
50
  "value": "scss",
50
- "label": "SASS(.scss) [ https://sass-lang.com ]"
51
- },
52
- {
53
- "value": "less",
54
- "label": "LESS [ https://lesscss.org ]"
51
+ "label": "SASS(.scss) [ https://sass-lang.com ]"
55
52
  },
56
53
  {
57
54
  "value": "none",
@@ -1,7 +1,7 @@
1
1
  import { type GeneratorCallback, type Tree } from '@nx/devkit';
2
2
  export type EnsureDependenciesOptions = {
3
3
  routing?: boolean;
4
- style?: 'scss' | 'less' | 'none' | 'css';
4
+ style?: 'scss' | 'none' | 'css';
5
5
  };
6
6
  export declare function ensureDependencies(tree: Tree, options: EnsureDependenciesOptions): GeneratorCallback;
7
7
  //# sourceMappingURL=ensure-dependencies.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ensure-dependencies.d.ts","sourceRoot":"","sources":["../../../../../packages/vue/src/utils/ensure-dependencies.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;AAUpB,MAAM,MAAM,yBAAyB,GAAG;IACtC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC;CAC1C,CAAC;AAEF,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,yBAAyB,GACjC,iBAAiB,CAmBnB"}
1
+ {"version":3,"file":"ensure-dependencies.d.ts","sourceRoot":"","sources":["../../../../../packages/vue/src/utils/ensure-dependencies.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;AASpB,MAAM,MAAM,yBAAyB,GAAG;IACtC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC;CACjC,CAAC;AAEF,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,yBAAyB,GACjC,iBAAiB,CAiBnB"}
@@ -16,8 +16,5 @@ function ensureDependencies(tree, options) {
16
16
  if (options.style === 'scss') {
17
17
  devDependencies['sass'] = versions_1.sassVersion;
18
18
  }
19
- else if (options.style === 'less') {
20
- devDependencies['less'] = versions_1.lessVersion;
21
- }
22
19
  return (0, devkit_1.addDependenciesToPackageJson)(tree, dependencies, devDependencies);
23
20
  }
@@ -9,8 +9,6 @@ export declare const vueEslintConfigTypescriptVersion = "^11.0.3";
9
9
  export declare const eslint9__VueEslintConfigTypescriptVersion = "^14.6.0";
10
10
  export declare const eslintPluginVueVersion = "^9.16.1";
11
11
  export declare const postcssVersion = "8.4.21";
12
- export declare const tailwindcssVersion = "3.2.7";
13
12
  export declare const autoprefixerVersion = "10.4.13";
14
- export declare const sassVersion = "^1.70.0";
15
- export declare const lessVersion = "3.12.2";
13
+ export declare const sassVersion = "^1.97.2";
16
14
  //# sourceMappingURL=versions.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../../../packages/vue/src/utils/versions.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,KAAwC,CAAC;AAG/D,eAAO,MAAM,UAAU,YAAY,CAAC;AACpC,eAAO,MAAM,aAAa,WAAW,CAAC;AACtC,eAAO,MAAM,gBAAgB,WAAW,CAAC;AAGzC,eAAO,MAAM,mBAAmB,WAAW,CAAC;AAC5C,eAAO,MAAM,oBAAoB,WAAW,CAAC;AAG7C,eAAO,MAAM,8BAA8B,YAAY,CAAC;AACxD,eAAO,MAAM,gCAAgC,YAAY,CAAC;AAC1D,eAAO,MAAM,yCAAyC,YAAY,CAAC;AACnE,eAAO,MAAM,sBAAsB,YAAY,CAAC;AAGhD,eAAO,MAAM,cAAc,WAAW,CAAC;AACvC,eAAO,MAAM,kBAAkB,UAAU,CAAC;AAC1C,eAAO,MAAM,mBAAmB,YAAY,CAAC;AAG7C,eAAO,MAAM,WAAW,YAAY,CAAC;AACrC,eAAO,MAAM,WAAW,WAAW,CAAC"}
1
+ {"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../../../packages/vue/src/utils/versions.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,KAAwC,CAAC;AAG/D,eAAO,MAAM,UAAU,YAAY,CAAC;AACpC,eAAO,MAAM,aAAa,WAAW,CAAC;AACtC,eAAO,MAAM,gBAAgB,WAAW,CAAC;AAGzC,eAAO,MAAM,mBAAmB,WAAW,CAAC;AAC5C,eAAO,MAAM,oBAAoB,WAAW,CAAC;AAG7C,eAAO,MAAM,8BAA8B,YAAY,CAAC;AACxD,eAAO,MAAM,gCAAgC,YAAY,CAAC;AAC1D,eAAO,MAAM,yCAAyC,YAAY,CAAC;AACnE,eAAO,MAAM,sBAAsB,YAAY,CAAC;AAEhD,eAAO,MAAM,cAAc,WAAW,CAAC;AACvC,eAAO,MAAM,mBAAmB,YAAY,CAAC;AAG7C,eAAO,MAAM,WAAW,YAAY,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.lessVersion = exports.sassVersion = exports.autoprefixerVersion = exports.tailwindcssVersion = exports.postcssVersion = exports.eslintPluginVueVersion = exports.eslint9__VueEslintConfigTypescriptVersion = exports.vueEslintConfigTypescriptVersion = exports.vueEslintConfigPrettierVersion = exports.vitePluginVueVersion = exports.vueTestUtilsVersion = exports.vueRouterVersion = exports.vueTscVersion = exports.vueVersion = exports.nxVersion = void 0;
3
+ exports.sassVersion = exports.autoprefixerVersion = exports.postcssVersion = exports.eslintPluginVueVersion = exports.eslint9__VueEslintConfigTypescriptVersion = exports.vueEslintConfigTypescriptVersion = exports.vueEslintConfigPrettierVersion = exports.vitePluginVueVersion = exports.vueTestUtilsVersion = exports.vueRouterVersion = exports.vueTscVersion = exports.vueVersion = exports.nxVersion = void 0;
4
4
  exports.nxVersion = require('../../package.json').version;
5
5
  // vue core
6
6
  exports.vueVersion = '^3.5.13';
@@ -14,10 +14,7 @@ exports.vueEslintConfigPrettierVersion = '^10.2.0';
14
14
  exports.vueEslintConfigTypescriptVersion = '^11.0.3';
15
15
  exports.eslint9__VueEslintConfigTypescriptVersion = '^14.6.0';
16
16
  exports.eslintPluginVueVersion = '^9.16.1';
17
- // tailwindcss
18
17
  exports.postcssVersion = '8.4.21';
19
- exports.tailwindcssVersion = '3.2.7';
20
18
  exports.autoprefixerVersion = '10.4.13';
21
19
  // other deps
22
- exports.sassVersion = '^1.70.0';
23
- exports.lessVersion = '3.12.2';
20
+ exports.sassVersion = '^1.97.2';
package/tailwind.d.ts CHANGED
@@ -1,7 +1,6 @@
1
1
  /**
2
- * Generates a set of glob patterns based off the source root of the app and its dependencies
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
2
+ * @deprecated `@nx/vue/tailwind` will be removed in Nx 24. Migrate to Tailwind CSS v4 which no longer needs glob patterns.
3
+ * See: https://nx.dev/docs/technologies/vue/guides/using-tailwind-css-in-vue
5
4
  */
6
5
  export declare function createGlobPatternsForDependencies(dirPath: string, fileGlobPattern?: string): string[];
7
6
  //# sourceMappingURL=tailwind.d.ts.map
package/tailwind.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"tailwind.d.ts","sourceRoot":"","sources":["../../../packages/vue/tailwind.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,wBAAgB,iCAAiC,CAC/C,OAAO,EAAE,MAAM,EACf,eAAe,GAAE,MAAuD,YAoBzE"}
1
+ {"version":3,"file":"tailwind.d.ts","sourceRoot":"","sources":["../../../packages/vue/tailwind.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,wBAAgB,iCAAiC,CAC/C,OAAO,EAAE,MAAM,EACf,eAAe,GAAE,MAAsD,YA4BxE"}
package/tailwind.js CHANGED
@@ -2,12 +2,18 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createGlobPatternsForDependencies = createGlobPatternsForDependencies;
4
4
  const generate_globs_1 = require("@nx/js/src/utils/generate-globs");
5
+ let hasWarned = false;
5
6
  /**
6
- * Generates a set of glob patterns based off the source root of the app and its dependencies
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
7
+ * @deprecated `@nx/vue/tailwind` will be removed in Nx 24. Migrate to Tailwind CSS v4 which no longer needs glob patterns.
8
+ * See: https://nx.dev/docs/technologies/vue/guides/using-tailwind-css-in-vue
9
9
  */
10
- function createGlobPatternsForDependencies(dirPath, fileGlobPattern = '/**/*!(*.stories|*.spec).{vue,tsx,ts,jsx,js}') {
10
+ function createGlobPatternsForDependencies(dirPath, fileGlobPattern = '/**/!(*.stories|*.spec).{vue,tsx,ts,jsx,js}') {
11
+ if (!hasWarned) {
12
+ hasWarned = true;
13
+ console.warn(`\nWARNING: "@nx/vue/tailwind" is deprecated and will be removed in Nx 24.\n` +
14
+ `Migrate to Tailwind CSS v4 which no longer needs glob patterns for content detection.\n` +
15
+ `See: https://nx.dev/docs/technologies/vue/guides/using-tailwind-css-in-vue\n`);
16
+ }
11
17
  try {
12
18
  return (0, generate_globs_1.createGlobPatternsForDependencies)(dirPath, fileGlobPattern);
13
19
  }
@@ -1,10 +0,0 @@
1
- const { join } = require('path');
2
-
3
- module.exports = {
4
- plugins: {
5
- tailwindcss: {
6
- config: join(__dirname, 'tailwind.config.js'),
7
- },
8
- autoprefixer: {},
9
- },
10
- }
@@ -1,18 +0,0 @@
1
- const { createGlobPatternsForDependencies } = require('@nx/vue/tailwind');
2
- const { join } = require('path');
3
-
4
- /** @type {import('tailwindcss').Config} */
5
- module.exports = {
6
- content: [
7
- join(__dirname, 'index.html'),
8
- join(
9
- __dirname,
10
- 'src/**/*!(*.stories|*.spec).{vue,ts,tsx,js,jsx}'
11
- ),
12
- ...createGlobPatternsForDependencies(__dirname),
13
- ],
14
- theme: {
15
- extend: {},
16
- },
17
- plugins: [],
18
- };
@@ -1,4 +0,0 @@
1
- import { ProjectConfiguration, Tree } from '@nx/devkit';
2
- import { SetupTailwindOptions } from '../schema';
3
- export declare function addTailwindStyleImports(tree: Tree, project: ProjectConfiguration, _options: SetupTailwindOptions): void;
4
- //# sourceMappingURL=add-tailwind-style-imports.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"add-tailwind-style-imports.d.ts","sourceRoot":"","sources":["../../../../../../../packages/vue/src/generators/setup-tailwind/lib/add-tailwind-style-imports.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,oBAAoB,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAE3E,OAAO,EAAE,oBAAoB,EAAE,MAAM,WAAW,CAAC;AAmBjD,wBAAgB,uBAAuB,CACrC,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,oBAAoB,EAC7B,QAAQ,EAAE,oBAAoB,QAqB/B"}
@@ -1,31 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addTailwindStyleImports = addTailwindStyleImports;
4
- const devkit_1 = require("@nx/devkit");
5
- const knownStylesheetLocations = [
6
- // What we generate by default
7
- 'src/styles.css',
8
- 'src/styles.scss',
9
- 'src/styles.less',
10
- // What we generate for nuxt by default
11
- 'src/assets/css/styles.css',
12
- 'src/assets/css/styles.scss',
13
- 'src/assets/css/styles.less',
14
- // Other common locations (e.g. what `npm create vue` does)
15
- 'src/assets/styles.css',
16
- 'src/assets/styles.scss',
17
- 'src/assets/styles.less',
18
- ];
19
- function addTailwindStyleImports(tree, project, _options) {
20
- if (_options.stylesheet) {
21
- knownStylesheetLocations.push(_options.stylesheet);
22
- }
23
- const stylesPath = knownStylesheetLocations
24
- .map((file) => (0, devkit_1.joinPathFragments)(project.root, file))
25
- .find((file) => tree.exists(file));
26
- if (!stylesPath) {
27
- throw new Error(`Could not find the stylesheet to update. Use --stylesheet to specify this path (relative to the workspace root).`);
28
- }
29
- const content = tree.read(stylesPath).toString();
30
- tree.write(stylesPath, `@tailwind base;\n@tailwind components;\n@tailwind utilities;\n${content}`);
31
- }
@@ -1,6 +0,0 @@
1
- export interface SetupTailwindOptions {
2
- project: string;
3
- skipFormat?: boolean;
4
- skipPackageJson?: boolean;
5
- stylesheet?: string;
6
- }
@@ -1,45 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/schema",
3
- "cli": "nx",
4
- "$id": "NxVueTailwindSetupGenerator",
5
- "title": "Configures Tailwind CSS for an application or a library.",
6
- "description": "Adds the Tailwind CSS configuration files for a given Vue project and installs, if needed, the packages required for Tailwind CSS to work.",
7
- "type": "object",
8
- "examples": [
9
- {
10
- "command": "nx g setup-tailwind --project=my-app",
11
- "description": "Initialize Tailwind configuration for the `my-app` project."
12
- }
13
- ],
14
- "properties": {
15
- "project": {
16
- "type": "string",
17
- "description": "The name of the project to add the Tailwind CSS setup for.",
18
- "alias": "p",
19
- "$default": {
20
- "$source": "argv",
21
- "index": 0
22
- },
23
- "x-dropdown": "projects",
24
- "x-prompt": "What project would you like to add the Tailwind CSS setup?",
25
- "x-priority": "important"
26
- },
27
- "skipFormat": {
28
- "type": "boolean",
29
- "description": "Skips formatting the workspace after the generator completes.",
30
- "x-priority": "internal"
31
- },
32
- "skipPackageJson": {
33
- "type": "boolean",
34
- "default": false,
35
- "description": "Do not add dependencies to `package.json`.",
36
- "x-priority": "internal"
37
- },
38
- "stylesheet": {
39
- "type": "string",
40
- "description": "Path to the styles entry point relative to the workspace root. This option is only needed if the stylesheet location cannot be found automatically."
41
- }
42
- },
43
- "additionalProperties": false,
44
- "required": ["project"]
45
- }
@@ -1,5 +0,0 @@
1
- import type { GeneratorCallback, Tree } from '@nx/devkit';
2
- import type { SetupTailwindOptions } from './schema';
3
- export declare function setupTailwindGenerator(tree: Tree, options: SetupTailwindOptions): Promise<void | GeneratorCallback>;
4
- export default setupTailwindGenerator;
5
- //# sourceMappingURL=setup-tailwind.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"setup-tailwind.d.ts","sourceRoot":"","sources":["../../../../../../packages/vue/src/generators/setup-tailwind/setup-tailwind.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAc1D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAIrD,wBAAsB,sBAAsB,CAC1C,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC,IAAI,GAAG,iBAAiB,CAAC,CA2BnC;AAED,eAAe,sBAAsB,CAAC"}
@@ -1,25 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.setupTailwindGenerator = setupTailwindGenerator;
4
- const devkit_1 = require("@nx/devkit");
5
- const versions_1 = require("../../utils/versions");
6
- const add_tailwind_style_imports_1 = require("./lib/add-tailwind-style-imports");
7
- const path_1 = require("path");
8
- async function setupTailwindGenerator(tree, options) {
9
- devkit_1.logger.warn(`The 'setup-tailwind' generator is deprecated. Generating Tailwind configuration is no longer maintained. This generator will be removed in Nx 23.`);
10
- let installTask = undefined;
11
- const project = (0, devkit_1.readProjectConfiguration)(tree, options.project);
12
- (0, devkit_1.generateFiles)(tree, (0, path_1.join)(__dirname, './files'), project.root, {});
13
- (0, add_tailwind_style_imports_1.addTailwindStyleImports)(tree, project, options);
14
- if (!options.skipPackageJson) {
15
- installTask = (0, devkit_1.addDependenciesToPackageJson)(tree, {}, {
16
- autoprefixer: versions_1.autoprefixerVersion,
17
- postcss: versions_1.postcssVersion,
18
- tailwindcss: versions_1.tailwindcssVersion,
19
- });
20
- }
21
- if (!options.skipFormat)
22
- await (0, devkit_1.formatFiles)(tree);
23
- return installTask;
24
- }
25
- exports.default = setupTailwindGenerator;