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
While trying to set up a new TypeScript project to use rollup-plugin-styles, I ran into difficulty getting my project to build. While I did have rollup-plugin-styles configured to emit d.ts files, they wouldn't flush to disk until after a successful build, which is obviously impossible when those files are required to complete the build. I worked out a solution that seems simple and direct enough: First execute a different build to emit only the d.ts files. (A separate command also means you can refresh your .css.d.ts files without doing a full build.) That said, finding the right plugins and configuration to achieve that in a clean way took quite a bit of experimentation, and it feels like a very shallow pit of success for what I think would be a rather common workflow. Did I missing something obvious, or is this a use case that could benefit from additional support?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
While trying to set up a new TypeScript project to use rollup-plugin-styles, I ran into difficulty getting my project to build. While I did have rollup-plugin-styles configured to emit d.ts files, they wouldn't flush to disk until after a successful build, which is obviously impossible when those files are required to complete the build. I worked out a solution that seems simple and direct enough: First execute a different build to emit only the d.ts files. (A separate command also means you can refresh your .css.d.ts files without doing a full build.) That said, finding the right plugins and configuration to achieve that in a clean way took quite a bit of experimentation, and it feels like a very shallow pit of success for what I think would be a rather common workflow. Did I missing something obvious, or is this a use case that could benefit from additional support?
I set up a repo with my setup for reference: https://github.com/WCWedin/rollup-plugin-styles-test
Beta Was this translation helpful? Give feedback.
All reactions