jrans / React-Webpack-Hotloader

Example of how to set up a project that uses three technologies above!
7 stars 0 forks source link

How do the loaders work? #4

Open besarthoxhaj opened 9 years ago

minaorangina commented 8 years ago

@jrans Do you have an answer to this yet? In particular wondering if there's a difference (other than stylistic preference) between

loader: "style!css!sass"

and

loaders: ["style", "css", "sass"]

I once ran into an error where webpack didn't like me having a query (for babel presets) alongside the loaders: ["react-hot", "babel-loader"]. Wonder whether writing it as loader: "react-hot!babel" would have made a difference

Also I know in some cases loaders are read from right to left, so the order you put them in can have different consequences. Documentation is a bit on the scant side for some of this stuff :blush: