attribute record element-ui

1, close-on-click-modal, use the time to pay attention to the binding property

<el-dialog
      title="上传"
      :close-on-click-modal="false"
    >
    </el-dialog>

Explanation: If the value is true, that you can close the pop-up box by clicking on the empty place; not to be false

2, el-form ref DOM element for acquiring the current

<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
    <el-form-item label="活动名称" prop="name">
    <el-input v-model="ruleForm.name"></el-input>
  </el-form-item>
</el-form>

We are rules here written validation rules for the form, but how we specified form to authenticate methods where we start to write a ref = "ruleForm" in el-form, we can use the methods in
this. $ refs.ruleForm.validate ((valid) => {}
such a method you write authentication rules specified form.

3, package.json inside the name value and not the name of the package you want to install, like
for example: name is express, and then you install npm install express --save will error

Guess you like

Origin blog.51cto.com/9161018/2447879