mirror of
https://github.com/muerwre/muerwre.github.io.git
synced 2025-04-24 18:36:41 +07:00
10 lines
278 B
TypeScript
10 lines
278 B
TypeScript
export default defineNitroPlugin((nitroApp) => {
|
|
nitroApp.hooks.hook("content:file:beforeParse", (file) => {
|
|
if (file._id.endsWith(".md")) {
|
|
file.body = file.body.replace(
|
|
/==([^=]+)==/gs,
|
|
`<span class="highlight">$1</span>`
|
|
);
|
|
}
|
|
});
|
|
});
|