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

Deminify js code in <script> tags. #2

Open
nandod opened this issue Nov 17, 2011 · 5 comments
Open

Deminify js code in <script> tags. #2

nandod opened this issue Nov 17, 2011 · 5 comments

Comments

@nandod
Copy link

nandod commented Nov 17, 2011

Hello,
it would be nice if jsdeminifier could deminify js code in < script > tags inside text/html responses. I tried to add text/html to the list of supported mime types but it tries to deminify everything thus breaking the HTML.

@benmmurphy
Copy link
Owner

This is a nice idea but it is quite tricky do do :(

@nandod
Copy link
Author

nandod commented Nov 23, 2011

I guess so. :-( It would need to parse the stream and only pass what's between <script> and </script> to the beautifier. Or an alternate beautifier that doesn't mangle HTML code, which I am not aware of.

@nandod
Copy link
Author

nandod commented Nov 23, 2011

Between < script > and </ script > I meant.

@benmmurphy
Copy link
Owner

this is true. sounds a bit easier than I thought it would be. i'll start work on it after i have closed off #3

@caesarsol
Copy link

hello, any news on this feature? :)
if I paste HTML code on jsbeautify.com it can manage the HTML, maybe you could update the algorithm?
then it would be enough to insert text/html in the extensions.jsdeminifier.contenttypes config, to pass all the HTML to the deminifier!
thanks!

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

3 participants