[request] add option for only match when language is set on matter
bluelovers opened this issue · comments
bluelovers commented
let text_not_parse = `---
title: Hello
slug: home
---
<h1>Hello world!</h1>
This is content
<!-- end -->
<h1>Hello world</h1>`;
/*
{
content: '---\ntitle: Hello\nslug: home\n---<h1>Hello world!</h1>\nThis is content\n<!-- end -->\n<h1>Hello world</h1>',
data: {},
isEmpty: false,
excerpt: ''
}
*/
let text_will_parse = `---yaml
title: Hello
slug: home
---
<h1>Hello world!</h1>
This is content
<!-- end -->
<h1>Hello world</h1>`;
/*
{
content: '<h1>Hello world!</h1>\nThis is content\n<!-- end -->\n<h1>Hello world</h1>',
data: { title: 'Hello', slug: 'home' },
isEmpty: false,
excerpt: ''
}
*/