diff --git a/src/content/guides/asset-management.md b/src/content/guides/asset-management.md index 86838d3b564d..770f6363bd98 100644 --- a/src/content/guides/asset-management.md +++ b/src/content/guides/asset-management.md @@ -86,6 +86,9 @@ __webpack.config.js__ + }, }; ``` +Module loaders can be chained. Each loader in the chain applies transformations to the processed resource. A chain is executed in reverse order. The first loader passes its result (resource with applied transformations) to the next one, and so forth. Finally, webpack expects JavaScript to be returned by the last loader in the chain. + +The above order or loaders should be maintained with 'style-loader' coming first and then, 'css-loader'. If this convention is not followed, webpack is likely to throw errors. T> webpack uses a regular expression to determine which files it should look for and serve to a specific loader. In this case, any file that ends with `.css` will be served to the `style-loader` and the `css-loader`.