Skip to content

Latest commit

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

A web proxy for rewriting web responses on the fly. Based on node-unblocker.

Example

Inject a javascript tag at the end of the page.

varniScriptTag=['<script type="text/javascript">',"(function(i,s,o,g,r,a,m){i['NirrorObject']=r;i[r]=i[r]||function(){","(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();i[r].scriptURL=g;a=s.createElement(o),","m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)","})(window,document,'script','https://static.nirror.com/client/nirrorclient.js','Ni');",'</script>'].join("\n");require("web-proxy")({processChunk: function(html){returnhtml.replace("</body>",niScriptTag+"\n</body>");}});

License

This project is released under the terms of the GNU GPL version 3

About

Web proxy for rewriting http responses on the fly

Resources

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages