Skip to content

Commit

Permalink
feat(webpack-runner): 修复import与extract插件的配置错误
Browse files Browse the repository at this point in the history
  • Loading branch information
Littly committed Sep 14, 2018
1 parent 8ceee13 commit bfae27a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/taro-webpack-runner/src/util/chain.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as path from 'path';
import { partial } from 'lodash';
import { pipe } from 'lodash/fp';
import MiniCssExtractPlugin from 'mini-css-extract-plugin';
import * as MiniCssExtractPlugin from 'mini-css-extract-plugin';

import { Option } from './types';

Expand All @@ -25,7 +25,9 @@ const getSassLoader = pipe(mergeOption, partial(getLoader, 'sass-loader'))
const getLessLoader = pipe(mergeOption, partial(getLoader, 'less-loader'))
const getStylusLoader = pipe(mergeOption, partial(getLoader, 'stylus-loader'))
const getExtractCssLoader = () => {
return MiniCssExtractPlugin.loader
return {
loader: MiniCssExtractPlugin.loader
}
}

const appPath = process.cwd()
Expand Down

0 comments on commit bfae27a

Please sign in to comment.