Home

Awesome

<div align="center"> <a href="https://github.com/webpack/webpack"> <img width="200" height="200" src="https://webpack.js.org/assets/icon-square-big.svg"> </a> </div>

npm node chat size total-downloads issues GitHub license

snarkdown-loader

Getting Started

A lightweight markdown loader using snarkdown

To begin, you'll need to install snarkdown-loader:

npm install snarkdown-loader --save-dev

Then add the loader to your webpack config. For example:

index.js

import file from 'readme.md';

webpack.config.js

module.exports = {
  module: {
    rules: [
      {
        test: /.md$/,
        use: [
          {
            loader: `snarkdown-loader`,
          },
        ],
      },
    ],
  },
};

And run webpack via your preferred method.

Example

webpack.config.js

module.exports = {
  module: {
    rules: [
      {
        test: /.md$/,
        use: [
          {
            loader: 'html-loader', // Exports HTML as string
          },
          {
            loader: `snarkdown-loader`, // converts the markdown to HTML
          },
        ],
      },
    ],
  },
};

Contributing

Please take a moment to read our contributing guidelines if you haven't yet done so.

CONTRIBUTING

MIT

Maintained by

<img alt="pluggingIn logo" src="https://imgur.com/kjyrz79.png" width="250px" />

Author

Aniketh Saha

License

MIT