import path from 'path' ; import { Configuration } from 'webpack' ; import { ConfigurationFactory } from '../interface' ; const factory = entry => { const { cwd } = entry ; const config = { output : { path : path . join ( cwd , 'dist' ) , filename : 'index.js' , libraryTarget : 'commonjs2' , } , } ; return config ; } ; export default factory ;