Skip to content
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

Closed
wants to merge 8 commits into from

Conversation

matyunya
Copy link

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.

@matyunya matyunya changed the title Strict order New "strict order" option for preprocessor (recreated) Jan 18, 2020
...preprocessors.map(({ style }) => ({ style })),
];

await async_for_each(order, async p => {
Copy link
Member

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.

jiangfengming added a commit to jiangfengming/svelte-preprocess-html-asset that referenced this pull request Nov 5, 2020
@mcmxcdev mcmxcdev mentioned this pull request Feb 27, 2021
4 tasks
@happycollision
Copy link
Contributor

happycollision commented Feb 27, 2021

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.

@stale
Copy link

stale bot commented Sep 25, 2021

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.

@stale stale bot added the stale-bot label Sep 25, 2021
@stale
Copy link

stale bot commented Oct 20, 2021

This pull request has been closed as it was previously marked as stale and saw no subsequent activity.

@stale stale bot closed this Oct 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants