diff --git a/docs/generated/packages/rollup/executors/rollup.json b/docs/generated/packages/rollup/executors/rollup.json index f9c10f29d3087..fe3e6c1eb8f01 100644 --- a/docs/generated/packages/rollup/executors/rollup.json +++ b/docs/generated/packages/rollup/executors/rollup.json @@ -159,6 +159,11 @@ "type": "boolean", "description": "Generate package.json with 'exports' field. This field defines entry points in the package and is used by Node and the TypeScript compiler.", "default": false + }, + "skipTypeCheck": { + "type": "boolean", + "description": "Whether to skip TypeScript type checking.", + "default": false } }, "required": ["tsConfig", "main", "outputPath"], diff --git a/packages/rollup/src/executors/rollup/lib/normalize.ts b/packages/rollup/src/executors/rollup/lib/normalize.ts index 567dabade76f8..aa1662e242980 100644 --- a/packages/rollup/src/executors/rollup/lib/normalize.ts +++ b/packages/rollup/src/executors/rollup/lib/normalize.ts @@ -44,6 +44,7 @@ export function normalizeRollupExecutorOptions( project, projectRoot, outputPath, + skipTypeCheck: options.skipTypeCheck || false, }; } diff --git a/packages/rollup/src/executors/rollup/rollup.impl.ts b/packages/rollup/src/executors/rollup/rollup.impl.ts index ea583abcd9860..423115122e35a 100644 --- a/packages/rollup/src/executors/rollup/rollup.impl.ts +++ b/packages/rollup/src/executors/rollup/rollup.impl.ts @@ -214,7 +214,7 @@ export function createRollupOptions( json(), (useTsc || useBabel) && require('rollup-plugin-typescript2')({ - check: true, + check: !options.skipTypeCheck, tsconfig: options.tsConfig, tsconfigOverride: { compilerOptions: createTsCompilerOptions( diff --git a/packages/rollup/src/executors/rollup/schema.d.ts b/packages/rollup/src/executors/rollup/schema.d.ts index f5034297affdc..bcc5d69a6ad6c 100644 --- a/packages/rollup/src/executors/rollup/schema.d.ts +++ b/packages/rollup/src/executors/rollup/schema.d.ts @@ -31,4 +31,5 @@ export interface RollupExecutorOptions { compiler?: 'babel' | 'tsc' | 'swc'; javascriptEnabled?: boolean; generateExportsField?: boolean; + skipTypeCheck?: boolean; } diff --git a/packages/rollup/src/executors/rollup/schema.json b/packages/rollup/src/executors/rollup/schema.json index b4faad2986b4e..0f96ce96938bc 100644 --- a/packages/rollup/src/executors/rollup/schema.json +++ b/packages/rollup/src/executors/rollup/schema.json @@ -146,6 +146,11 @@ "type": "boolean", "description": "Generate package.json with 'exports' field. This field defines entry points in the package and is used by Node and the TypeScript compiler.", "default": false + }, + "skipTypeCheck": { + "type": "boolean", + "description": "Whether to skip TypeScript type checking.", + "default": false } }, "required": ["tsConfig", "main", "outputPath"],