Skip to content

Commit 94f8d31

Browse files
committed
fix: avoid self-closing tag
1 parent ed912ba commit 94f8d31

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ module.exports = function attacher({ liveFilter } = {}) {
6666
.replace(/</g, "&lt;")
6767
.replace(/>/g, "&gt;")}"`
6868
: ""
69-
} />`;
69+
} ></vue-live>`;
7070

7171
node.type = "html";
7272
node.value = markdownGenerated;

index.spec.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ test("transform fenced into vue-live with live flag", () => {
1717
expect(String(file)).toMatchInlineSnapshot(`
1818
"<vue-live
1919
:layout-props=\\"{lang:'vue'}\\"
20-
:code=\\"\`&lt;comp/&gt;\`\\" />
20+
:code=\\"\`&lt;comp/&gt;\`\\" ></vue-live>
2121
"
2222
`);
2323
}
@@ -63,7 +63,7 @@ test("transform custom fenced into vue-live", () => {
6363
expect(String(file)).toMatchInlineSnapshot(`
6464
"<vue-live
6565
:layout-props=\\"{lang:'pizza'}\\"
66-
:code=\\"\`&lt;comp/&gt;\`\\" />
66+
:code=\\"\`&lt;comp/&gt;\`\\" ></vue-live>
6767
"
6868
`);
6969
}
@@ -91,7 +91,7 @@ const a = require('test/req')
9191
:requires=\\"{'test/import': require('test/import'),'test/req': require('test/req')}\\"
9292
:code=\\"\`import b from 'test/import'
9393
const a = require('test/req')
94-
&lt;comp/&gt;\`\\" />
94+
&lt;comp/&gt;\`\\" ></vue-live>
9595
"
9696
`);
9797
}
@@ -115,7 +115,7 @@ test("transform require and import statements", () => {
115115
"<vue-live
116116
:layout-props=\\"{lang:'js'}\\"
117117
:code=\\"\`&lt;comp/&gt;\`\\"
118-
:editor-props=\\"{&quot;lineNumbers&quot;: true}\\" />
118+
:editor-props=\\"{&quot;lineNumbers&quot;: true}\\" ></vue-live>
119119
"
120120
`);
121121
}

0 commit comments

Comments
 (0)