As of VSCode 1.17, typing import x from './ offers autocomplete suggestions of local files and directories. However, the list of file extensions that are recognised is somewhat arbitrary — .js files are recognised, as are .ts and .jsx, but .json isn't (despite the fact that the Node handles .json files natively).
Meanwhile, when building web applications with bundlers like Webpack and Rollup, it's common to import files with extensions like .css, .html, .vue, .tsv and so on.
Is there some way to customise the list of extensions that are recognised? An alternative approach could be to recognise all file extensions rather than attempting to filter them.
Copied from original issue: Microsoft/vscode#35731
From @Rich-Harris on October 6, 2017 15:7
As of VSCode 1.17, typing
import x from './
offers autocomplete suggestions of local files and directories. However, the list of file extensions that are recognised is somewhat arbitrary — .js files are recognised, as are .ts and .jsx, but .json isn't (despite the fact that the Node handles .json files natively).Meanwhile, when building web applications with bundlers like Webpack and Rollup, it's common to import files with extensions like .css, .html, .vue, .tsv and so on.
Is there some way to customise the list of extensions that are recognised? An alternative approach could be to recognise all file extensions rather than attempting to filter them.
Copied from original issue: Microsoft/vscode#35731