2017-08-28 20 views
0

Lorsque j'extrais un fichier .pug avec ExtractTextPlugin, il le convertit en html mais minify, car il ne l'est pas ??pug d'unminify utilisant le plugin ExtractTextPlugin

const extractHTML = new ExtractTextPlugin('[name]-pug.html'); 

.... 


{ 
    test: /\.pug$/, 
    use: extractHTML.extract({ 
     fallback: "style-loader", 
     use: ['html-loader' ,'pug-html-loader'], 
     options: { 
      pretty: true 
     } 
    }) 
} 

Répondre

0

C'est ce que j'utilisée pour la sortie unminified HTML:

{ 
    test: /\.pug$/, 
    include: path.join(__dirname, 'src'), 
    use: [{ 
     loader: 'pug-loader', 
     options: { pretty: true }, 
    }], 
    },