Code Monkey home page Code Monkey logo

nim's Introduction


NiM Logo

Google Reviews

NiM (Node.js --inspector Manager)

Streamlines your development process
  • Google Chrome Web Store (works with any Chromium browsers: Google's Chrome, Microsoft's Edge, Opera, Vivaldi, Brave, Epic, and more... )

  • Microsoft Edge Addons (Works with the Microsoft's Edge browser https://www.microsoftedgeinsider.com/en-us/)

    PLEASE NOTE: Installing this does require the sharing of your email address with me (and only me). You are given other notice of this, but it's become and remains such an issue that I feel the need to make it OVER-abundantly clear. If you take issue with sharing your email address with me (mine is [email protected] by the way) please, I implore you to clone/fork a copy yourself and change what you don't like about the code and/or use alternate solutions (none of which are as good as NiM, but call me biased). Further feel free to contact me directly and have a chat. Unlike the behemoths like Facebook, Google, Amazon that you probably (and without hesitation) share your email address with, I actually care about the concerns of the actual people who choose to use the code I wrote (~99%) and am responsible for. Here is the privacy policy that goes along with NiM https://june07.com/privacypolicy. Thank you so much.

Blog Posts/Updates:

Now integrates with VSCode using NiMS VSCode Extension VSCode Integration

Easier than about::inspect (chrome://inspect/#devices)

NiM manages the Chrome DevTools window/tab lifecycle leaving you with more ability to focus on what matters... debugging your code. You no longer need to copy/paste DevTools URL's or continue opening/closing tabs/windows.

NiM automatically detects the URL that is generated when running node (locally or remotely) with --inspect option. NiM provides you with the option of automatically opening and closing Chrome DevTools in a tab or window. Just toggle the Manual/Auto setting and then start a debugging session. DevTools will open either on clicking the "Open DevTools" button or after the specified timeout period. If set to auto close, once you end your debugging session, The DevTools tab/window will close automatically.

  • Manage and monitor local and remote debugging sessions
  • Manual or automatic control of DevTools interface
  • Open DevTools in a new tab or window
  • Make DevTools focused or inactive on start
  • Customize duration between v8 Inspector probes
  • Autosave settings
  • Debug node processes launched by VSCode

Setup / Usage / How To

Simple and basic... just install the Chrome Extension in any of the following ways:

  1. Install via Chrome Web Store: https://bit.ly/2W8hQG9 (https://chrome.google.com/webstore/detail/gnhhdgbaldcilmgcpfddgdbkhjohddkj)
  2. Or, download .crx file directly from releases as shown here:

https://media.giphy.com/media/xT0xenBpYPF2F0j2fe/giphy.gif

Need Additional Information?

Note: At the time of writing, the v8 --inspect option is fairly new. See https://nodejs.org/api/debugger.html#debugger_v8_inspector_integration_for_node_js for additional details on the option.

If you enjoy using NIM please give us a 5 star rating and/or a G+1.

Any and all feedback is encouraged and welcome. Send us an email!

Digitalocean $100 Credit

nim's People

Contributors

aaliyahw avatar abcang avatar artofvs avatar dependabot[bot] avatar devbrent avatar ebramanti avatar fatkhanfauzi avatar gtarsia avatar haydnhkim avatar hpohlmeyer avatar jingsam avatar june07 avatar kubeeek avatar mrgekko avatar onionmk2 avatar soteck avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nim's Issues

Latest Chrome update gets NIM stuck in a loop

Chrome just auto updated to Version 65.0.3325.146 (Official Build) (64-bit)
and now I get this when NIM launches

nim-loop

But going directly to chrome://inspect works. Also looks like there is a new option in chrome://inspect to Open dedicated DevTools for Node

Hostname is really IP address

You prompt for a hostname, but the validation on the field only accepts an IP address or localhost. Is there a reason why you don't accept a hostname? I'm debugging a container which has a variable IP address, but always has the same hostname which I add to /etc/hosts. Hence the hostname always resolves to a local IP (198.x.x.x), and I'd imagine it would work for debugging. Chrome can happily accept the hostname in the chrome://inspect/#devices network targets configuration.

Request less permissions

I was rebuilding the Chrome profile and noticed that NiM was disabled because of new permissions:
image

Not sure why the browser didn't complain about it before. IMO if you really want to save users' email, you should make it optional and allow users to opt-out.

Another question is about the host permission *://*/*. Why the extension has to request it for all URLs?

Cannot open Developer Tools: "TYPEERROR: CANNOT READ PROPERTY '0' OF NULL"

Version 68.0.3440.106 (Official Build) Built on Ubuntu , running on Ubuntu 18.04 (64-bit)

Extension Version: 0.15.0

When I switch to Auto and press Enter, or switch to Manual and click "Open DevTools", I receive error TYPEERROR: CANNOT READ PROPERTY '0' OF NULL.

Host is localhost or 127.0.0.1, port is 9229.

Open inspector in Chrome Canary

The last Chrome Canary supports well the source-maps when inspecting Node, this is very useful for people using compilers like Babel.

Is it possible to configure the Chrome path that I want to use with NIM?

Thanks, NIM is awesome!

NiM inappropriately intercepts `cmd+i`

Environment

OS X 10.12.6 (16G29)
Chrome 60.0.3112.90 (Official Build) (64-bit)
NiM 0.13.8

What happened?

After installing NiM, I was working in Google Docs and attempted to use cmd+i to italicize some text but nothing happened. Disabling NiM, cmd+i worked again. Inspecting manifest.json, I noticed that cmd+i was registered as the open devtools keyboard shortcut when it should be cmd+option+i (View -> Developer -> Developer Tools ⌥⌘I).

What did you expect to happen?

I did not expect NiM to intercept keyboard shortcuts.


Thank you for NiM, for the reasons you outline in your blog post it's a real time saver. 🍻

Doesn't open tab

Inspector tab doesn't open automatically after upgrading Chrome to 66.0.3359.117 64-bit
If I switch to manual and click Open DevTools it says either "TYPEERROR: CANNOT READ PROPERTY '0' OF NULL" or "OPENING TAB IN PROGRESS..." and nothing happened.

Workaround: open chrome://inspect/#devices and click Inspect link

OS X: 10.13.4
Chrome: 66.0.3359.117
NiM: 0.14.5

FR: watch multiple ports

Dude, I love this extension, many thanks!

Small niggle, I have a couple of services running at the same time and I find that I often need to switch between them... would it be difficult to have NIM listen for multiple ports, and open devtools for each?

The deluxe version of this feature would be to have a user configured list of ports, each with a toggle and a manual button...

Food for thought... thanks again :)

Keeps stealing focus from other apps

I'm using nodemon and with every update to my node files the inspector grabs focus from my editor. I've got the "Make tab active" option disabled, which works when focus is already on Chrome. Would love if the option also prevented Chrome from grabbing focus while in my editor. Is this possible or native Chrome behaviour when refreshing a tab?
I'm using Mac OS 10.11.6 with Sublime 3 and Chrome 59 (beta channel). Love the plugin btw.

Problem to start the extension

problem remains also after uninstall and reinstall of the extension
Workaround: in chrome developer console goto Application, right click on local storage and clear.

Uncaught (in promise) TypeError: Cannot assign to read only property 'length' of object '#'
at SettingsStorage.setPreference [as _setCallback] (host.js:106)
at SettingsStorage.set (common.js:330)
at VersionController._migrateSettingsFromLocalStorage (common.js:429)
at VersionController._updateVersionFrom11To12 (common.js:396)
at VersionController.updateVersion (common.js:366)
at MainImpl._createSettings (main.js:37)
at MainImpl._gotPreferences (main.js:34)
at InspectorFrontendHostStub.getPreferences (host.js:105)
at MainImpl._loaded (main.js:32)

Does NIM adaptable to other application than Node

Hello
I'm currently integrating V8Inspector in my company application that already embeds V8.
I'm currently facing the issue your plugin NIM has already solved for Node : how to simplify the start of a debug session ?
Do you think it's possible to use NIM to automate the launching of CDT in my application?
Thanks and regards
Aligre

Not working in chrome 83

Today I update my chrome to 83. And now this extension is broken... After write node --inspect --inspect-brk - I get many, very many tabs in chrome... New tab is opening every half second until stop terminal. The same behavior in canary (version 85)

DevTools does not disconnect after update to version 2.4.0

From NiM user:

Since the latest update I have noticed issues with NiM. Particularly that the debugger has troubles disconnecting after wdio execution. I am using chromedriver 2.43, but I noticed the same issue trying with version 83.

Optionally disable G+ elements

NIM is currently unsuable in China without a complex proxy setup. It is probably also unusable on airplanes, or other times when the user has no Internet access.

Observed behavior: Click the NIM button. The animation that the button is clicked plays. Nothing else happens.

Expected behavior: Clicking the NIM button should bring up the NIM window.

I can open the option dialog, and I can open the NIM dialog when using a proxy, but when I use a proxy I can't access my local node inspector ports.

Proposed solution: Either set a manual timeout for fetching the G+ resources (maybe 0.2s) and continue operations if they haven't been loaded, or allow us to disable the G+ button in the options menu.

We (devs in China) already use a proxy for downloading and installing the extension, but when we are debugging our local apps we don't want Chromium to be running a proxy, because that changes 'localhost" to be our proxy endpoint. The usual workaround to this is to use a PAC file to specifically whitelist localhost, but this does not work in all versions of Chromium on all OSes. For example, I get the following when I try to open the networking dialog:

When running Chromium under a supported desktop environment, the
system proxy settings will be used. However, either your system is not
supported or there was a problem launching your system configuration.

But you can still configure via the command line. Please see man
chromium-browser for more information on flags and environment
variables.

I can start Chromium with --proxy-server=socks5://localhost:1080 to use a SOCKS proxy, but for this I do not get any opportunity to configure black/whitelists, and I can't configure a global system proxy (for reasons I don't want to get into.)

Runaway tab/window opening when devtools url is blank.

Caught this today when for some reason the custom devtools option was missing. Need to implement a failsafe such that if too many tabs/windows are opened in succession of each other, further openings are disabled until a user intervenes. In this case, it required selecting a valid devtools url or disabling the option. Better validation could be written to ensure a correct devtools address, but I think it would be too much to make it exhaustive and it might continually change. Thus this would be the best course of action for a fix.

Why does NiM need an active internet connection in order to operate?

It turns out NiM doesn't work without an active internet connection because it tries to connect to http://chrome-devtools-frontend.june07.com/.

Why does NiM need that while chrome://inspect/#devices perfectly works without it?

More importantly, how can we configure NiM to work without an internet connection?

503 error after installing

When installing NiM in a new Chrome Canary profile, http://june07.com/blog/nim-install opens in a new tab served by Heroku with a 503 "Application Error". The NiM icon still appears in my toolbar and the popup still displays properly, so I'm guessing it's just a server issue in your post installation site.

Setting to have inspector window maximized

Currently the inspector window opens with rather awkward dimensions on my laptop. The chrome.windows API allows setting the window to maximized (https://developers.chrome.com/extensions/windows#method-create) which would be great for my small laptop screen. Any chance you could add this?

Being able to set the width and height if not maximized would be perfection :)

This is a super helpful extension btw, thanks.

How do you control auto close?

Thanks for this tool -- very handy.

How do you control the auto-close feature? I assume that enabling this option will kill any instances of node --inspect. Correct? I'm hoping that it will deal with the "Unable to open devtools socket: address already in use" that I get from time to time.

Does it auto-close simply by closing the tab that NIM is running in?

Chrome tab not closing properly when using Nodemon

I have an issue where restarting my server through Nodemon does not close the tab, but instead renders this error message:

screenshot 2016-12-17 21 19 28

After looking through the source code I think I've isolated the problem to here. The catch for the HTTP request does not consider a valid case where the debug server is not down, but the ID of the debugger websocket changes.

A proposed solution would be to store the unique identifier for each devtools session, and check if that identifier is in the returned JSON from the localhost debug server. Requests coulda also be minimized by making the request only once and filtering $scope.devToolsSessions according to the returned identifiers.

I'd be willing to PR this in the next couple days with your OK @june07

Edit: Initial conversation about this issue can be found here.

Latest Chrome update V76 stopped extension opening up new tab / finding local host

I have noticed that since the latest update of Chrome V76 the extension is not opening up a new tab automatically for the devtools and looks like it's not picking up the WS as per the screenshot?
image
The work around I have had to do is start the debugger and then open up chrome://inspect then click on the inspect link to open the devtools for that WS.
image

Sourcemaps aren't rectified

When using the plug-in, sourcemaps for babel aren't been mapped to the source. This is similar in symptom to NodeJS issue #8369 -- however, when I access the dev tools using chrome://inspect the issue is not seen.

Love this plug-in and would be happy to help however is needed-- I can perform more info as needed and would be willing to take a crack at opening a PR if I could get some direction.

Thanks.

Are Chrome apps deprecated?

I swear I read somewhere that Chrome apps are deprecated and that Google Chrome will no longer host them. Is that for real?

I want to develop a Chrome App, and I wanted to borrow this codebase as a starting point for my app.

Btw, I use NiM regularly, thanks for your work.

NiM should not bind Command+I by default

Command+I is a common keyboard shortcut for italicizing text (including in Google Docs) or getting information in web applications. It would be great if NiM would leave this keyboard shortcut alone so it can be used in Chrome, or at least give the option to disable or change it.

image

Getting error WebSocket disconnected

Hi,

I'm getting an error on startup; this is what I'm doing.

I configure the host to be "auto" in NiM:
image

I create a simple main.js file, and then I run it using node --inspect-brk main.js. NiM detects the URL and opens, but I get the following error:
image

OS & Versions:
OS: Manjaro Linux
Node: v14.4.0
NiM: 2.4.2 (as seen by the first screenshot)

Thank you

Make keyboard short cut (cmd-I) configurable (or different?)

This might sound silly but it'd be great to make the keyboard shortcut to show the inspector configurable. Currently cmd-i interferes with at anywhere in chrome one might use italics (gmail, google docs, the github markdown editor for that matter). Either that or set it to a different default.

I suppose I could just fork this and make my own plugin with a different keyboard command but that seems like overkill!

Opening Tab in Progress

Environment

  • NiM 1.3.0
  • Chrome Version 70.0.3538.77 (Official Build) (64-bit)

Repro:

  1. click on NiM icon.
  2. click on Open DevTools

Result: a little popup in red text that says: OPENING TAB IN PROGRESS...
Tried with options set to tab or window.

Maybe related to #47?

Workaround

restart chrome 😞

Reason for new permissions

Thanks for your work on this extension. It's made things a lot easier.

Could you explain why the permission requirements of the extension have changed recently? The latest change will reveal the user's email address. It would be a good idea to explain why each permission is necessary on the extension's description page.

extension not saves auto/handle tumbler and not saves inspector-settings

NiM extension is beautiful, but after a year of rest, I launched it again on a new project and discovered two problems.

  • extension not saves auto/handler tubler (my tumbler even a little buggy and glitch, i can record gif, seem to be low-fps gpu)
  • chrome inspector not saves console options

MacOs 10.14.6 Mojave, Chrome 80.0.3987.132

Снимок экрана 2020-03-10 в 11 29 57
Снимок экрана 2020-03-10 в 11 25 43

Inspecting Jest breaks opening devtools

When using Jest's recommended inspection command (node --inspect-brk node_modules/.bin/jest -i), automatic mode does not open devtools and manual mode causes an error.

Steps

Automatic

  • Use automatic mode
  • Run command
  • DevTools are not opened

Manual

  • Use manual mode
  • Run command
  • Click Open DevTools
  • Error is displayed: TYPEERROR: CANNOT READ PROPERTY '0' OF NULL

Environment

  • NiM 0.13.9
  • Chrome Dev 63.0.3230.0
  • Jest 21.2.1
  • Node 8.6.0

NiM Icon in Chrome Menu disappears when clicked

When I click on the NiM Icon in the chrome menu/toolbar (at the top of the browser window), the NiM Icon simply disappears from the menu bar. I then need to open Chrome Settings (right top corner) -> More Tools -> Extensions and it says that NiM Extensions may have been corrupted. I can then click on the "Repair" Button below the error message and the NiM icon will show up in the chrome menu bar again.

This is pretty frustrating because I cannot open the "main menu" of NiM. However, right-clicking on the NiM Icon works -> I can right-click the icon and from the context menu, choose "Option" to open NiM's option menu.

image
image

I am using Chrome Version 72.0.3626.81 (Official Build) (64-bit) on an Ubuntu 16.04 machine.
The NiM Version is 2.0.0.

Auto-open setting is not remembered on chrome restart

I leave NIM enabled in the Chrome Extensions settings, and NIM set to 'manual'.

I find that whenever I restart my computer and load up my work project (has a couple of node --inspect tasks) the devtools window opens up, and I set NIM to 'manual' again, then shut devtools until I need it some other day...

No biggie, just an FYI - thanks!

Network tab

There are no requests logging in the network tab. How do I fix this?
In my app I use node-request.

Support question - how to replicate project

I have forked this repo, going to re-purpose the codebase for an entirely different app.

  1. I see this in manifest.json:
  "manifest_version": 2,
  "name": "__MSG_appName__",
  "short_name": "__MSG_appShortName__",

my question is - I looked through the whole codebase - I don't see how "MSG_appName" gets populated.

  1. How do you generate your build/*.zip files? Is it manual? is there some build script you have?

Extension crashes on clicking on the extension icon

Thanks a lot for such useful tool!

Unfortunately at some point the extension started crashing on my machine when i click on it (Ubuntu 16.04, Chrome 59). Maybe you have any idea where is the source of this issue?

"Open DevTools" button just shows "[object object]"

Hi,

Maybe I'm doing something wrong, idk. I use es6 (babel), so my npm script is nodemon --inspect src/Application.js --exec babel-node. It does work, but I have the issue of the ws changing url always, so I installed NiM.

Unfortunately, leaving on auto does nothing. Leaving on manual and clicking on Open DevTools gives me the following:
screen shot 2018-07-12 at 8 26 45 pm

I'm getting the following when pressing Open DevTools:
screen shot 2018-07-12 at 8 24 44 pm

I'm currently using Canary v69
Any ideas?
Thank you!

Cordova support?

Good morning,

great tool! Is it possible to add Cordova support?

The problem is similar: launching in example "$ cordova run android --device" causes the Inspector to disconnect, so you have to close it and click on "inspect" again.

In the screenshot you can see both Node and Cordova in action :)

Thanks a lot.

schermata 2017-09-08 alle 16 51 26

Any way to avoid the window re-opening

Hello! huge huge huge thank you for NIM - it's just what we need to make node debugging have a smooth workflow.

I was wondering if it's at all possible to just change the page to the new inspector window.

The problem I'm having is that when I save a file, I have nodemon restart my process.

Once it restarts, the window closes and a new one opens up. I love if I could just keep my window open at all times and have it refresh itself and move itself to the new window.

Let me know -thanks again!

NIM tab is reloaded every seconds.

NIM used to work like a charm.
But, it suddenly stopped working and NIM tab is reloaded every seconds, if I enable Auto mode.
There is no issue on manual mode.
I can just suspect it as an issue on 0.12.3.

Thank you.

Uses a lot of CPU

When NiM is in auto mode, I can often see it take up 15% of CPU in the Chrome task manager. Can this not be lessened?

Even when I switch to manual mode, the extension takes up 0.1% CPU even though it shouldn't be doing anything…

(BTW, great extension! 👍 🙇)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.