Git Product home page Git Product logo

Comments (13)

 avatar commented on May 24, 2024

上传文件需要后端提供接口,你给组件的config属性传递一个对象就可以,里面的serverUrl字段填上后端给你的接口地址。如果你是还有疑问或者配置错误,可以把我写的DEMO克隆下来,作为参考。
image

image

from vue-ueditor-wrap.

zongcong avatar zongcong commented on May 24, 2024

谢谢,还有一个问题,就是循环多个编辑器的时候,接口请求返回数据如果比多个编辑快的时候,会报错,这个怎么解决呢

from vue-ueditor-wrap.

 avatar commented on May 24, 2024

@zongcong 可以把你的代码和报错截个图吗?

from vue-ueditor-wrap.

zongcong avatar zongcong commented on May 24, 2024

image
这是报错,然后有时候页面的双向绑定没有起作用,我估计是编辑器比接口请求的数据晚加载了

from vue-ueditor-wrap.

zongcong avatar zongcong commented on May 24, 2024

我测试了一下在接口请求的数据成功那边加了个定时器之后,等编辑器加载完成之后在重新赋值是正常的

from vue-ueditor-wrap.

 avatar commented on May 24, 2024

你尝试一下在@ready方法中请求接口

from vue-ueditor-wrap.

 avatar commented on May 24, 2024

@zongcong 不要设定时器,接口返回的时间和实例化编辑器的时间是不确定的

from vue-ueditor-wrap.

zongcong avatar zongcong commented on May 24, 2024

我这边是要在接口返回的数据加载相应的或者多个的编辑器。这样好像行不通吧

from vue-ueditor-wrap.

 avatar commented on May 24, 2024

我理解你得意思是:你要绑定的数据是接口请求下来的,但是多个编辑器实例化的速度比你接口返回数据慢,所以报错了。但是即使你一开始就绑定值,也不会报错呀!所以不太明白你的为什么会报错,可以给我看一下你具体使用的代码吗?

from vue-ueditor-wrap.

zongcong avatar zongcong commented on May 24, 2024

image
image
第一张是正常能够绑定的时候,第二张是绑定不了的时候。报错我这边检查一下

from vue-ueditor-wrap.

 avatar commented on May 24, 2024

我看你第二张图里面的实例是空,v-model绑定的数据有内容,但是我在组件封装的时候已经考虑到了
image
当你没有实例的时候,会先初始化实例,初始化之后才会把值赋给ueditor,所以不太清楚你为什么报错,如果你不方便贴你项目代码的图,可以发到我邮箱[email protected]

from vue-ueditor-wrap.

zongcong avatar zongcong commented on May 24, 2024

找到问题了,我这边的问题,谢谢了

from vue-ueditor-wrap.

KDWangBoss avatar KDWangBoss commented on May 24, 2024

大佬,可以问下这个富文本编辑器图片上传serverUrl是指后端的上传接口吗

from vue-ueditor-wrap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.