Remove runtime dependencies
charphi opened this issue · comments
This library is very light but is linked to 2 big dependencies at runtime.
It would be nice to have a standalone library instead.
To do so:
- Html escape could be coded directly.
- compressJs could be made optional.
Yes, I agree.
I was looking into a simple js-minifier I could copy-paste, but I didn't find any. Inline HTML/CSS are probably not used by a lot of people, so maybe I should just remove them.
HTML escape used to be coded directly (trivial implementation from SO), but there were some issues. Do you know of a decent and light-weight solution?
PR #36 makes use of js-minifier optional.
For html escape, I don't have a light-weight solution currently.
Okay. I've merged your PR. We could make stringutils optional too, with a fallback to a trivial implementation for those who need that.
Closure is now completely removed, looking for a html-escaper.
I just wrote a simple one. According to owasp you don't need to do much.