Hacker News new | ask | show | jobs
by AussieWog93 17 days ago
The difference is that I expect "npm install" to execute code, where I do not expect merely opening a repo to look at the files in Cursor to execute anything.
1 comments

IDEs do syntax highlighting, typechecking, linting, automatic git refreshes. All of this happens in the background without you executing any code. If you open a Typescript project in VS Code and it automatically shows you a list of errors where do you think it got them from? It ran the tsc executable in your node_modules folder.
> syntax highlighting, typechecking, linting, automatic git refreshes

In most languages, none of those things involve execution of code in the repo. In languages that do - for example Elixir - it prompts you to trust them first.

Visual Studio Code asks you if you trust the files in the folder you open, or at least it always has done for me. Presumably this stuff stops working if you don't?
I'm a Python dev so don't do much typescript, this sounds crazy too!