@nx/angular 19.5.0-beta.0 → 19.5.0-beta.1
Sign up to get free protection for your applications and to get access to all the features.
- package/migrations.json +70 -0
- package/package.json +9 -9
- package/plugins/component-testing.js +1 -2
- package/src/builders/dev-server/dev-server.impl.js +1 -2
- package/src/builders/dev-server/lib/normalize-options.js +1 -2
- package/src/builders/dev-server/lib/validate-options.js +5 -2
- package/src/builders/dev-server/schema.d.ts +1 -0
- package/src/builders/dev-server/schema.json +11 -0
- package/src/builders/module-federation-dev-ssr/module-federation-dev-ssr.impl.js +1 -2
- package/src/builders/utilities/buildable-libs.js +1 -2
- package/src/builders/utilities/module-federation.js +4 -5
- package/src/builders/utilities/webpack.js +3 -4
- package/src/builders/webpack-browser/webpack-browser.impl.js +9 -3
- package/src/builders/webpack-server/webpack-server.impl.js +1 -2
- package/src/executors/application/application.impl.js +1 -1
- package/src/executors/application/utils/validate-options.js +1 -2
- package/src/executors/browser-esbuild/browser-esbuild.impl.js +1 -1
- package/src/executors/delegate-build/delegate-build.impl.js +1 -2
- package/src/executors/extract-i18n/extract-i18n.impl.js +1 -1
- package/src/executors/module-federation-dev-server/lib/build-static-remotes.js +1 -2
- package/src/executors/module-federation-dev-server/lib/normalize-options.js +1 -2
- package/src/executors/module-federation-dev-server/lib/parse-static-remotes-config.js +1 -2
- package/src/executors/module-federation-dev-server/lib/start-dev-remotes.js +1 -2
- package/src/executors/module-federation-dev-server/lib/start-static-remotes-file-server.js +1 -2
- package/src/executors/module-federation-dev-server/module-federation-dev-server.impl.js +1 -2
- package/src/executors/ng-packagr-lite/ng-packagr-adjustments/ng-packagr.js +1 -2
- package/src/executors/ng-packagr-lite/ng-packagr-adjustments/pre-v17/ngc/compile-source-files.js +1 -2
- package/src/executors/package/ng-packagr-adjustments/ng-packagr.js +1 -2
- package/src/executors/package/ng-packagr-adjustments/ngc/compile-source-files.js +1 -2
- package/src/executors/package/ng-packagr-adjustments/utils/ng-compiler-cli.js +1 -2
- package/src/executors/package/package.impl.js +2 -2
- package/src/executors/utilities/angular-version-utils.js +2 -3
- package/src/executors/utilities/buildable-libs.js +1 -2
- package/src/executors/utilities/esbuild-extensions.js +3 -4
- package/src/executors/utilities/module-loader.js +2 -3
- package/src/executors/utilities/ng-packagr/tailwindcss.js +3 -4
- package/src/executors/utilities/patch-builder-context.js +1 -2
- package/src/executors/utilities/typescript.js +1 -2
- package/src/generators/add-linting/add-linting.js +1 -2
- package/src/generators/add-linting/lib/add-angular-eslint-dependencies.js +1 -2
- package/src/generators/add-linting/lib/buildable-project.js +1 -2
- package/src/generators/add-linting/lib/create-eslint-configuration.d.ts +24 -24
- package/src/generators/add-linting/lib/create-eslint-configuration.js +2 -2
- package/src/generators/application/application.js +2 -3
- package/src/generators/application/files/base/tsconfig.json__tpl__ +2 -2
- package/src/generators/application/files/ng-module/src/app/app.component.spec.ts__tpl__ +4 -3
- package/src/generators/application/files/standalone-components/src/app/app.component.spec.ts__tpl__ +4 -3
- package/src/generators/application/lib/add-e2e.js +1 -2
- package/src/generators/application/lib/add-linting.js +1 -2
- package/src/generators/application/lib/add-proxy-config.js +1 -2
- package/src/generators/application/lib/add-unit-test-runner.js +1 -2
- package/src/generators/application/lib/create-files.js +8 -5
- package/src/generators/application/lib/create-project.js +1 -2
- package/src/generators/application/lib/enable-strict-type-checking.js +1 -2
- package/src/generators/application/lib/normalize-options.js +1 -2
- package/src/generators/application/lib/set-app-strict-default.js +1 -2
- package/src/generators/application/lib/set-generator-defaults.js +1 -2
- package/src/generators/application/lib/update-editor-tsconfig.js +1 -2
- package/src/generators/component/component.js +2 -3
- package/src/generators/component/lib/component.js +1 -2
- package/src/generators/component/lib/module.js +1 -2
- package/src/generators/component/lib/normalize-options.js +1 -2
- package/src/generators/component/lib/set-generator-defaults.js +1 -2
- package/src/generators/component-cypress-spec/component-cypress-spec.js +1 -2
- package/src/generators/component-cypress-spec/lib/get-args-default-value.js +1 -2
- package/src/generators/component-cypress-spec/lib/get-component-selector.js +1 -2
- package/src/generators/component-story/component-story.js +1 -2
- package/src/generators/component-test/component-test.js +1 -2
- package/src/generators/convert-to-application-executor/convert-to-application-executor.js +1 -2
- package/src/generators/convert-to-with-mf/convert-to-with-mf.js +1 -2
- package/src/generators/convert-to-with-mf/lib/check-name-matches.js +1 -2
- package/src/generators/convert-to-with-mf/lib/check-shared-npm-packages.js +1 -2
- package/src/generators/convert-to-with-mf/lib/get-webpack-config-path.js +1 -2
- package/src/generators/convert-to-with-mf/lib/is-host-remote-config.js +3 -4
- package/src/generators/convert-to-with-mf/lib/parse-ast-webpack-config.js +1 -2
- package/src/generators/convert-to-with-mf/lib/write-new-webpack-config.js +1 -2
- package/src/generators/cypress-component-configuration/cypress-component-configuration.js +2 -3
- package/src/generators/directive/directive.js +1 -2
- package/src/generators/directive/lib/normalize-options.js +1 -2
- package/src/generators/federate-module/federate-module.js +1 -2
- package/src/generators/federate-module/lib/add-file-to-remote-tsconfig.js +1 -2
- package/src/generators/federate-module/lib/add-path-to-exposes.js +1 -2
- package/src/generators/federate-module/lib/add-path-to-ts-config.js +1 -2
- package/src/generators/federate-module/lib/add-remote.js +1 -2
- package/src/generators/federate-module/lib/check-remote-exists.js +1 -2
- package/src/generators/host/host.js +2 -3
- package/src/generators/host/lib/update-ssr-setup.js +1 -2
- package/src/generators/init/init.js +1 -2
- package/src/generators/library/files/base/tsconfig.json__tpl__ +2 -2
- package/src/generators/library/lib/add-children.js +1 -2
- package/src/generators/library/lib/add-load-children.js +1 -2
- package/src/generators/library/lib/add-module.js +1 -2
- package/src/generators/library/lib/add-project.js +1 -2
- package/src/generators/library/lib/add-standalone-component.js +1 -2
- package/src/generators/library/lib/create-files.js +3 -2
- package/src/generators/library/lib/enable-strict-type-checking.js +2 -3
- package/src/generators/library/lib/normalize-options.js +1 -2
- package/src/generators/library/lib/set-generator-defaults.js +1 -2
- package/src/generators/library/lib/update-lib-package-npm-scope.js +1 -2
- package/src/generators/library/lib/update-tsconfig.js +1 -2
- package/src/generators/library/library.js +2 -3
- package/src/generators/library-secondary-entry-point/lib/add-files.js +1 -2
- package/src/generators/library-secondary-entry-point/lib/add-path-mapping.js +1 -2
- package/src/generators/library-secondary-entry-point/lib/normalize-options.js +1 -2
- package/src/generators/library-secondary-entry-point/lib/update-tsconfig-included-files.js +1 -2
- package/src/generators/library-secondary-entry-point/library-secondary-entry-point.js +1 -2
- package/src/generators/move/lib/update-module-name.js +1 -2
- package/src/generators/move/lib/update-ng-package.js +1 -2
- package/src/generators/move/lib/update-secondary-entry-points.js +1 -2
- package/src/generators/move/move-impl.js +1 -2
- package/src/generators/move/move.js +2 -3
- package/src/generators/ng-add/migrate-from-angular-cli.js +1 -2
- package/src/generators/ng-add/ng-add.js +1 -2
- package/src/generators/ng-add/utilities/dependencies.js +1 -2
- package/src/generators/ng-add/utilities/format-files-task.js +1 -2
- package/src/generators/ng-add/utilities/projects.js +2 -3
- package/src/generators/ng-add/utilities/validation-logging.js +2 -3
- package/src/generators/ng-add/utilities/workspace.js +13 -14
- package/src/generators/ngrx/lib/add-exports-barrel.js +1 -2
- package/src/generators/ngrx/lib/add-imports-to-module.js +1 -2
- package/src/generators/ngrx/lib/add-ngrx-to-package-json.js +1 -2
- package/src/generators/ngrx/lib/generate-files.js +1 -2
- package/src/generators/ngrx/lib/normalize-options.js +1 -2
- package/src/generators/ngrx/lib/validate-options.js +1 -2
- package/src/generators/ngrx/ngrx.js +1 -2
- package/src/generators/ngrx-feature-store/lib/add-exports-barrel.js +1 -2
- package/src/generators/ngrx-feature-store/lib/add-imports.js +1 -2
- package/src/generators/ngrx-feature-store/lib/add-ngrx-to-package-json.js +1 -2
- package/src/generators/ngrx-feature-store/lib/generate-files.js +1 -2
- package/src/generators/ngrx-feature-store/lib/normalize-options.js +1 -2
- package/src/generators/ngrx-feature-store/lib/validate-options.js +1 -2
- package/src/generators/ngrx-feature-store/ngrx-feature-store.js +1 -2
- package/src/generators/ngrx-root-store/lib/add-imports.js +1 -2
- package/src/generators/ngrx-root-store/lib/add-ngrx-to-package-json.js +1 -2
- package/src/generators/ngrx-root-store/lib/normalize-options.js +1 -2
- package/src/generators/ngrx-root-store/lib/validate-options.js +1 -2
- package/src/generators/ngrx-root-store/ngrx-root-store.js +1 -2
- package/src/generators/pipe/lib/normalize-options.js +1 -2
- package/src/generators/pipe/pipe.js +1 -2
- package/src/generators/remote/lib/find-next-available-port.js +1 -2
- package/src/generators/remote/lib/update-ssr-setup.js +1 -2
- package/src/generators/remote/remote.js +2 -3
- package/src/generators/scam/lib/convert-component-to-scam.js +1 -2
- package/src/generators/scam/lib/normalize-options.js +1 -2
- package/src/generators/scam/scam.js +1 -2
- package/src/generators/scam-directive/lib/convert-directive-to-scam.js +1 -2
- package/src/generators/scam-directive/lib/normalize-options.js +1 -2
- package/src/generators/scam-directive/scam-directive.js +1 -2
- package/src/generators/scam-pipe/lib/convert-pipe-to-scam.js +1 -2
- package/src/generators/scam-pipe/lib/normalize-options.js +1 -2
- package/src/generators/scam-pipe/scam-pipe.js +1 -2
- package/src/generators/scam-to-standalone/lib/convert-scam-to-standalone.js +1 -2
- package/src/generators/scam-to-standalone/lib/get-component-data-from-ast.js +1 -2
- package/src/generators/scam-to-standalone/lib/get-module-metadata-from-ast.js +1 -2
- package/src/generators/scam-to-standalone/lib/get-target-project.js +1 -2
- package/src/generators/scam-to-standalone/lib/replace-module-usages-with-component.js +1 -2
- package/src/generators/scam-to-standalone/lib/selector-exists-in-ast.js +1 -2
- package/src/generators/scam-to-standalone/lib/verify-is-inline-scam.js +1 -2
- package/src/generators/scam-to-standalone/lib/verify-module-is-scam.js +1 -2
- package/src/generators/scam-to-standalone/scam-to-standalone.js +1 -2
- package/src/generators/setup-mf/files/host-files/app.component.spec.ts__tmpl__ +8 -5
- package/src/generators/setup-mf/lib/add-cypress-workaround.js +1 -2
- package/src/generators/setup-mf/lib/add-remote-entry.js +1 -2
- package/src/generators/setup-mf/lib/add-remote-to-host.js +3 -4
- package/src/generators/setup-mf/lib/change-build-target.js +1 -2
- package/src/generators/setup-mf/lib/fix-bootstrap.js +1 -2
- package/src/generators/setup-mf/lib/generate-config.js +1 -2
- package/src/generators/setup-mf/lib/get-remotes-with-ports.js +1 -2
- package/src/generators/setup-mf/lib/normalize-options.js +1 -2
- package/src/generators/setup-mf/lib/remove-dead-code-from-remote.js +1 -2
- package/src/generators/setup-mf/lib/setup-host-if-dynamic.js +1 -2
- package/src/generators/setup-mf/lib/setup-serve-target.js +1 -2
- package/src/generators/setup-mf/lib/setup-tspath-for-remote.js +1 -2
- package/src/generators/setup-mf/lib/update-host-app-routes.d.ts +2 -2
- package/src/generators/setup-mf/lib/update-host-app-routes.js +5 -10
- package/src/generators/setup-mf/lib/update-tsconfig.js +1 -2
- package/src/generators/setup-mf/setup-mf.js +1 -2
- package/src/generators/setup-ssr/lib/add-dependencies.js +1 -2
- package/src/generators/setup-ssr/lib/add-hydration.js +1 -2
- package/src/generators/setup-ssr/lib/add-server-file.js +1 -2
- package/src/generators/setup-ssr/lib/generate-files.js +1 -2
- package/src/generators/setup-ssr/lib/generate-server-ts-config.js +2 -3
- package/src/generators/setup-ssr/lib/normalize-options.js +1 -2
- package/src/generators/setup-ssr/lib/set-router-initial-navigation.js +1 -2
- package/src/generators/setup-ssr/lib/update-project-config.js +2 -3
- package/src/generators/setup-ssr/lib/validate-options.js +1 -2
- package/src/generators/setup-ssr/setup-ssr.js +1 -2
- package/src/generators/setup-tailwind/lib/add-tailwind-config-path-to-project.js +1 -2
- package/src/generators/setup-tailwind/lib/add-tailwind-config.js +1 -2
- package/src/generators/setup-tailwind/lib/add-tailwind-required-packages.js +1 -2
- package/src/generators/setup-tailwind/lib/detect-tailwind-installed-version.js +1 -2
- package/src/generators/setup-tailwind/lib/normalize-options.js +1 -2
- package/src/generators/setup-tailwind/lib/update-application-styles.js +1 -2
- package/src/generators/setup-tailwind/setup-tailwind.js +1 -2
- package/src/generators/stories/lib/get-e2e-project.js +1 -2
- package/src/generators/stories/stories.js +1 -2
- package/src/generators/storybook-configuration/lib/assert-compatible-storybook-version.js +1 -2
- package/src/generators/storybook-configuration/lib/generate-stories.js +1 -2
- package/src/generators/storybook-configuration/lib/generate-storybook-configuration.js +1 -2
- package/src/generators/storybook-configuration/lib/validate-options.js +1 -2
- package/src/generators/storybook-configuration/storybook-configuration.js +1 -2
- package/src/generators/utils/add-jest.js +1 -2
- package/src/generators/utils/add-mf-env-to-inputs.js +1 -2
- package/src/generators/utils/dependencies.js +1 -2
- package/src/generators/utils/ensure-angular-dependencies.js +1 -2
- package/src/generators/utils/entry-point.js +1 -2
- package/src/generators/utils/export-scam.js +1 -2
- package/src/generators/utils/find-module.js +2 -3
- package/src/generators/utils/insert-ngmodule-import.js +2 -3
- package/src/generators/utils/path.js +1 -2
- package/src/generators/utils/project.js +1 -2
- package/src/generators/utils/selector.js +2 -3
- package/src/generators/utils/storybook-ast/component-info.js +3 -4
- package/src/generators/utils/storybook-ast/entry-point.js +1 -2
- package/src/generators/utils/storybook-ast/module-info.js +2 -3
- package/src/generators/utils/storybook-ast/storybook-inputs.js +4 -5
- package/src/generators/utils/storybook-ast/tree-utilities.js +1 -2
- package/src/generators/utils/testing.js +5 -6
- package/src/generators/utils/update-app-editor-tsconfig-excluded-files.js +1 -2
- package/src/generators/utils/update-project-root-tsconfig.js +2 -2
- package/src/generators/utils/validations.js +1 -2
- package/src/generators/utils/version-utils.js +6 -7
- package/src/generators/web-worker/lib/add-snippet.js +1 -2
- package/src/generators/web-worker/lib/normalize-options.js +1 -2
- package/src/generators/web-worker/web-worker.js +1 -2
- package/src/migrations/update-14-2-0/remove-show-circular-dependencies-option.js +1 -1
- package/src/migrations/update-14-2-0/update-angular-cli.js +1 -1
- package/src/migrations/update-14-2-0/update-libraries-secondary-entrypoints.js +1 -1
- package/src/migrations/update-14-2-0/update-ngcc-target.js +1 -1
- package/src/migrations/update-14-2-0/update-router-initial-navigation.js +6 -3
- package/src/migrations/update-14-2-0/update-tsconfig-target.js +2 -2
- package/src/migrations/update-14-5-0/migrate-mfe-to-mf.js +4 -5
- package/src/migrations/update-14-5-2/update-angular-cli.js +1 -1
- package/src/migrations/update-14-6-0/update-angular-cli.js +1 -1
- package/src/migrations/update-14-8-0/rename-webpack-server.js +1 -1
- package/src/migrations/update-15-0-0/add-karma-inputs.js +1 -1
- package/src/migrations/update-15-0-0/switch-to-jasmine-marbles.js +1 -1
- package/src/migrations/update-15-2-0/remove-browserlist-config.js +1 -1
- package/src/migrations/update-15-2-0/remove-platform-server-exports.js +1 -1
- package/src/migrations/update-15-2-0/update-angular-cli.js +1 -1
- package/src/migrations/update-15-2-0/update-karma-main-file.js +1 -1
- package/src/migrations/update-15-2-0/update-typescript-target.js +1 -1
- package/src/migrations/update-15-2-0/update-workspace-config.js +1 -1
- package/src/migrations/update-15-5-0/update-angular-cli.js +1 -1
- package/src/migrations/update-15-7-0/install-required-packages.js +1 -1
- package/src/migrations/update-15-8-0/update-angular-cli.js +1 -1
- package/src/migrations/update-15-9-0/update-file-server-executor.js +1 -1
- package/src/migrations/update-15-9-0/update-testing-tsconfig.js +1 -2
- package/src/migrations/update-16-0-0/remove-karma-defaults.js +1 -1
- package/src/migrations/update-16-0-0/remove-library-generator-simple-module-name-option.js +1 -1
- package/src/migrations/update-16-0-0/remove-protractor-defaults.js +1 -1
- package/src/migrations/update-16-0-0-add-nx-packages/update-16-0-0-add-nx-packages.js +1 -1
- package/src/migrations/update-16-1-0/extract-standalone-config-from-bootstrap.js +1 -1
- package/src/migrations/update-16-1-0/remove-ngcc-invocation.js +1 -1
- package/src/migrations/update-16-1-0/remove-render-module-platform-server-exports.js +1 -1
- package/src/migrations/update-16-1-0/update-angular-cli.js +1 -1
- package/src/migrations/update-16-1-0/update-server-executor-config.js +1 -1
- package/src/migrations/update-16-2-0/switch-data-persistence-operators-imports-to-ngrx-router-store.js +1 -1
- package/src/migrations/update-16-4-0/rename-angular-eslint-accesibility-rules.js +1 -1
- package/src/migrations/update-16-4-0/update-angular-cli.js +1 -1
- package/src/migrations/update-16-6-0/explicitly-set-projects-to-update-buildable-deps.js +1 -1
- package/src/migrations/update-16-7-0/update-angular-cli.js +1 -1
- package/src/migrations/update-17-1-0/browser-target-to-build-target.js +1 -1
- package/src/migrations/update-17-1-0/replace-nguniversal-builders.js +1 -1
- package/src/migrations/update-17-1-0/replace-nguniversal-engines.js +1 -1
- package/src/migrations/update-17-1-0/update-angular-cli.js +1 -1
- package/src/migrations/update-17-1-0/update-zone-js-deep-import.js +1 -1
- package/src/migrations/update-17-2-0/rename-webpack-dev-server.js +1 -1
- package/src/migrations/update-17-3-0/add-autoprefixer-dependency.js +1 -1
- package/src/migrations/update-17-3-0/add-browser-sync-dependency.js +1 -1
- package/src/migrations/update-17-3-0/update-angular-cli.js +1 -1
- package/src/migrations/update-18-0-0/add-mf-env-var-to-target-defaults.js +1 -1
- package/src/migrations/update-18-1-0/update-angular-cli.js +1 -1
- package/src/migrations/update-18-1-1/fix-target-defaults-inputs.js +1 -1
- package/src/migrations/update-18-2-0/update-angular-cli.js +1 -1
- package/src/migrations/update-19-1-0/update-angular-cli.js +1 -1
- package/src/migrations/update-19-2-1/add-typescript-eslint-utils.d.ts +1 -1
- package/src/migrations/update-19-2-1/add-typescript-eslint-utils.js +2 -2
- package/src/migrations/update-19-5-0/update-angular-cli.d.ts +3 -0
- package/src/migrations/update-19-5-0/update-angular-cli.js +23 -0
- package/src/migrations/utils/projects.js +1 -2
- package/src/utils/cli-config-utils.js +1 -2
- package/src/utils/get-mf-projects.js +1 -2
- package/src/utils/mf/utils.js +4 -4
- package/src/utils/mf/with-module-federation-ssr.js +1 -2
- package/src/utils/mf/with-module-federation.js +1 -2
- package/src/utils/nx-devkit/ast-utils.js +23 -24
- package/src/utils/nx-devkit/route-utils.js +2 -3
- package/src/utils/nx-devkit/testing.js +4 -5
- package/src/utils/targets.js +1 -2
- package/src/utils/version-utils.js +2 -3
- package/src/utils/versions.d.ts +4 -4
- package/src/utils/versions.js +4 -4
- package/tailwind.js +1 -2
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.componentTestGenerator =
|
3
|
+
exports.componentTestGenerator = componentTestGenerator;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const versions_1 = require("../../utils/versions");
|
6
6
|
const storybook_inputs_1 = require("../utils/storybook-ast/storybook-inputs");
|
@@ -27,5 +27,4 @@ async function componentTestGenerator(tree, options) {
|
|
27
27
|
await (0, devkit_1.formatFiles)(tree);
|
28
28
|
}
|
29
29
|
}
|
30
|
-
exports.componentTestGenerator = componentTestGenerator;
|
31
30
|
exports.default = componentTestGenerator;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.convertToApplicationExecutor =
|
3
|
+
exports.convertToApplicationExecutor = convertToApplicationExecutor;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const posix_1 = require("node:path/posix");
|
6
6
|
const semver_1 = require("semver");
|
@@ -55,7 +55,6 @@ async function convertToApplicationExecutor(tree, options) {
|
|
55
55
|
}
|
56
56
|
return didAnySucceed ? () => (0, devkit_1.installPackagesTask)(tree) : () => { };
|
57
57
|
}
|
58
|
-
exports.convertToApplicationExecutor = convertToApplicationExecutor;
|
59
58
|
async function convertProjectTargets(tree, projectName, angularVersion, isProvidedProject = false) {
|
60
59
|
function warnIfProvided(message) {
|
61
60
|
if (isProvidedProject) {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.convertToWithMF =
|
3
|
+
exports.convertToWithMF = convertToWithMF;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const get_mf_projects_1 = require("../../utils/get-mf-projects");
|
6
6
|
const lib_1 = require("./lib");
|
@@ -28,5 +28,4 @@ async function convertToWithMF(tree, schema) {
|
|
28
28
|
await (0, devkit_1.formatFiles)(tree);
|
29
29
|
}
|
30
30
|
}
|
31
|
-
exports.convertToWithMF = convertToWithMF;
|
32
31
|
exports.default = convertToWithMF;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.checkOutputNameMatchesProjectName =
|
3
|
+
exports.checkOutputNameMatchesProjectName = checkOutputNameMatchesProjectName;
|
4
4
|
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
5
5
|
function checkOutputNameMatchesProjectName(ast, projectName) {
|
6
6
|
(0, ensure_typescript_1.ensureTypescript)();
|
@@ -22,4 +22,3 @@ function checkOutputNameMatchesProjectName(ast, projectName) {
|
|
22
22
|
const uniqueName = uniqueNameNodes[0].getText().replace(/'/g, '');
|
23
23
|
return uniqueName === projectName;
|
24
24
|
}
|
25
|
-
exports.checkOutputNameMatchesProjectName = checkOutputNameMatchesProjectName;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.checkSharedNpmPackagesMatchExpected =
|
3
|
+
exports.checkSharedNpmPackagesMatchExpected = checkSharedNpmPackagesMatchExpected;
|
4
4
|
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
5
5
|
function checkSharedNpmPackagesMatchExpected(ast) {
|
6
6
|
(0, ensure_typescript_1.ensureTypescript)();
|
@@ -47,4 +47,3 @@ function checkSharedNpmPackagesMatchExpected(ast) {
|
|
47
47
|
}
|
48
48
|
return packagesMatch;
|
49
49
|
}
|
50
|
-
exports.checkSharedNpmPackagesMatchExpected = checkSharedNpmPackagesMatchExpected;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.getWebpackConfigPath =
|
3
|
+
exports.getWebpackConfigPath = getWebpackConfigPath;
|
4
4
|
function getWebpackConfigPath(project, projectName) {
|
5
5
|
let pathToWebpackConfig = '';
|
6
6
|
for (const target of Object.values(project.targets ?? {})) {
|
@@ -16,4 +16,3 @@ function getWebpackConfigPath(project, projectName) {
|
|
16
16
|
}
|
17
17
|
return pathToWebpackConfig;
|
18
18
|
}
|
19
|
-
exports.getWebpackConfigPath = getWebpackConfigPath;
|
@@ -1,6 +1,8 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.isHostRemoteConfig = isHostRemoteConfig;
|
4
|
+
exports.getRemotesFromHost = getRemotesFromHost;
|
5
|
+
exports.getExposedModulesFromRemote = getExposedModulesFromRemote;
|
4
6
|
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
5
7
|
const REMOTES_EXPRESSION_SELECTOR = 'PropertyAssignment:has(Identifier[name=remotes]) > ObjectLiteralExpression';
|
6
8
|
const EXPOSES_EXPRESSION_SELECTOR = 'PropertyAssignment:has(Identifier[name=exposes]) > ObjectLiteralExpression';
|
@@ -25,7 +27,6 @@ function isHostRemoteConfig(ast) {
|
|
25
27
|
let result = isHost && isRemote ? 'both' : isHost ? 'host' : isRemote ? 'remote' : false;
|
26
28
|
return result;
|
27
29
|
}
|
28
|
-
exports.isHostRemoteConfig = isHostRemoteConfig;
|
29
30
|
function getRemotesFromHost(ast) {
|
30
31
|
(0, ensure_typescript_1.ensureTypescript)();
|
31
32
|
const { tsquery } = require('@phenomnomnominal/tsquery');
|
@@ -53,7 +54,6 @@ function getRemotesFromHost(ast) {
|
|
53
54
|
}
|
54
55
|
return remotes;
|
55
56
|
}
|
56
|
-
exports.getRemotesFromHost = getRemotesFromHost;
|
57
57
|
function getExposedModulesFromRemote(ast) {
|
58
58
|
(0, ensure_typescript_1.ensureTypescript)();
|
59
59
|
const { tsquery } = require('@phenomnomnominal/tsquery');
|
@@ -65,4 +65,3 @@ function getExposedModulesFromRemote(ast) {
|
|
65
65
|
}
|
66
66
|
return exposesObjectNodes[0].getText();
|
67
67
|
}
|
68
|
-
exports.getExposedModulesFromRemote = getExposedModulesFromRemote;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.parseASTOfWebpackConfig =
|
3
|
+
exports.parseASTOfWebpackConfig = parseASTOfWebpackConfig;
|
4
4
|
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
5
5
|
function parseASTOfWebpackConfig(tree, pathToWebpackConfig) {
|
6
6
|
if (!tree.exists(pathToWebpackConfig)) {
|
@@ -11,4 +11,3 @@ function parseASTOfWebpackConfig(tree, pathToWebpackConfig) {
|
|
11
11
|
const source = tree.read(pathToWebpackConfig, 'utf-8');
|
12
12
|
return tsquery.ast(source);
|
13
13
|
}
|
14
|
-
exports.parseASTOfWebpackConfig = parseASTOfWebpackConfig;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.writeNewWebpackConfig =
|
3
|
+
exports.writeNewWebpackConfig = writeNewWebpackConfig;
|
4
4
|
const is_host_remote_config_1 = require("./is-host-remote-config");
|
5
5
|
function writeNewWebpackConfig(ast, mfType, projectName) {
|
6
6
|
const webpackConfig = `const { withModuleFederation } = require('@nx/angular/module-federation');
|
@@ -42,7 +42,6 @@ module.exports = withModuleFederation(config);
|
|
42
42
|
}
|
43
43
|
return [webpackConfig, mfeConfig];
|
44
44
|
}
|
45
|
-
exports.writeNewWebpackConfig = writeNewWebpackConfig;
|
46
45
|
function hostRemotesToString(ast) {
|
47
46
|
const remotes = (0, is_host_remote_config_1.getRemotesFromHost)(ast)
|
48
47
|
.reduce((acc, remotePair) => `['${remotePair[0]}', '${remotePair[1]}'], ${acc}`, '')
|
@@ -1,6 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.cypressComponentConfiguration = cypressComponentConfiguration;
|
4
|
+
exports.cypressComponentConfigurationInternal = cypressComponentConfigurationInternal;
|
4
5
|
const devkit_1 = require("@nx/devkit");
|
5
6
|
const path_1 = require("path");
|
6
7
|
const versions_1 = require("../../utils/versions");
|
@@ -14,7 +15,6 @@ function cypressComponentConfiguration(tree, options) {
|
|
14
15
|
...options,
|
15
16
|
});
|
16
17
|
}
|
17
|
-
exports.cypressComponentConfiguration = cypressComponentConfiguration;
|
18
18
|
/**
|
19
19
|
* This is for cypress built in component testing, if you want to test with
|
20
20
|
* storybook + cypress then use the componentCypressGenerator instead.
|
@@ -38,7 +38,6 @@ async function cypressComponentConfigurationInternal(tree, options) {
|
|
38
38
|
}
|
39
39
|
return installTask;
|
40
40
|
}
|
41
|
-
exports.cypressComponentConfigurationInternal = cypressComponentConfigurationInternal;
|
42
41
|
async function addFiles(tree, projectConfig, options) {
|
43
42
|
const componentFile = (0, devkit_1.joinPathFragments)(projectConfig.root, 'cypress', 'support', 'component.ts');
|
44
43
|
const { addMountDefinition } = require('@nx/cypress/src/utils/config');
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.directiveGenerator =
|
3
|
+
exports.directiveGenerator = directiveGenerator;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const utils_1 = require("../utils");
|
6
6
|
const lib_1 = require("./lib");
|
@@ -25,5 +25,4 @@ async function directiveGenerator(tree, schema) {
|
|
25
25
|
await (0, devkit_1.formatFiles)(tree);
|
26
26
|
}
|
27
27
|
}
|
28
|
-
exports.directiveGenerator = directiveGenerator;
|
29
28
|
exports.default = directiveGenerator;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.normalizeOptions =
|
3
|
+
exports.normalizeOptions = normalizeOptions;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const selector_1 = require("../../utils/selector");
|
6
6
|
const artifact_name_and_directory_utils_1 = require("@nx/devkit/src/generators/artifact-name-and-directory-utils");
|
@@ -34,4 +34,3 @@ async function normalizeOptions(tree, options) {
|
|
34
34
|
standalone: options.standalone ?? true,
|
35
35
|
};
|
36
36
|
}
|
37
|
-
exports.normalizeOptions = normalizeOptions;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.federateModuleGenerator =
|
3
|
+
exports.federateModuleGenerator = federateModuleGenerator;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const lib_1 = require("./lib");
|
6
6
|
async function federateModuleGenerator(tree, schema) {
|
@@ -36,5 +36,4 @@ async function federateModuleGenerator(tree, schema) {
|
|
36
36
|
`);
|
37
37
|
return (0, devkit_1.runTasksInSerial)(...tasks);
|
38
38
|
}
|
39
|
-
exports.federateModuleGenerator = federateModuleGenerator;
|
40
39
|
exports.default = federateModuleGenerator;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addFileToRemoteTsconfig =
|
3
|
+
exports.addFileToRemoteTsconfig = addFileToRemoteTsconfig;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function addFileToRemoteTsconfig(tree, remoteName, pathToExpose) {
|
6
6
|
const remote = (0, devkit_1.readProjectConfiguration)(tree, remoteName);
|
@@ -12,4 +12,3 @@ function addFileToRemoteTsconfig(tree, remoteName, pathToExpose) {
|
|
12
12
|
],
|
13
13
|
}));
|
14
14
|
}
|
15
|
-
exports.addFileToRemoteTsconfig = addFileToRemoteTsconfig;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addPathToExposes =
|
3
|
+
exports.addPathToExposes = addPathToExposes;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
6
6
|
let tsModule;
|
@@ -10,7 +10,6 @@ function addPathToExposes(tree, { projectPath, moduleName, modulePath }) {
|
|
10
10
|
: 'module-federation.config.js');
|
11
11
|
updateExposesProperty(tree, moduleFederationConfigPath, moduleName, modulePath);
|
12
12
|
}
|
13
|
-
exports.addPathToExposes = addPathToExposes;
|
14
13
|
function updateExposesProperty(tree, moduleFederationConfigPath, moduleName, modulePath) {
|
15
14
|
if (!tsModule) {
|
16
15
|
tsModule = (0, ensure_typescript_1.ensureTypescript)();
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addPathToTsConfig =
|
3
|
+
exports.addPathToTsConfig = addPathToTsConfig;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const js_1 = require("@nx/js");
|
6
6
|
function addPathToTsConfig(tree, { remoteName, moduleName, pathToFile }) {
|
@@ -9,4 +9,3 @@ function addPathToTsConfig(tree, { remoteName, moduleName, pathToFile }) {
|
|
9
9
|
(0, js_1.addTsConfigPath)(tree, `${remoteName}/${moduleName}`, [pathToFile]);
|
10
10
|
}
|
11
11
|
}
|
12
|
-
exports.addPathToTsConfig = addPathToTsConfig;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addRemote =
|
3
|
+
exports.addRemote = addRemote;
|
4
4
|
const tslib_1 = require("tslib");
|
5
5
|
const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
|
6
6
|
const test_runners_1 = require("../../../utils/test-runners");
|
@@ -43,4 +43,3 @@ async function addRemote(tree, schema) {
|
|
43
43
|
remoteName,
|
44
44
|
};
|
45
45
|
}
|
46
|
-
exports.addRemote = addRemote;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.getRemoteIfExists =
|
3
|
+
exports.getRemoteIfExists = getRemoteIfExists;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function getRemoteIfExists(tree, remote) {
|
6
6
|
const remoteProject = getRemote(tree, remote);
|
@@ -11,7 +11,6 @@ function getRemoteIfExists(tree, remote) {
|
|
11
11
|
tree.exists((0, devkit_1.joinPathFragments)(remoteProject.root, 'module-federation.config.js'));
|
12
12
|
return hasModuleFederationConfig ? remoteProject : false;
|
13
13
|
}
|
14
|
-
exports.getRemoteIfExists = getRemoteIfExists;
|
15
14
|
function getRemote(tree, remote) {
|
16
15
|
try {
|
17
16
|
return (0, devkit_1.readProjectConfiguration)(tree, remote);
|
@@ -1,6 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.host = host;
|
4
|
+
exports.hostInternal = hostInternal;
|
4
5
|
const tslib_1 = require("tslib");
|
5
6
|
const devkit_1 = require("@nx/devkit");
|
6
7
|
const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
|
@@ -17,7 +18,6 @@ async function host(tree, options) {
|
|
17
18
|
...options,
|
18
19
|
});
|
19
20
|
}
|
20
|
-
exports.host = host;
|
21
21
|
async function hostInternal(tree, schema) {
|
22
22
|
const { typescriptConfiguration = true, ...options } = schema;
|
23
23
|
options.standalone = options.standalone ?? true;
|
@@ -109,5 +109,4 @@ async function hostInternal(tree, schema) {
|
|
109
109
|
}
|
110
110
|
return (0, devkit_1.runTasksInSerial)(...installTasks);
|
111
111
|
}
|
112
|
-
exports.hostInternal = hostInternal;
|
113
112
|
exports.default = host;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.updateSsrSetup =
|
3
|
+
exports.updateSsrSetup = updateSsrSetup;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const path_1 = require("path");
|
6
6
|
const versions_1 = require("../../../utils/versions");
|
@@ -45,4 +45,3 @@ async function updateSsrSetup(tree, options, appName, typescriptConfiguration) {
|
|
45
45
|
}
|
46
46
|
return () => { };
|
47
47
|
}
|
48
|
-
exports.updateSsrSetup = updateSsrSetup;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.angularInitGenerator =
|
3
|
+
exports.angularInitGenerator = angularInitGenerator;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const version_utils_1 = require("../utils/version-utils");
|
6
6
|
async function angularInitGenerator(tree, options) {
|
@@ -11,7 +11,6 @@ async function angularInitGenerator(tree, options) {
|
|
11
11
|
}
|
12
12
|
return installTask;
|
13
13
|
}
|
14
|
-
exports.angularInitGenerator = angularInitGenerator;
|
15
14
|
function installAngularDevkitCoreIfMissing(tree, options) {
|
16
15
|
const packageVersion = (0, version_utils_1.getInstalledPackageVersion)(tree, '@angular-devkit/core');
|
17
16
|
if (!packageVersion) {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addChildren =
|
3
|
+
exports.addChildren = addChildren;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const js_1 = require("@nx/js");
|
6
6
|
const ast_utils_1 = require("../../../utils/nx-devkit/ast-utils");
|
@@ -27,4 +27,3 @@ function addChildren(tree, options) {
|
|
27
27
|
const route = `{ path: '${(0, devkit_1.names)(options.fileName).fileName}', children: ${constName} }`;
|
28
28
|
(0, route_utils_1.addRoute)(tree, options.parent, route, false, constName, importPath);
|
29
29
|
}
|
30
|
-
exports.addChildren = addChildren;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addLoadChildren =
|
3
|
+
exports.addLoadChildren = addLoadChildren;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const route_utils_1 = require("../../../utils/nx-devkit/route-utils");
|
6
6
|
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
@@ -19,4 +19,3 @@ function addLoadChildren(tree, options) {
|
|
19
19
|
: options.moduleName}) }`;
|
20
20
|
(0, route_utils_1.addRoute)(tree, options.parent, route);
|
21
21
|
}
|
22
|
-
exports.addLoadChildren = addLoadChildren;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addModule =
|
3
|
+
exports.addModule = addModule;
|
4
4
|
const add_children_1 = require("./add-children");
|
5
5
|
const add_load_children_1 = require("./add-load-children");
|
6
6
|
function addModule(host, options) {
|
@@ -11,4 +11,3 @@ function addModule(host, options) {
|
|
11
11
|
(0, add_children_1.addChildren)(host, options);
|
12
12
|
}
|
13
13
|
}
|
14
|
-
exports.addModule = addModule;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addProject =
|
3
|
+
exports.addProject = addProject;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const add_build_target_defaults_1 = require("@nx/devkit/src/generators/add-build-target-defaults");
|
6
6
|
function addProject(tree, libraryOptions) {
|
@@ -38,4 +38,3 @@ function addProject(tree, libraryOptions) {
|
|
38
38
|
(0, devkit_1.addProjectConfiguration)(tree, libraryOptions.name, project);
|
39
39
|
return project;
|
40
40
|
}
|
41
|
-
exports.addProject = addProject;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addStandaloneComponent =
|
3
|
+
exports.addStandaloneComponent = addStandaloneComponent;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const component_1 = require("../../component/component");
|
6
6
|
const add_children_1 = require("./add-children");
|
@@ -26,4 +26,3 @@ async function addStandaloneComponent(tree, { libraryOptions, componentOptions }
|
|
26
26
|
}
|
27
27
|
}
|
28
28
|
}
|
29
|
-
exports.addStandaloneComponent = addStandaloneComponent;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.createFiles =
|
3
|
+
exports.createFiles = createFiles;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const js_1 = require("@nx/js");
|
6
6
|
const semver_1 = require("semver");
|
@@ -14,6 +14,7 @@ function createFiles(tree, options, project) {
|
|
14
14
|
: (0, devkit_1.joinPathFragments)(options.libraryOptions.fileName, options.libraryOptions.fileName);
|
15
15
|
const version = (0, version_utils_1.getInstalledAngularVersion)(tree);
|
16
16
|
const { major, minor } = (0, semver_1.parse)(version);
|
17
|
+
const disableModernClassFieldsBehavior = (0, semver_1.lt)(version, '18.1.0-rc.0');
|
17
18
|
const substitutions = {
|
18
19
|
libName: options.libraryOptions.name,
|
19
20
|
libFileName: options.libraryOptions.fileName,
|
@@ -28,6 +29,7 @@ function createFiles(tree, options, project) {
|
|
28
29
|
importPath: options.libraryOptions.importPath,
|
29
30
|
rootOffset,
|
30
31
|
angularPeerDepVersion: `^${major}.${minor}.0`,
|
32
|
+
disableModernClassFieldsBehavior,
|
31
33
|
tpl: '',
|
32
34
|
};
|
33
35
|
(0, devkit_1.generateFiles)(tree, (0, devkit_1.joinPathFragments)(__dirname, '../files/base'), options.libraryOptions.projectRoot, substitutions);
|
@@ -50,4 +52,3 @@ function createFiles(tree, options, project) {
|
|
50
52
|
tree.delete((0, devkit_1.joinPathFragments)(project.root, `package.json`));
|
51
53
|
}
|
52
54
|
}
|
53
|
-
exports.createFiles = createFiles;
|
@@ -1,6 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.enableStrictTypeChecking = enableStrictTypeChecking;
|
4
|
+
exports.setLibraryStrictDefault = setLibraryStrictDefault;
|
4
5
|
const devkit_1 = require("@nx/devkit");
|
5
6
|
/**
|
6
7
|
* Enable Strict Mode in the library and spec TS Config
|
@@ -8,7 +9,6 @@ const devkit_1 = require("@nx/devkit");
|
|
8
9
|
function enableStrictTypeChecking(host, options) {
|
9
10
|
updateTsConfig(host, options);
|
10
11
|
}
|
11
|
-
exports.enableStrictTypeChecking = enableStrictTypeChecking;
|
12
12
|
function setLibraryStrictDefault(host, isStrict) {
|
13
13
|
// set the default so future libraries use it
|
14
14
|
// unless the user has previously set this value
|
@@ -20,7 +20,6 @@ function setLibraryStrictDefault(host, isStrict) {
|
|
20
20
|
nxJson.generators['@nx/angular:library'].strict ?? isStrict;
|
21
21
|
(0, devkit_1.updateNxJson)(host, nxJson);
|
22
22
|
}
|
23
|
-
exports.setLibraryStrictDefault = setLibraryStrictDefault;
|
24
23
|
function updateTsConfig(host, options) {
|
25
24
|
// Update the settings in the tsconfig.app.json to enable strict type checking.
|
26
25
|
// This matches the settings defined by the Angular CL https://angular.io/guide/strict-mode
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.normalizeOptions =
|
3
|
+
exports.normalizeOptions = normalizeOptions;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
|
6
6
|
const eslint_1 = require("@nx/eslint");
|
@@ -74,4 +74,3 @@ async function normalizeOptions(host, schema) {
|
|
74
74
|
},
|
75
75
|
};
|
76
76
|
}
|
77
|
-
exports.normalizeOptions = normalizeOptions;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.setGeneratorDefaults =
|
3
|
+
exports.setGeneratorDefaults = setGeneratorDefaults;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function setGeneratorDefaults(tree, options) {
|
6
6
|
const nxJson = (0, devkit_1.readNxJson)(tree);
|
@@ -12,4 +12,3 @@ function setGeneratorDefaults(tree, options) {
|
|
12
12
|
};
|
13
13
|
(0, devkit_1.updateNxJson)(tree, nxJson);
|
14
14
|
}
|
15
|
-
exports.setGeneratorDefaults = setGeneratorDefaults;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.updateLibPackageNpmScope =
|
3
|
+
exports.updateLibPackageNpmScope = updateLibPackageNpmScope;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function updateLibPackageNpmScope(host, options) {
|
6
6
|
return (0, devkit_1.updateJson)(host, `${options.projectRoot}/package.json`, (json) => {
|
@@ -8,4 +8,3 @@ function updateLibPackageNpmScope(host, options) {
|
|
8
8
|
return json;
|
9
9
|
});
|
10
10
|
}
|
11
|
-
exports.updateLibPackageNpmScope = updateLibPackageNpmScope;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.updateTsConfig =
|
3
|
+
exports.updateTsConfig = updateTsConfig;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const js_1 = require("@nx/js");
|
6
6
|
const update_project_root_tsconfig_1 = require("../../utils/update-project-root-tsconfig");
|
@@ -34,4 +34,3 @@ function updateTsConfig(host, options) {
|
|
34
34
|
updateProjectConfig(host, options);
|
35
35
|
updateProjectIvyConfig(host, options);
|
36
36
|
}
|
37
|
-
exports.updateTsConfig = updateTsConfig;
|
@@ -1,6 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.libraryGenerator = libraryGenerator;
|
4
|
+
exports.libraryGeneratorInternal = libraryGeneratorInternal;
|
4
5
|
const tslib_1 = require("tslib");
|
5
6
|
const devkit_1 = require("@nx/devkit");
|
6
7
|
const eslint_1 = require("@nx/eslint");
|
@@ -30,7 +31,6 @@ async function libraryGenerator(tree, schema) {
|
|
30
31
|
...schema,
|
31
32
|
});
|
32
33
|
}
|
33
|
-
exports.libraryGenerator = libraryGenerator;
|
34
34
|
async function libraryGeneratorInternal(tree, schema) {
|
35
35
|
// Do some validation checks
|
36
36
|
if (!schema.routing && schema.lazy) {
|
@@ -93,7 +93,6 @@ async function libraryGeneratorInternal(tree, schema) {
|
|
93
93
|
(0, log_show_project_command_1.logShowProjectCommand)(libraryOptions.name);
|
94
94
|
};
|
95
95
|
}
|
96
|
-
exports.libraryGeneratorInternal = libraryGeneratorInternal;
|
97
96
|
async function addUnitTestRunner(host, options) {
|
98
97
|
if (options.unitTestRunner === 'jest') {
|
99
98
|
await (0, add_jest_1.addJest)(host, {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addFiles =
|
3
|
+
exports.addFiles = addFiles;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function addFiles(tree, options) {
|
6
6
|
const nameVariants = (0, devkit_1.names)(options.name);
|
@@ -13,4 +13,3 @@ function addFiles(tree, options) {
|
|
13
13
|
tree.delete((0, devkit_1.joinPathFragments)(options.entryPointDestination, `src/lib/${nameVariants.fileName}.module.ts`));
|
14
14
|
}
|
15
15
|
}
|
16
|
-
exports.addFiles = addFiles;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.addPathMapping =
|
3
|
+
exports.addPathMapping = addPathMapping;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const js_1 = require("@nx/js");
|
6
6
|
function addPathMapping(tree, options) {
|
@@ -13,4 +13,3 @@ function addPathMapping(tree, options) {
|
|
13
13
|
return json;
|
14
14
|
});
|
15
15
|
}
|
16
|
-
exports.addPathMapping = addPathMapping;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.normalizeOptions =
|
3
|
+
exports.normalizeOptions = normalizeOptions;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function normalizeOptions(tree, options) {
|
6
6
|
const name = (0, devkit_1.names)(options.name).fileName;
|
@@ -28,4 +28,3 @@ function normalizeOptions(tree, options) {
|
|
28
28
|
skipModule: options.skipModule ?? false,
|
29
29
|
};
|
30
30
|
}
|
31
|
-
exports.normalizeOptions = normalizeOptions;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.updateTsConfigIncludedFiles =
|
3
|
+
exports.updateTsConfigIncludedFiles = updateTsConfigIncludedFiles;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
function updateTsConfigIncludedFiles(tree, options) {
|
6
6
|
const candidateTsConfigPaths = [
|
@@ -23,4 +23,3 @@ function updateTsConfigIncludedFiles(tree, options) {
|
|
23
23
|
return json;
|
24
24
|
});
|
25
25
|
}
|
26
|
-
exports.updateTsConfigIncludedFiles = updateTsConfigIncludedFiles;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.librarySecondaryEntryPointGenerator =
|
3
|
+
exports.librarySecondaryEntryPointGenerator = librarySecondaryEntryPointGenerator;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
const lib_1 = require("./lib");
|
6
6
|
async function librarySecondaryEntryPointGenerator(tree, rawOptions) {
|
@@ -12,5 +12,4 @@ async function librarySecondaryEntryPointGenerator(tree, rawOptions) {
|
|
12
12
|
await (0, devkit_1.formatFiles)(tree);
|
13
13
|
}
|
14
14
|
}
|
15
|
-
exports.librarySecondaryEntryPointGenerator = librarySecondaryEntryPointGenerator;
|
16
15
|
exports.default = librarySecondaryEntryPointGenerator;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.updateModuleName =
|
3
|
+
exports.updateModuleName = updateModuleName;
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
5
5
|
/**
|
6
6
|
* Updates the Angular module name (including the spec file and index.ts)
|
@@ -81,7 +81,6 @@ function updateModuleName(tree, { oldProjectName, newProjectName }) {
|
|
81
81
|
});
|
82
82
|
}
|
83
83
|
}
|
84
|
-
exports.updateModuleName = updateModuleName;
|
85
84
|
function updateFileContent(tree, replacements, fileName, newFileName) {
|
86
85
|
let content = tree.read(fileName, 'utf-8');
|
87
86
|
if (content) {
|