peerigon/markdown-loader

Documentation no longer valid for webpack2

jeanbza opened this issue · 2 comments

Using the following syntax from the README.md:

module.exports = {
    ...
    markdownLoader: {
        renderer: renderer
    }
};

I get:

[0] Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
[0]  - configuration has an unknown property 'markdownLoader'. These properties are valid:
[0]    object { amd?, bail?, cache?, context?, dependencies?, devServer?, devtool?, entry, externals?, loader?, module?, name?, node?, output?, performance?, plugins?, profile?, recordsInputPath?, recordsOutputPath?, recordsPath?, resolve?, resolveLoader?, stats?, target?, watch?, watchOptions? }
[0]    For typos: please correct them.
[0]    For loader options: webpack 2 no longer allows custom properties in configuration.
[0]      Loaders should be updated to allow passing options via loader options in module.rules.
[0]      Until loaders are updated one can use the LoaderOptionsPlugin to pass these options to the loader:
[0]      plugins: [
[0]        new webpack.LoaderOptionsPlugin({
[0]          // test: /\.xxx$/, // may apply this only for some modules
[0]          options: {
[0]            markdownLoader: ...
[0]          }
[0]        })
[0]      ]
meaku commented

Thanks @jadekler. I will look into it.

meaku commented

Fixed! Any feedback appreciated.