在實際需求中,往往需要限制input輸入字符串長度,在iview中和h5中的input有很大區別
1.在h5中input限制字符輸入長度
<input type="text" name="fullname" maxlength="15" />
2.在iview中限制字符輸入長度
<Input placeholder="請輸入..." :maxlength="14" v-model="message" ></Input>
總結:在這裏容易受到主關影響,在iview中也直接maxlength=“15”不加前面冒號,就會報一下錯。在這總結一下。