The example in the Usage as a remark plugin without Gatsby section does not compile as is:
Top-level await only available in ES Modules but used here with require() – decided to go with the former and use imports
Backticks not escaped in template string
Incorrect module name (remarkParse should be remark-parse)
Incorrect property reference in result returned from processor (contents should be value)
I also added the npm install line required and a suggestion of the file name to use (including .mjs extension) to make it easier to follow and avoid possible trip-ups.
The example in the Usage as a remark plugin without Gatsby section does not compile as is:
remarkParse
should beremark-parse
)contents
should bevalue
)I also added the npm install line required and a suggestion of the file name to use (including .mjs extension) to make it easier to follow and avoid possible trip-ups.