Skip to content

Commit

Permalink
fix(docs): non-linear time regex
Browse files Browse the repository at this point in the history
  • Loading branch information
kris7t committed Apr 26, 2024
1 parent c61fd44 commit d75fa7a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion subprojects/docs/src/plugins/remarkPosix2Windows.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ function createTabItem(

function transformNode(node: Code): MdxJsxFlowElement[] {
const posixCode = node.value;
const windowsCode = posixCode.replaceAll(/(?<=^\w*)\.\//gm, '.\\');
const windowsCode = posixCode.replaceAll(
/(^\w*)\.\//gm,
(_substring, prefix: string) => `${prefix}.\\`,
);
return [
{
type: 'mdxJsxFlowElement',
Expand Down

0 comments on commit d75fa7a

Please sign in to comment.