froala / vue-froala-wysiwyg

Vue component for Froala WYSIWYG HTML Rich Text Editor.
https://froala.com/wysiwyg-editor
632 stars 86 forks source link

How is it configured and used in vue-cli3? #55

Open vopdoo opened 6 years ago

vopdoo commented 6 years ago

Make sure you have the right Webpack settings for loading the CSS files, Font Awesome and jQuery.

In this section, how do you configure a project based on vue-cli3?

stefanneculai commented 6 years ago

We don't have such details for now, @vopdoo. Thanks for your request, we'll put them shortly.

glassesjacketshirtman commented 6 years ago

The way we solved this issue is by running yarn add babel-runtime@6.26.0.

stefanneculai commented 6 years ago

@glassesjacketshirtman is there anything we could do to the package to avoid running this command?

glassesjacketshirtman commented 6 years ago

@stefanneculai you might want to refer to this issue I believe what's happening is that your bundled code is referring to an old version of babel-runtime. You can probably just upgrade your bundler to the latest and rebuild your package and all should work fine.

Pyro979 commented 5 years ago

@vopdoo Does this resolve your issue (it did mine)? https://github.com/froala/vue-froala-wysiwyg/issues/14

If so, @stefanneculai, you should probably update the doc to include that info

stefanneculai commented 5 years ago

Should be fixed in the latest master.

lxdDreamFuture commented 5 years ago

use "yarn" commend

yarn add vue-froala-wysiwyg
yarn add jquery

in your vue project 's root directory, create file vue.config.js

// vue.config.js
const webpack = require('webpack')
module.exports = {
    configureWebpack: {
        plugins: [
            new webpack.ProvidePlugin({
                $: 'jquery',
                jQuery: 'jquery',
                'windows.jQuery': 'jquery'
            })
        ]
    }
}

you don't need setting for loading the css files if you use vue3

other config is the same as vue2, just look for doc

liuguangyong93 commented 5 years ago

@vopdoo Why dont use version 3.0+ ??