snarkdown-loader

markdown loader based on snarkdown

Usage no npm install needed!

<script type="module">
  import snarkdownLoader from 'https://cdn.skypack.dev/snarkdown-loader';
</script>

README

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

pluggingIn logo

Author

Aniketh Saha

License

MIT