Skip to content

Commit 9c2c848

Browse files
committed
[CHORE] Allow for absolute file paths
1 parent b206ed8 commit 9c2c848

File tree

2 files changed

+17
-5
lines changed

2 files changed

+17
-5
lines changed

.eslintrc

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55
"files": [
66
"stories/*.{js,jsx}"
77
],
8-
rules: {
9-
"import/no-extraneous-dependencies": ["error", { "devDependencies": true }],
10-
},
8+
"rules": {
9+
"import/no-extraneous-dependencies": ["error", { "devDependencies": true }]
10+
}
1111
},
1212
{
1313
"files": [
14-
"src/**/*.{js,jsx}",
14+
"src/**/*.{js,jsx}"
1515
],
1616
"env": {
1717
"browser": true
@@ -103,9 +103,16 @@
103103
"react-hooks/exhaustive-deps": "warn",
104104
"react-hooks/rules-of-hooks": "error",
105105
"semi": 0
106-
},
106+
}
107107
}
108108
],
109+
"settings": {
110+
"import/resolver": {
111+
"node": {
112+
"paths": ["./"]
113+
}
114+
}
115+
},
109116
"rules": {
110117
"class-methods-use-this": 0,
111118
"function-paren-newline": ["error", "consistent"],

.storybook/webpack.config.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,10 @@ module.exports = function({ config }) {
77
include: path.resolve(__dirname, '../')
88
});
99

10+
config.resolve.modules = [
11+
...(config.resolve.modules || []),
12+
path.resolve('./'),
13+
];
14+
1015
return config;
1116
};

0 commit comments

Comments
 (0)