Show HN: A very simple http “proxy” on runkit
runkit.io
runkit.io
For those interested, the code is here: https://runkit.com/dosyago-coder-0/proxy
It does the simplest possible:
- prepends the URL form to the proxied html page
- prepends a <base> element with the proxied page's uri ( to ensure relative links point to the source and not the proxy )
- prepends a script which captures clicks on anchor links and instead of allowing the navigation to proceed submits the URL ( via the prepended form ) back to the endpoint
Also, for the sake of a technical challenge, I don't know how to get it to work on Amazon.com -- what happens is after the first load, any links clicked seem to break out of the proxy. Anyone who can work out why it doesn't work, please tell me!
edit: oops, seems as if the HN 'glance' of death ( not hug, this has only been on for 20 minutes ) kills it intermittently, and that runkit has a quota that is sometimes exceeded!