# survey-editer

## Project setup
```
yarn install
```

### Compiles and hot-reloads for development
```
yarn serve
```

### Compiles and minifies for production
```
yarn build
```

### Lints and fixes files
```
yarn lint
```

### Customize configuration
See [Configuration Reference](https://cli.vuejs.org/config/).

### 组件使用

#### 题型列表 ToolBox

```
 <ToolBox :width="400"></ToolBox>
 属性：
 width: 宽度样式
```

```
import Creator from 'dsurvey-editor'

Vue.use(Creator, {
  locale: 'zh_CN',
  messages: {  // 定制化国际化
    en_US: {
      editor: {
        qtype07: '单选题',
        edit46: '231321'
      },
      question: {
        field06: '单选题'
      }
    }
  }
})

<!-- 切换语言 -->

this.$editorLang = 'en_US'
```

vue 页面引入creator
``` 
  <survey-toolbox>
  </survey-toolbox>
     <survey-editor v-if="testData" :disabled="false"  :surveyModel="testData" :surveyConfig="config"/>
```