You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When i bump to 1.0.0-alpha.74 and configure the search field,start a server will get a error.
The reason is that my markdown plugin which depends on env parameters that contains path info in markdownToVue.ts
But when I configure the search field in config.ts, in localSearchPlugin.ts which use md.render(await fs.readFile(file, 'utf-8')), It lacks path info in env object as belows:
My plugin is a normal markdown plugin which relies env.path.
exportconstloadContainerPlugin=(md: MarkdownIt)=>{md.use(markdownItContainer,'demo',{validate(params){return!!params.trim().match(/^demo/)},render(tokens: Token[],idx,_,env){// It will breaks when working with localSearchPlugin.tsconsole.log(env.path)}})}
Reproduction
none
Expected behavior
localSearchPlugin should keep the same logic as markdownToVue when use md.render()
Describe the bug
When i bump to
1.0.0-alpha.74
and configure thesearch
field,start a server will get a error.The reason is that my markdown plugin which depends on
env
parameters that containspath
info inmarkdownToVue.ts
But when I configure the
search
field inconfig.ts
, inlocalSearchPlugin.ts
which usemd.render(await fs.readFile(file, 'utf-8'))
, It lackspath
info inenv
object as belows:My plugin is a normal markdown plugin which relies
env.path
.Reproduction
none
Expected behavior
localSearchPlugin
should keep the same logic asmarkdownToVue
when usemd.render()
System Info
Additional context
No response
Validations
The text was updated successfully, but these errors were encountered: