Advertisement
Guest User

Untitled

a guest
Feb 20th, 2019
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.79 KB | None | 0 0
  1. const path = require('path');
  2. const MiniCssExtractPlugin = require("mini-css-extract-plugin");
  3.  
  4. let conf={
  5. entry: './src/index.js',
  6. output: {
  7. path: path.resolve(__dirname, 'dist'),
  8. },
  9. plugins: [
  10. new MiniCssExtractPlugin({
  11. filename: "styles.css"
  12. }),
  13. ],
  14. module: {
  15. rules: [
  16. {
  17. test: /\.ttf$/,
  18. loader: 'file-loader',
  19. options: {}
  20. },
  21. {
  22. test: /\.scss$/,
  23. use: [
  24. MiniCssExtractPlugin.loader,
  25. "css-loader",
  26. "sass-loader"
  27. ]
  28. },
  29.  
  30. {
  31. test: /\.m?js$/,
  32. exclude: /(node_modules|bower_components)/,
  33. use: {
  34. loader: 'babel-loader',
  35. options: {
  36. presets: ['es2015']
  37. }
  38. }
  39. }
  40. ]
  41. }
  42. }
  43.  
  44. module.exports=conf;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement