瀏覽代碼

docs(x-model `.number` modifier)

Hugo 5 年之前
父節點
當前提交
7761fa32ad
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      README.md

+ 6 - 0
README.md

@@ -400,6 +400,12 @@ The `camel` modifier will attach an event listener for the camel case equivalent
 
 > Note: `x-model` is smart enough to detect changes on text inputs, checkboxes, radio buttons, textareas, selects, and multiple selects. It should behave [how Vue would](https://vuejs.org/v2/guide/forms.html) in those scenarios.
 
+**`.number` modifier**
+**Example:** `<input x-model.number="age">`
+
+The `number` modifier will convert the input's value to a number.
+
+
 **`.debounce` modifier**
 **Example:** `<input x-model.debounce="search">`