diff --git a/.eslintrc.js b/.eslintrc.js index 03e06eb499..86ec12b0d0 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -88,15 +88,23 @@ module.exports = { react: { version: 'detect' }, - 'import/extensions': [ - '.js', - '.ts', - '.jsx', - '.tsx' - ], 'import/parsers': { '@typescript-eslint/parser': [ '.ts', '.tsx' ] }, + 'import/resolver': { + node: { + extensions: [ + '.js', + '.ts', + '.jsx', + '.tsx' + ], + moduleDirectory: [ + 'node_modules', + 'src' + ] + } + }, polyfills: [ // Native Promises Only 'Promise', diff --git a/tsconfig.json b/tsconfig.json index a67dd148ed..d3541c6df1 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,5 +1,6 @@ { "compilerOptions": { + "baseUrl": "src", "target": "ES5", "lib": ["DOM", "DOM.Iterable", "ES2015"], "allowJs": true, diff --git a/webpack.common.js b/webpack.common.js index 57d3cc6fdc..7d08ca06c3 100644 --- a/webpack.common.js +++ b/webpack.common.js @@ -31,6 +31,7 @@ const config = { resolve: { extensions: ['.tsx', '.ts', '.js'], modules: [ + path.resolve(__dirname, 'src'), path.resolve(__dirname, 'node_modules') ] },