nl_tokens: 为src目录下的所有子目录创建alias
pl_tokens: function createMapper ( ) { var packagesDir = path . resolve ( __dirname , '../src' ) ; var packages = fs . readdirSync ( packagesDir ) ; return packages . filter ( p => <mask> . statSync ( path . join ( packagesDir , p ) ) . isDirectory ( ) ) . reduce ( ( alias , p ) => { alias [ ` ${ p } ` ] = ` ${ p } ` ; alias [ ` ${ p } ` ] = ` ${ p } ` ; return alias ; } , { } ) ; }