king
2021-02-02 318642cd6837a38a4bf5dfe059bcbb6cafe3bca8
src/menu/components/code/sandbox/editorcode/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Icon, Modal, Tabs } from 'antd'
import { Icon, Modal, Tabs, message } from 'antd'
import zhCN from '@/locales/zh-CN/model.js'
import enUS from '@/locales/en-US/model.js'
@@ -63,6 +63,11 @@
  }
  onJsChange = (val) => {
    if (/document\.getElementsByTagName/g.test(val)) {
      message.warning('为防止代码冲突,js中不可使用document.getElementsByTagName方法!')
      return
    }
    this.setState({
      js: val
    })