Socket
Socket
Sign inDemoInstall

x-ace-editor.vue

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

x-ace-editor.vue

Vusion extension UI - AceEditor


Version published
Maintainers
1
Created
Source

XAceEditor

示例

基本用法

<x-ace-editor></x-ace-editor>

设置语言和主题

<template>
<x-ace-editor v-model="value" lang="json" theme="monokai"></x-ace-editor>
</template>
<script>
import 'brace';
import 'brace/mode/json';
import 'brace/theme/monokai';

export default {
    data() {
        return {
            value:
`{
    "name": "Alice",
    "age": 24,
    "phone": "18612345678"
}
`,
        };
    },
}
</script>

禁用

<x-ace-editor value="var i = 0;" disabled></x-ace-editor>

API

Props/Attrs

Prop/AttrTypeDefaultDescription
value.sync, v-modelAny当前选择的值
langString'text'设置语言
themeString设置主题
readonlyBooleanfalse是否只读
disabledBooleanfalse是否禁用
optionsObject配置项对象
autofocusBooleanfalse默认focus状态

Keywords

FAQs

Package last updated on 15 Nov 2019

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

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc