-
-
Save spac3unit/f84ac30139d7cd91e18d59686029e779 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* -- webpack.config.shared.js -- */ | |
| export const sharedConfig = { | |
| alias: { | |
| 'Utils': path.resolve(__dirname, '../src/app/utils/'), | |
| 'Components': path.resolve(__dirname, '../src/app/components/'), | |
| }, | |
| }; | |
| /* -- webpack.config.dev.js -- */ | |
| import { sharedConfig } from './webpack.config.shared.js'; | |
| const config = { | |
| // development config | |
| resolve: { | |
| alias: sharedConfig.alias, | |
| }, | |
| }; | |
| /* -- webpack.config.prod.js -- */ | |
| import { sharedConfig } from './webpack.config.shared.js'; | |
| const config = { | |
| // production config | |
| resolve: { | |
| alias: sharedConfig.alias, | |
| }, | |
| }; | |
| /* -- SomeComponent.js -- */ | |
| import toNumber from 'Utils/toNumber'; | |
| import toString from 'Utils/toString'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment