Comments (2)
I tried that, but I got an error: TypeError: mdPlugin is not a function
. (Version 2.1.0)
console.log(mdPlugin)
shows it as
{
Mode: { TOC: 'toc', HTML: 'html', REACT: 'react', VUE: 'vue' },
plugin: [Function: plugin],
default: [Function: plugin]
}
Changing the import to
import {plugin as mdPlugin, Mode} from 'vite-plugin-markdown';
fixed it for me.
I don't understand what is wrong there, though.
from vite-plugin-markdown.
Register it correctly.
import { defineConfig } from 'vite';
import mdPlugin, {Mode} from 'vite-plugin-markdown';
export default defineConfig({
plugins: [
mdPlugin({ mode: [Mode.HTML, Mode.TOC, Mode.VUE] })
],
});
from vite-plugin-markdown.
Related Issues (20)
- Dynamically loading markdown files HOT 1
- npm ERR! ERESOLVE unable to resolve dependency tree (Svelte 3.44.0) HOT 2
- [FR] Additional output modes
- Handle relative image paths HOT 2
- not support table render HOT 1
- Using template string in md code block caused error !
- Add plain string mode support HOT 2
- Need to support Vite 4 HOT 2
- No html mode HOT 1
- `Mode.MARKDOWN` does not exist on type `Mode` HOT 2
- [vite] mdPlugin is not a function HOT 2
- Can I use it without react or vue? HOT 2
- npm i vite-plugin-markdown error HOT 1
- 异常:TypeError: 'caller', 'callee', and 'arguments' properties may not be accessed on strict mode functions or the arguments objects for calls to them at Function.invokeGetter (<anonymous>:3:28)
- ReferenceError: vueRender is not defined HOT 1
- there is no type : Mode.RAW HOT 1
- @babel/preset-react should be in package.json dependencies HOT 4
- Table not works in react
- Support for Vite 5 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vite-plugin-markdown.