You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I got a type error when using lodash. If you change it to typeof, it works.
Checklist
I can reproduce this issue when running this plugin on its own. Other plugins, such as node-resolve are known to cause issues.
I am running this plugin on .d.ts files generated by TypeScript. The plugin can consume .ts and even .js files (with allowJs: true), but this is known to cause issues.
This issue is not related to rolling up @types. The plugin ignores these by default, unless respectExternal is set. @types can contain hand-crafted code which is known to cause issues.
src/index.ts(15,17): error TS2349: This expression is not callable.
Not all constituents of type 'true | ScrollToOptions | (() => boolean | ScrollToOptions)' are callable.
Type 'true' has no call signatures.
src/index.ts(23,5): error TS2322: Type 'true | ScrollToOptions | (() => boolean | ScrollToOptions)' is not assignable to type 'ScrollToOptions'.
Type 'true' has no properties in common with type 'ScrollToOptions'.
[!] (plugin dts) RollupError: [plugin dts] src/index.ts: Failed to compile. Check the logs above.
src/index.ts
at getRollupError (D:\Projects\swiper-extra-modules\node_modules\.pnpm\rollup@4.14.1\node_modules\rollup\dist\shared\parseAst.js:282:41)
at Object.error (D:\Projects\swiper-extra-modules\node_modules\.pnpm\rollup@4.14.1\node_modules\rollup\dist\shared\parseAst.js:278:42)
at Object.error (D:\Projects\swiper-extra-modules\node_modules\.pnpm\rollup@4.14.1\node_modules\rollup\dist\shared\rollup.js:804:32)
at Object.error (D:\Projects\swiper-extra-modules\node_modules\.pnpm\rollup@4.14.1\node_modules\rollup\dist\shared\rollup.js:19612:42)
at generateDtsFromTs (file:///D:/Projects/swiper-extra-modules/node_modules/.pnpm/rollup-plugin-dts@6.1.0_rollup@4.14.1_typescript@5.4.4/node_modules/rollup-plugin-dts/dist/rollup-plugin-dts.mjs:1833:30)
at Object.transform (file:///D:/Projects/swiper-extra-modules/node_modules/.pnpm/rollup-plugin-dts@6.1.0_rollup@4.14.1_typescript@5.4.4/node_modules/rollup-plugin-dts/dist/rollup-plugin-dts.mjs:1842:38)
at D:\Projects\swiper-extra-modules\node_modules\.pnpm\rollup@4.14.1\node_modules\rollup\dist\shared\rollup.js:989:40
The text was updated successfully, but these errors were encountered:
I got a type error when using lodash. If you change it to typeof, it works.
Checklist
Other plugins, such as
node-resolve
are known to cause issues..d.ts
files generated by TypeScript.The plugin can consume
.ts
and even.js
files (withallowJs: true
), but this is known to cause issues.@types
.The plugin ignores these by default, unless
respectExternal
is set.@types
can contain hand-crafted code which is known to cause issues.Code Snipped
Error Message
The text was updated successfully, but these errors were encountered: