phryneas / remark-typescript-tools

MIT License
129 stars 7 forks source link

allow overwriting file extensions this plugin runs for #7

Closed vkarpov15 closed 2 years ago

vkarpov15 commented 3 years ago

Nice plugin! I got it mostly working for https://github.com/temporalio/documentation/pull/496, the only issue is that we use .md instead of .mdx for our MDX files and there's no workaround for running this plugin on .md files.

phryneas commented 3 years ago

Hmm. The plugin generates mdx output - would this even work in a .md file? :thinking:

I mean, if it does work for you I'm happy to merge, just wondering :sweat_smile:

vkarpov15 commented 3 years ago

Any md file is valid mdx, modulo edge cases :) I think the rationale is that our docs are written in plain markdown, hence .md, but docusaurus compiles the markdown files as mdx, so plugins can insert mdx functionality.

slorber commented 3 years ago

By default Docusaurus compile both .md/.mdx with MDX so that seems like a good option to allow this

Note in practice it's annoying for a few users because adopting Docusaurus means that commonmark docs are not always 100% compatible (https://github.com/facebook/docusaurus/issues/3018)

phryneas commented 2 years ago

Then let's get this in :)

phryneas commented 2 years ago

This has been released in v1.0.9

vkarpov15 commented 2 years ago

Thanks :+1: I'll take a look at integrating this into temporal's docs next week.