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

Support useref like blocks #41

Open
gunzip opened this issue Nov 19, 2015 · 2 comments
Open

Support useref like blocks #41

gunzip opened this issue Nov 19, 2015 · 2 comments

Comments

@gunzip
Copy link

gunzip commented Nov 19, 2015

To support parsing useref blocks ie.

<!-- build:css combined/style.css -->

regex could become:

var regex = /(\n?)([ \t]*)(<!--\s*build:(\w+(?:-\w+)*)\s+[^-]*\s*-->)\n?([\s\S]*?)\n?(<!--\s*endbuild\s*-->)\n?/ig;

I need html replacement to work aside useref.

@VFK
Copy link
Owner

VFK commented Nov 21, 2015

@gunzip
I'm not sure about this one. The whole point of this plugin is not to work like useref and instead provide what i think is a better way of achieving this task. Plus what's the point in recreating some other library? If you need this particular syntax then why don't just use useref? Or if the syntax doesn't matter then why don't change it so gulp-html-replace can work with it? What's your use case?

@gunzip
Copy link
Author

gunzip commented Nov 21, 2015

My use case consist in

  • collecting assets list through useref
  • use gulp-rev generate a manifest
  • use gulp-html-replace to do some custom replacement using the generated manifest

if i could collect assets through gulp-html-replace this is not needed indeed.
If you think i't's an edge case feel free to close the issue anyway =)

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