Skip to content

How to use Asynchronous Plugins in Remark? #1314

Answered by ChristianMurphy
fwx5618177 asked this question in Q&A
Discussion options

You must be logged in to vote

This is a test case designed to evaluate the AST after modifying node values in an asynchronous plugin

Then use unified.process or unified.run with async await https://github.com/unifiedjs/unified?tab=readme-ov-file#overview

When I refer to this.node, I am indicating that particular node.

I understand, but have you passed a reference to the node or a copy of the node?

It's not a concern; it’s simply employed within a design pattern of strategies.

It is a concern, misuse of inheritance has been known to be an anti-pattern for over 30 years.
There's a whole chapter dedicated to it in the Gang of Four Patterns book, the same book defines the Strategy Pattern https://en.wikipedia.org/wi…

Replies: 2 comments 8 replies

Comment options

You must be logged in to vote
2 replies
@fwx5618177
Comment options

@ChristianMurphy
Comment options

Comment options

You must be logged in to vote
6 replies
@ChristianMurphy
Comment options

@fwx5618177
Comment options

@ChristianMurphy
Comment options

Answer selected by fwx5618177
@fwx5618177
Comment options

@ChristianMurphy
Comment options

@fwx5618177
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants