-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New "strict order" option for preprocessor (recreated) #4282
Conversation
src/compiler/preprocess/index.ts
Outdated
...preprocessors.map(({ style }) => ({ style })), | ||
]; | ||
|
||
await async_for_each(order, async p => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's no need for an async_for_each
abstraction here. It's exactly the same as before. Please revert this to a for-of
with order
.
As usual, someone already tackled this issue and I just didn't know what to search for! (And it's @matyunya, of course, because we are both trying to get a workable flow for Svelte Image in particular 😉). For anyone looking at this solution, you might also be interested in the way I've also solved the problem in #6031. Seems like it allows a bit more flexibility (and preserves some possibly necessary behaviors for some processors?), as you aren't opting in to a different processing order, but rather grouping processors instead, preserving the original "markup, then scripts, then styles" model in all cases. |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This pull request has been closed as it was previously marked as stale and saw no subsequent activity. |
I recreated my PR after messing up my fork's master. (previous PR: #4222)
Original discussion: sveltejs/rollup-plugin-svelte#86 (comment).
Issue: #4141
New option allows users to specify strict order in which preprocessors must be applied, specifically for the case when Sass preprocessor must run before Svelte image to work properly.