Is it possible to run a newly created JavaScript file in a local workspace in the chrome developer tools console?
The workflow I'm trying to achieve is the one shown in this image:
I want to be able to create a new file in my workspace, run (or require or whatever) the file and be able to use it's functions and variables in the chrome developer console.
If I'm correct, this means running the script within the context of the webpage and adding the methods and variables to the window object?
Is their a way this can be done?
I could not find an automatic way to add a local file into the DOM context. The best solution I found so far:
Well, this is not much better than copy&paste but spares a few key presses/mouse clicks.
You can create a plain html file like this with your javascript file in the script tag.
Then you should be able to get all your methods in the developer console.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With