Debugging Meteor app with NTVS (Node Tools for Visual Studio)
Asked Answered
F

2

7

I'm investigating using NTVS (https://nodejstools.codeplex.com/) with Visual Studio 2013 to debug my Meteor/Node application. I can't figure out how to get debugging to work.

The problem is that when Meteor starts it copies all of my sources to the .local directory and runs them in a new instance of Node.exe. This confuses NTVS because it can't follow on into the child process. And I can't set breakpoints because Visual Studio doesn't know how to deal with the fact that the files I am editing being different than the ones that are running in the .local directory.

What I'd like is some way to run my Meteor based code under Node.exe straight from my sources, without the pre-bundling steps. Is this possible?

I'm fine with not having development niceties like hot-code pushing and package updates on-the-fly. I can manage that in other ways.

'meteor bundle' doesn't do the trick because (a) it takes too long and (b) it still makes the copy that throws off breakpoints.

Hopefully there is a way to use Meteor as an awesome library separate from Meteor as a runtime environment so I can debug it with NTVS.

Thanks,

/Michael Ost

Fidelis answered 18/9, 2014 at 1:58 Comment(1)
Hi Michael, have you tried the latest packages?Stimson
A
0

if the functionality of the meteor tools for Visual Studio are not sufficient, why not contribute to the project.

It's a bit old (last commit 18 months ago) and hence probably outdated, but it will give you a head start as to how to make things work.

Autostability answered 17/7, 2015 at 7:47 Comment(0)
A
0

You can run your app in debug mode using meteor debug and then attach debugger to port number 5858, It should work for all type of node.js debuggers e.g. Visual Studio, Visual code, Webstorm etc because they all have "attach" debugger option next to "debug" option.

Apicella answered 7/5, 2016 at 17:48 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.