nativescript-community / nativescript-vscode-extension

A Visual Studio Code Extension for NativeScript
https://www.nativescript.org/visual-studio-code
Apache License 2.0
82 stars 32 forks source link

fix: debug-brk does not work with webpack #245

Closed rosen-vladimirov closed 5 years ago

rosen-vladimirov commented 5 years ago

In case you are using --bundle/--hmr with --debug-brk, application should break in starter.js. However, an error is shown. There are several problems - first of app the projectName is calculated incorrectly for iOS, so the path to platforms/ios/<project name> is incorrect. Also, as we are modifying the relativePath string multiple times, it contains the dir from nsconfig.json instead of app, but in platforms dir, where starter.js is located, there's only app dir (i.e. no src there). Refactor the code, so we'll check the location of the file correctly. Add unit tests for iOS as well.