api-sorter
v0.2.0
Published
> [#7856](https://github.com/ant-design/ant-design/issues/7856) for more information
Downloads
5
Readme
api-sorter
#7856 for more information
Installation
npm install api-sorter
Usage
const apiSorter = require('api-sorter');
apiSorter({ file: 'components/**/index.+(zh-CN|en-US).md' }).then(() => {
console.log('Sorted API successfully!');
});
API
apiSorter({ file, [dest] })
file
Type: Array string
Required: true
dest
Type: string
Required: false
Default: .
apiSorter will return a Promise
.
apiSorter.sort(AST)
AST
Get Markdown AST using unified and remark-parse.
it will return sorted AST.