From 2faf2e34331703b3bdea3eb487cb8799c8d65377 Mon Sep 17 00:00:00 2001 From: Armand Philippot Date: Tue, 19 Sep 2023 18:13:57 +0200 Subject: refactor(build): replace paths aliases with relative paths Using paths aliases starting with "@" can be confusing and can lead to conflict with existings modules. I prefer to use relative paths to avoid extra configuration in tools because of these aliases. --- .storybook/main.js | 15 --------------- 1 file changed, 15 deletions(-) (limited to '.storybook/main.js') diff --git a/.storybook/main.js b/.storybook/main.js index 477b09e..ca18e6b 100644 --- a/.storybook/main.js +++ b/.storybook/main.js @@ -1,5 +1,3 @@ -const path = require('path'); - /** * @typedef {import('webpack').Configuration} WebpackConfig */ @@ -35,19 +33,6 @@ const storybookConfig = { /** @type {import('next').NextConfig} */ const nextConfig = require('../next.config'); - // Set modules aliases. - config.resolve.alias = { - ...config.resolve.alias, - '@i18n': path.resolve(__dirname, '../src/i18n'), - '@assets': path.resolve(__dirname, '../src/assets'), - '@components': path.resolve(__dirname, '../src/components'), - '@content': path.resolve(__dirname, '../src/content'), - '@pages': path.resolve(__dirname, '../src/pages'), - '@services': path.resolve(__dirname, '../src/services'), - '@styles': path.resolve(__dirname, '../src/styles'), - '@utils': path.resolve(__dirname, '../src/utils'), - }; - return { ...config, ...nextConfig.webpack }; }, }; -- cgit v1.2.3