slidev-addon-eslint-editor-vue
v0.1.6
Published
Slidev addon that add eslint vue editor component
Downloads
5
Maintainers
Readme
ESLint Vue Editor for Slidev
Addon for Slidev (Presentation Slides for Developers)
Based on eslint-editor-vue from @ota-meshi
Usage
Install
npm i slidev-addon-eslint-editor-vue
yarn add slidev-addon-eslint-editor-vue
pnpm add slidev-addon-eslint-editor-vue
Slidev Configuration
Define addon in your slidev addons.
In your slides metadata (using Front Matter):
---
addons:
- slidev-addon-eslint-editor-vue
---
Vite configuration
// vite.config.js
import { defineConfig, mergeConfig } from "vite"
import eevConfig from "slidev-addon-eslint-editor-vue/vite.config"
const config = defineConfig({
// your config
})
export default mergeConfig(config, eevConfig)
Use in slides
Usually as any component.
- Can pass code as a code-block.
<ESLintVueEditor :rules="{ ... }">
```vue
<template>
<div>Hello</div>
</template>
```
</ESLintVueEditor>
- Can pass code as a snippet.
<ESLintVueEditor :rules="{ ... }">
<<< @/snippets/code.vue
</ESLintVueEditor>
(Currently) Supported plugins
Need another plugin? Add your