wangEditor
wangEditor copied to clipboard
代码语言能支持yaml吗?
editorConfig.MENU_CONF['codeSelectLang'] = {
// 代码语言
codeLangs: [
{ text: 'html', value: 'html' },
{ text: 'java', value: 'java' },
{ text: 'bash', value: 'bash' },
{ text: 'python', value: 'python' },
{ text: 'sql', value: 'sql' },
{ text: 'css', value: 'css' },
{ text: 'xml', value: 'xml' },
{ text: 'javascript', value: 'javascript' },
{ text: 'jsx', value: 'jsx' },
{ text: 'php', value: 'php' },
{ text: 'c', value: 'c' },
{ text: 'c++', value: 'c++' },
{ text: 'c#', value: 'c#' },
{ text: 'go', value: 'go' },
{ text: 'ruby', value: 'ruby' },
{ text: 'swift', value: 'swift' },
{ text: 'markdown', value: 'markdown' },
{ text: 'yaml', value: 'yaml' },
]
}
目前yaml好像还是黑白的,没有高亮。
#https://github.com/wangeditor-team/wangEditor/issues/5721
editorConfig.MENU_CONF['codeSelectLang'] = { // 代码语言 codeLangs: [ { text: 'html', value: 'html' }, { text: 'java', value: 'java' }, { text: 'bash', value: 'bash' }, { text: 'python', value: 'python' }, { text: 'sql', value: 'sql' }, { text: 'css', value: 'css' }, { text: 'xml', value: 'xml' }, { text: 'javascript', value: 'javascript' }, { text: 'jsx', value: 'jsx' }, { text: 'php', value: 'php' }, { text: 'c', value: 'c' }, { text: 'c++', value: 'c++' }, { text: 'c#', value: 'c#' }, { text: 'go', value: 'go' }, { text: 'ruby', value: 'ruby' }, { text: 'swift', value: 'swift' }, { text: 'markdown', value: 'markdown' }, { text: 'yaml', value: 'yaml' }, ] }
目前yaml好像还是黑白的,没有高亮。
怎么使用在
标签中使用
@wangShiBoGT 标签?是引用吗
@wangShiBoGT标签?是引用吗
在pre标签中当成JSON数据那种展示
@wangShiBoGT标签?是引用吗
在pre标签中当成JSON数据那种展示
wangEditor 代码高亮就是用的 pre 标签包裹的呀