diff --git a/.eslintrc.json b/.eslintrc.json index 68e641c..01c53cf 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -3,6 +3,7 @@ "browser": true, "es2021": true }, + "plugins": ["react", "@typescript-eslint", "import"], "extends": ["plugin:react/recommended"], "parser": "@typescript-eslint/parser", "settings": { @@ -22,6 +23,7 @@ "ecmaVersion": 12, "sourceType": "module" }, - "plugins": ["react", "@typescript-eslint"], - "rules": {} + "rules": { + "import/extensions": ["error", "always"] + } } diff --git a/src/App.test.tsx b/src/App.test.tsx index 2a68616..090f147 100644 --- a/src/App.test.tsx +++ b/src/App.test.tsx @@ -1,5 +1,7 @@ import React from 'react'; import { render, screen } from '@testing-library/react'; +// TODO: add extension +// eslint-disable-next-line import/extensions import App from './App'; test('renders learn react link', () => { diff --git a/src/index.tsx b/src/index.tsx index 8415a35..9552975 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -1,8 +1,12 @@ import './index.css'; +// TODO: add extension +// eslint-disable-next-line import/extensions import App from './App'; import React from 'react'; import ReactDOM from 'react-dom'; +// TODO: add extension +// eslint-disable-next-line import/extensions import reportWebVitals from './reportWebVitals'; ReactDOM.render(