In cursor, when using the quick fix import option. I’m presented with relative imports rather than subpath imports. This is a feature since Typescript 5.4. I’m using 5.9 currently. The same configuration works in VS code but does not in cursor.
Steps to Reproduce
Create an application with a package.json
In that package.json setup subpath imports
Create and export a module
Create and export another module
Attempt to use and import the first module
You’ll see a relative import
Expected Behavior
I should see the subpath import options rather than the relative imoprts
Screenshots / Screen Recordings
Cursor
VSCode
Operating System
MacOS
Current Cursor Version (Menu → About Cursor → Copy)
I’ve restarted the TS server and that didn’t fix it.
Nothing in my workspace settings.json in vscode. The user settings.json is synced between vscode and cursor. I tried removing everything from that and restarting the ts server, and even reloading the window and still not working
What specific tsconfig settings are you referring to? the compilerOpitons.path should be removed in favor of the subpath imports.
FWIW the tab completion recognizes it. Though that may be from me correcting it a bunch. E.g. it auto imports the relative path and then that Press tab to go here prompt shows up and the tab completion has the correct subpath import syntax