https://github.com/justforuse/vitepress-plugin-markdown-define
https://github.com/justforuse/vitepress-plugin-markdown-define
Last synced: 12 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/justforuse/vitepress-plugin-markdown-define
- Owner: justforuse
- License: mit
- Created: 2023-06-21T06:22:54.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2023-06-21T07:49:44.000Z (over 2 years ago)
- Last Synced: 2025-02-23T08:42:13.863Z (about 1 year ago)
- Language: JavaScript
- Size: 6.84 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
vitepress-plugin-markdown-define
Doc for vitepress-plugin-markdown-define.
## Install
```sh
npm install vitepress-plugin-markdown-define -D
```
## How to use
In your `config.ts`
```ts
import useDefinePlugin from 'vitepress-plugin-markdown-define'
const CONSTS = {
__custom_variable__: 'your value'
}
export default defineConfig({
markdown: {
config(md) {
useDefinePlugin(md, CONSTS)
},
},
})
```