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

Conditional spriting based on image url #10

Open
linxiaowu66 opened this issue Feb 14, 2017 · 3 comments
Open

Conditional spriting based on image url #10

linxiaowu66 opened this issue Feb 14, 2017 · 3 comments

Comments

@linxiaowu66
Copy link

linxiaowu66 commented Feb 14, 2017

Add an option to conditionally filter images based on the image URL

For example, any image with ?__spriter will be sprited

background-image: url('./images/test.png?__spriter');
@MadLittleMods MadLittleMods changed the title Can you add the interface to specific format image to generate spriter ? Conditional spriting based on image url Feb 15, 2017
@MadLittleMods
Copy link
Owner

Just in case you weren't aware and for people who stumble onto this issue. You can already conditionally render images with comments with some meta info in them, see https://github.com/MadLittleMods/gulp-css-spriter#meta-info

@MadLittleMods
Copy link
Owner

@xing-zhi We should make this a more general option for a matching function or regex, options.filter(uri, filePath)

#11

@linxiaowu66
Copy link
Author

@MadLittleMods Thanks a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants