Currently, I am utilizing VSCode version 1.17.2 alongside TypeScript 2.5.2. Whenever I attempt to use a class in a .ts file that has not been imported yet, an error occurs and the class name is underlined, providing the option to use Quick Fix with bulb to import it. However, the generated import uses an absolute path (actually relative to the project root) to the file, for example:
import { FormattedValue } from 'src/app/entities/formattedValue';
This method works fine; however, when creating modules that are intended to be easily copied to different projects with varying folder structures, the paths need to be relative. Therefore, when I start using something like FormattedValue
in a file src/app/entities/xy.ts
, the resulting import should look more like this:
import { IFormattedValue } from './formattedValue';
Is there a way to configure VSCode to generate imports with relative paths rather than absolute paths when using Quick Fix?