Open ManasMadrecha opened 2 years ago
Thanks for your issue @ManasMadrecha
I think that MDC should ignore the [[
or ![[
syntax directly ☺️
Fixed in remark-mdc
package and soon will be available on the edge channel
@farnabaz @Atinux Not yet fixed in edge channel. The remark-mdc
doesn't ignore the [[
or ![[
which makes it very difficult to convert them to links using custom-plugin. It still converts them into span
.
Kindly reopen the issue.
Is your feature request related to a problem? Please describe
Issue encountered in https://github.com/Atinux/content-wind/issues/6#issuecomment-1213299468
Currently, the
remark-mdc
plugin is parsed first, and then any other custom plugin.This happens even when in
nuxt.config.ts
:Note: Here,
'@docus/remark-mdc'
is manually added last inremarkPlugins
array. Still, it is parsed first.So, this markdown
becomes
With MDC enabled (by default)
![image](https://user-images.githubusercontent.com/65993481/184408537-52e29204-c930-4c0d-9003-b6e5fee52db2.png)With MDC disabled
![image](https://user-images.githubusercontent.com/65993481/184408982-fb5f85b7-3e22-433c-ad0c-faffc532eb2b.png)So, inside the custom remark plugin, it becomes difficult to target
[[...
type of text, e.g., wiki-links or![[...
, e.g., embed/attachments/transclusions.So, the issue is I can either use my custom plugin or the
remark-mdc
, but not both together.Describe the solution you'd like
The Module should parse the remark plugins based on the order they are present in the array of
remarkPlugins
. Don't give priority tomdc
plugin. Parse it as last remark plugin.Describe alternatives you've considered
Disable
mdc
, i.e., set it tofalse
. Then, use the custom remark plugin. But this prevents me from usingmdc
at all.Additional context