Golo Roden Golo Roden - 1 year ago 131
Javascript Question

How to redirect to the chrome-devtools:// protocol?

I have written a Node.js application that you can (of course) debug using the Chrome Debugging Protocol, if you use one of the latest Node.js versions:

$ node --inspect app.js

This prints a url (
) to the terminal. If I copy this url and paste it in Chrome, the debugger opens and everything is fine.

Now, this url is pretty long, and I wanted it to become shorter. So my idea was to run a very simple Node.js server that simply redirects an incoming
request to this url. Using some tests, I ensured that the correct headers and status code and so on are sent.

But - it does not work. If I call my redirect service, I only get the answer that the server sent an empty response. No redirection is taking place.

What am I missing?

How to redirect to chrome://extensions may give a hint that this is not possible at all, but I wonder what other options I may have (except of course, just live with the long urls)?

Answer Source

You can't redirect to an internal Chrome URL. It's not possible.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download