Repository navigation
Replies: 1 comment
|
The directory entries in the screenshots are not equivalent between the two For the plugin configuration, use patterns that include the directory contents: typescript({
tsconfig: './tsconfig.json',
exclude: [
'src/Pages/**',
'src/test/**',
'src/App.tsx',
'src/main.tsx',
'**/*.spec.ts',
'**/*.test.ts',
'**/*.spec.tsx',
'**/*.test.tsx'
],
compilerOptions: {
jsx: 'react-jsx',
declaration: true,
declarationDir: 'build'
}
})I reproduced the distinction with
All three builds completed without warnings. This isolates the pattern difference; it is not a run of your complete React project. The 8.3.4 plugin options document Also check an empty output directory when comparing results: a subsequent build that stops emitting a declaration does not necessarily remove a stale file from an earlier build. And exclusion is not an import boundary—if the library entry imports an application/test module, that dependency needs addressing separately rather than relying on |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi, I have a question!
If I configure "exclude" options in
tsconfig.jsondoesn't generated types of files from folder excludes, but if I configure "exclude" options inrollup.config.jsis generated only types of files from folder excludes, why is this happen?Correctly

Wrong

Versions in my project:
"@rollup/plugin-typescript": "^8.3.4","rollup": "^2.77.2",My Script for build:
"build": "npx rollup --config rollup.config.js",All reactions