diff --git a/src/radio/README.md b/src/radio/README.md index 82b620541..e25553b92 100644 --- a/src/radio/README.md +++ b/src/radio/README.md @@ -18,18 +18,19 @@ app.use(RadioGroup); Use `v-model` to bind the name of checked radio. ```html - + Radio 1 Radio 2 ``` ```js +import { ref } from 'vue'; + export default { - data() { - return { - radio: '1', - }; + setup() { + const checked = ref('1'); + return { checked }; }, }; ``` @@ -37,7 +38,7 @@ export default { ### Horizontal ```html - + Radio 1 Radio 2 @@ -46,7 +47,7 @@ export default { ### Disabled ```html - + Radio 1 Radio 2 @@ -55,7 +56,7 @@ export default { ### Custom Shape ```html - + Radio 1 Radio 2 @@ -64,7 +65,7 @@ export default { ### Custom Color ```html - + Radio 1 Radio 2 @@ -73,7 +74,7 @@ export default { ### Custom Icon Size ```html - + Radio 1 Radio 2 @@ -84,7 +85,7 @@ export default { Use icon slot to custom icon ```html - + Radio 1