Socket
Socket
Sign inDemoInstall

@honglm/ckeditor5-build-simple-upload

Package Overview
Dependencies
0
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @honglm/ckeditor5-build-simple-upload

The classic editor build of CKEditor 5 – the best browser-based rich text editor.


Version published
Maintainers
1
Created

Readme

Source

#CKEditor 5 classic editor with Simple Upload Adapter

##Quick start for NUXT.JS

First, install the build from npm:

yarn add @ckeditor/ckeditor5-vue;
yarn add @honglm/ckeditor5-build-simple-upload;

Create ckeditor.js in /plugins folder

import Vue from 'vue';
import CKEditor from '@ckeditor/ckeditor5-vue';

export default () =>{
    Vue.use(CKEditor);
}

In nuxt.config.js

plugins: [
    '@/plugins/ckeditor.js'
]

And use it in your pages:

<template>
	<div class="links">
	<ckeditor :editor="editor" v-model="editorData" :config="editorConfig"></ckeditor>
	</div>
</template>


<script>
import ClassicEditor from "@honglm/ckeditor5-build-simple-upload";
export default {
  components: {},
  data() {
    return {
      editor: ClassicEditor,
      editorData: "<p>Content of the editor.</p>",
      editorConfig: {
        simpleUpload: {
          // The URL that the images are uploaded to.
          uploadUrl: "http://example.com",

          // Enable the XMLHttpRequest.withCredentials property.
          withCredentials: true,

          // Headers sent along with the XMLHttpRequest to the upload server.
          headers: {
            "X-CSRF-TOKEN": "CSFR-Token",
            Authorization: "Bearer <JSON Web Token>"
          }
        }
      }
    };
  },
  mounted() {}
};
</script>

##NOTE: Rebuild: yarn run build -> npm publish

Keywords

FAQs

Last updated on 10 Jul 2020

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc