# vue-neditor-wrap-fixed

> Vue + NEditor + v-model双向绑定

Latest version **1.1.0** (published 2020-03-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install vue-neditor-wrap-fixed
pnpm add vue-neditor-wrap-fixed
yarn add vue-neditor-wrap-fixed
bun add vue-neditor-wrap-fixed
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; large bundle.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.0 |
| Published | 2020-03-25 |
| First published | 2020-03-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 25.3 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 243 |
| Author | 晁州 |
| Maintainers | missv |
| Keywords | ueditor, neditor, vue, vue-cli3, v-model, 富文本编辑器, 百度编辑器 |

## Links

- npm: https://www.npmjs.com/package/vue-neditor-wrap-fixed
- Repository: https://github.com/caiya/vue-neditor-wrap
- Homepage: https://github.com/caiya/vue-neditor-wrap#readme
- Issues: https://github.com/caiya/vue-neditor-wrap/issues
- npm.io page: https://npm.io/package/vue-neditor-wrap-fixed

## Alternatives

- [ext-list](https://npm.io/package/ext-list.md) — 6.3M weekly downloads
- [@lexical/selection](https://npm.io/package/@lexical/selection.md) — 3.8M weekly downloads
- [@lexical/text](https://npm.io/package/@lexical/text.md) — 3.6M weekly downloads
- [@lexical/clipboard](https://npm.io/package/@lexical/clipboard.md) — 3.0M weekly downloads
- [@tiptap/extension-mention](https://npm.io/package/@tiptap/extension-mention.md) — 3.0M weekly downloads

## Recent versions

- 1.1.0 (latest) — 2020-03-25

## README

# vue-neditor-wrap

## Installation
```bash
$ npm i vue-neditor-wrap
```

## Quick Start

1. 下载[官方资源文件](https://www.notadd.com/download/neditor/Neditor-next-master.tar.xz)

    > 下载完成后放在本地public下，命名为NEditor的文件夹下

2. 引入`VueNeditorWrap`组件

    `import VueNeditorWrap from 'vue-neditor-wrap'`

3. 注册组件
    ```js
    components: {
        VueNeditorWrap
    },
    ```
4. `v-model`绑定数据
    ```html
    <vue-neditor-wrap v-model="content" :config="myConfig" :destroy="false" @ready="ready"></vue-neditor-wrap>
    ```
    ```js
    data () {
        return {
            myConfig: {
                // 如果需要上传功能,找后端小伙伴要服务器接口地址
                serverUrl: '/api/web/upload/ueditor',
                // 你的UEditor资源存放的路径,相对于打包后的index.html
                UEDITOR_HOME_URL: '/NEditor/',
                // 编辑器不自动被内容撑高
                autoHeightEnabled: false,
                // 初始容器高度
                initialFrameHeight: 240,
                // 初始容器宽度
                initialFrameWidth: '100%',
                // 关闭自动保存
                enableAutoSave: false
            },
            content: '',
        }
    }
    ```
    > 至此你已经可以在页面中看到一个初始化之后的`NEditor`了，并且它已经成功和数据绑定了！

    ![](https://raw.githubusercontent.com/caiya/imgs/master/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20181124115713.png)

    ![](https://raw.githubusercontent.com/caiya/imgs/master/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20181124114504.png)

## License

[MIT](http://opensource.org/licenses/MIT)

---
_Source: https://npm.io/package/vue-neditor-wrap-fixed · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
