We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ef03084 commit 399f782Copy full SHA for 399f782
1 file changed
src/ng_package/rollup/rollup.config.js
@@ -195,6 +195,8 @@ if (dtsMode) {
195
);
196
}
197
198
+const outExtension = dtsMode ? 'd.ts' : 'mjs';
199
+
200
/** @type {import('rollup').RollupOptions} */
201
const config = {
202
input,
@@ -215,8 +217,9 @@ const config = {
215
217
minifyInternalExports: false,
216
218
sourcemap: !dtsMode,
219
banner: bannerContent,
- entryFileNames: '[name].' + (dtsMode ? 'd.ts' : 'mjs'),
- chunkFileNames: '[name].' + (dtsMode ? 'ts' : 'mjs'),
220
+ entryFileNames: '[name].' + outExtension,
221
+ // Hashing is needed as otherwise rollup will emit files with `.d.d.ts` in some cases.
222
+ chunkFileNames: '[name]-[hash].' + outExtension,
223
},
224
};
225
0 commit comments