webpack-root-directory-alias
v1.0.0
Published
A minimal module and CLI to make project environment configurations
Downloads
4
Readme
webpack Root Directories Alias
Generates a object of the current root directories
Installing
$ npm install --save-dev webpack-root-directory-alias
Use case
webpack.config.js
var webpackRootDirectoriesAlias = require('./webpack-root-directory-alias')
module.exports = {
target: 'node',
resolve: {
extensions: ['', '.js', '.jsx'],
alias: webpackRootDdirectoriesAlias()
},
module: {
loaders: [
{ test: /\.(js|jsx)$/, exclude: /node_modules/, loader: 'babel' },
]
}
}