#Using remark/rehype plugins per-layout?
5 messages · Page 1 of 1 (latest)
You can selectively apply plugins using the files path like this: #1132726084589330562 message
Oooh! Would this be a new file in my plugins directory that I then load in astro.config.mjs? I'm not super familiar with transformers
Ya, the example is a remark plugin so you can add it to your config like this: ```js
import { defineConfig } from 'astro/config'
import { conditionalRemarkBehead } from '../your/plugin/file';
export default defineConfig({
markdown: {
remarkPlugins: [
conditionalRemarkBehead
]
}
})
Trying this, thanks!