Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use remark.process instead of remark.processSync #599

Merged
merged 1 commit into from Apr 26, 2024

Conversation

trmjoa
Copy link
Contributor

@trmjoa trmjoa commented Apr 23, 2024

Hi,

I have been using the typedoc-plugin-markdown plugin for some time and stubled across a problem where I needed to rewrite relative links from myMarkDownFile.md to ./myMarkDownFile.md. In my attempt to find a solution to do that I came across the next branch of your repository.

While trying it out, I encountered this error:

Error: `processSync` finished async. Use `process` instead
    at assertDone (file:///Users/<retracted>javascript/core-api/node_modules/unified/lib/index.js:1273:11)
    at Function.processSync (file:///Users/<retracted>/javascript/core-api/node_modules/unified/lib/index.js:820:5)
    at parseContents (/Users/<retracted>/javascript/core-api/node_modules/typedoc-plugin-remark/dist/remark.cjs:35:15)
    at async /Users/<retracted>/javascript/core-api/node_modules/typedoc-plugin-remark/dist/index.js:75:24
    at async Promise.all (index 0)
    at async /Users/<retracted>/javascript/core-api/node_modules/typedoc-plugin-remark/dist/index.js:72:13
    at async Promise.all (index 0)
    at async _classThis.render (/Users/<retracted>/javascript/core-api/node_modules/typedoc-plugin-markdown/dist/app/renderer/overrides.js:117:9)
    at async _classThis.generateDocs (/Users/<retracted>/javascript/core-api/node_modules/typedoc-plugin-markdown/dist/app/renderer/overrides.js:45:5)
    at async run (/Users/<retracted>/javascript/core-api/node_modules/typedoc/dist/lib/cli.js:118:13)

I have no idea if this fits into your plans, or if its the correct solution, but this PR changes the usage of remark to utilise the process(async) function instead of processSync.

Merge it if its helps you, or discard it if that suits you better :)

Copy link

vercel bot commented Apr 23, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
typedoc-plugin-markdown ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 23, 2024 8:18pm

@tgreyuk tgreyuk merged commit 6863663 into typedoc2md:next Apr 26, 2024
3 checks passed
@tgreyuk
Copy link
Member

tgreyuk commented Apr 26, 2024

Thats interesting - thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants