Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export const html = (text: string, opts = {}) => {
unimplemented('html export');
};

export const mdast = (text: string, opts = {}) => {
export const mdast: any = (text: string, opts = {}) => {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ts can't infer this type because it would require exporting types from remark. This was my lazy way of fixing it, but we should improve this.

const processor = remark().use(remarkMdx);

try {
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"dist"
],
"scripts": {
"build": "webpack --mode production",
"build": "webpack --mode production && npm run build-types",
"build-types": "npx tsc --declaration --emitDeclarationOnly --declarationDir ./dist --skipLibCheck",
"lint": "eslint . --ext .jsx --ext .js --ext .ts --ext .tsx",
"release": "npx semantic-release",
"release.dry": "npx semantic-release --dry-run",
Expand Down