DynamoMTL / shopify-pipeline

Shopify Pipeline - A modern pipeline for Shopify theme development
MIT License
86 stars 16 forks source link

Enable CSS source maps #63

Open nddery opened 7 years ago

nddery commented 7 years ago

Had to remove CSS source maps to fix #61

lastobelus commented 6 years ago

How would I use webpack-merge and config/webpack.dev.conf.js to turn source maps back on? I tried:

{
  module: {
    rules: [
      {
        test: /\.s[ac]ss$/,
        use: [
          { loader: 'style-loader' },
          { loader: 'css-loader' , options: { sourceMap: true } },
          { loader: 'sass-loader' , options: { sourceMap: true } }
        ]
      }
    ]
  }
}

but no luck. Temporarily I've just done it by editing the node_module, but an example of how to use webpack-merge correctly would be awesome.

I don't use sections or admin during front end development, so #61 doesn't affect me.

nddery commented 6 years ago

Done directly in the shopify-pipeline module this should work. Have you restarted the server after making the changes ?

I'm not aware of any way to re-enable CSS source maps as you need to modify the loader from Shopify-Pipeline itself.

lastobelus commented 6 years ago

Ah, OK thanks. I was hoping there was a way to do it with custom config. I did get source maps working by editing shopifyi pipeline directly.