Skip to content
This repository has been archived by the owner on Nov 10, 2018. It is now read-only.
/ mdxfmt Public archive

[DEPRECATED] MDX is now supported in prettier

License

Notifications You must be signed in to change notification settings

mdx-js/mdxfmt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mdxfmt

An experimental code formatter for MDX.

Installation

Using the API:

npm i -D mdxfmt

Using the CLI:

npm i -g mdxfmt

Usage

Using the API:

const mdxfmt = require('mdxfmt')

const MDX = `
import { Box }
from 'grid-styled'

# Hello, world!

<div>
  hi   </div>
`

mdxfmt(MDX)

Using the CLI:

❯ mdxfmt help

    MDX code formatter

    Usage:
      mdxfmt file.md
      mdxfmt file.md > formatted.md

Options

Key Type Description
jsx {} Options object passed to Prettier for formatting JSX
md {} Options object passedt to Remark Stringify for formatting MD

About

[DEPRECATED] MDX is now supported in prettier

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published