
Security News
Potemkin Understanding in LLMs: New Study Reveals Flaws in AI Benchmarks
New research reveals that LLMs often fake understanding, passing benchmarks but failing to apply concepts or stay internally consistent.
@hydrabot/slate-vue
Advanced tools
in npm
npm install slate-vue
in yarn
yarn add slate-vue
import
import Vue from 'vue'
import { SlatePlugin } from 'slate-vue';
Vue.use(SlatePlugin)
use
<template>
<Slate :value="value">
<Editable placeholder="Enter some plain text..."></Editable>
</Slate>
</template>
<script>
import {Slate, Editable} from 'slate-vue'
// this value is for editor
const initialValue = [
{
children: [
{ text: 'This is editable plain text, just like a <textarea>!' },
],
},
]
export default {
name: 'index',
components: {
Slate,
Editable
},
data() {
return {
value: JSON.stringify(initialValue)
}
}
};
</script>
Vue's jsx and tsx grammar is recommend, but SFC is also supported.
Most of the usage is same with slate-react. Here are same difference as guideline:
this.$editor
If you want to apply some plugins(e.g. slate-history), use editorCreated hook:
Vue.use(SlatePlugin, {
editorCreated(editor) {
withHistory(editor)
}
})
It will be called after each editor created.
ReturnType must be any legal type which is equal with the first argument in Vue's createElement, please see.
Use Vue.mixin
import {SelectedMixin, FocusedMixin} from 'slate-vue'
And you will get selected, focused data in your component
Use global inject: inject: ['readOnly]
And you will get readOnly data in your component
import {useEffect, useRef} from 'slate-vue'
Same as react hooks. Forked from vue-hooks.
import {fragment} from 'slate-vue'
Forked from vue-fragment
import {VueEditor} from 'slate-vue'
Same api with react-editor
If your component is related to the editor(like toolbar), you must add slateMixin for rerender:
import {SlateMixin} from 'slate-vue'
For Nuxtjs, you must add slate-vue
and vue-tsx-support
into your transpile option in nuxt.config.js
build: {
transpile: ['slate-vue', 'vue-tsx-support']
}
FAQs
## Install
The npm package @hydrabot/slate-vue receives a total of 11 weekly downloads. As such, @hydrabot/slate-vue popularity was classified as not popular.
We found that @hydrabot/slate-vue demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
New research reveals that LLMs often fake understanding, passing benchmarks but failing to apply concepts or stay internally consistent.
Security News
Django has updated its security policies to reject AI-generated vulnerability reports that include fabricated or unverifiable content.
Security News
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.