GithubHelp home page GithubHelp logo

集成应用的离线需求 about vditor HOT 7 CLOSED

fu050409 avatar fu050409 commented on July 19, 2024
集成应用的离线需求

from vditor.

Comments (7)

Vanessa219 avatar Vanessa219 commented on July 19, 2024

cdn 配置为 "" ,然后把 dist 拷贝到对应路径下试试。https://github.com/Vanessa219/vditor/blob/32e7c46373ce55205ec32d0099f7df6189518e74/demo/index.js 离线也是可以使用的。

from vditor.

fu050409 avatar fu050409 commented on July 19, 2024

打包构建都是 Tauri 提供的

对 Vue 的打包是由 Tauri 接管的,也就是说集成进入 Tauri 软件的是由 Rust Cargo 集成打包的,我无法在编译时修改 dist 文件的内容

from vditor.

fu050409 avatar fu050409 commented on July 19, 2024

我这边能进行修改的只有 Vue 的代码,而 Tauri 的 CLI 是编译后的 Cargo 二进制工具,如果要在编译时确保 Vditor 的依赖都被打包,那就只能修改编译工具链的代码

from vditor.

Vanessa219 avatar Vanessa219 commented on July 19, 2024

不需要修改 dist 文件。初始化时使用 cdn 参数即可。

from vditor.

fu050409 avatar fu050409 commented on July 19, 2024

不需要修改 dist 文件。初始化时使用 cdn 参数即可。

十分感谢你的回答和耐心,我不久前意识到你的意思是我可以将它放在public文件夹里来让 Vditor 获取,这的确是一个十分可行的方案。

from vditor.

fu050409 avatar fu050409 commented on July 19, 2024

我其实还是觉得应该做一个本地导入的选项,Tauri打包之后的软件50%的占用都来自Vditor,vite和rollupjs都无法对Vditor的依赖和样式表进行压缩优化

from vditor.

Vanessa219 avatar Vanessa219 commented on July 19, 2024

dist 里面是已经压缩过了的,可能作用不大,vditor 中主要是 lute 比较大。

from vditor.

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.