New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

vue-codeditor

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue-codeditor

Multi-language vue js code editor component running on the browser.

latest
Source
npmnpm
Version
1.0.5
Version published
Weekly downloads
202
-12.17%
Maintainers
1
Weekly downloads
 
Created
Source

vue-codeditor

Multi-language vue js code editor component running on the browser.

Project setup

npm install vue-codeditor

Usage

Import vue-codeditor component
// main.js

import Vue from "vue"
import App from "./App.vue"
import vueCodeditor from "vue-codeditor";

Vue.component(vueCodeditor)
Usage in other components
<!-- App.vue -->

<template>
  <div id="app">
    <!-- 
        * Can be used in the loop (for multiple editor components)
        * Each component must have its own content value.
    -->
    <vue-codeditor v-model="content" mode="javascript" theme="chrome" />

    <!-- 
        * If you want it to be readonly, you should use "readonly='true'" directly!
    -->
    <vue-codeditor v-model="content2" mode="html" theme="monokai" readonly="true"/>
  </div>
</template>

<script>
export default {
  name: "App",
  data() {
    return {
      content: "console.log('Hello world!')",
      content2: "<h1>Hello world!</h1>",
    };
  },
};
</script>

Available Props

PropDefaultTypeDescription
modejavascriptStringoptional - ace mode(s)
themechromeStringoptional - ace theme(s)
readonlyfalseBooleanoptional

License

MIT

Copyright (c) 2020-present, Ömer Çelik

Keywords

vue js

FAQs

Package last updated on 13 Jan 2021

Did you know?

Socket

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