snowpack-plugin-mdx
TypeScript icon, indicating that this package has built-in type declarations

0.3.1 • Public • Published

snowpack-plugin-mdx

snowpack-plugin-mdx

Use the MDX compiler to build .mdx and .md files in Snowpack
npm i -D snowpack-plugin-mdx @mdx-js/mdx @mdx-js/react

Types Code coverage Build status NPM Version MIT License


Quick start

// snowpack.config.json
{
  "plugins": [["snowpack-plugin-mdx", { /* see "Plugin Options" below */ }]]
}

Plugin Options

interface SnowpackPluginMdxOptions {
  /**
   * Includes only the  specified paths
   */
  include?: string[]
  /**
   * Excludes the specified paths
   */
  exclude?: string[]
  /**
   * These options are passed directly to babel.transformAsync()
   */
  babelOptions?: TransformOptions
  /**
   * These options are passed directly to the MDX compiler
   */
  mdxOptions?: Record<string, any>
  /**
   * Override the default renderer
   *
   * @default ```js
   *   import React from 'react'
   *   import { mdx } from '@mdx-js/react'
   * ```
   */
  renderer?: string
}

LICENSE

MIT

/snowpack-plugin-mdx/

    Package Sidebar

    Install

    npm i snowpack-plugin-mdx

    Weekly Downloads

    2

    Version

    0.3.1

    License

    MIT

    Unpacked Size

    37.6 kB

    Total Files

    16

    Last publish

    Collaborators

    • jaredlunde