Skip to content

Commit 3d92877

Browse files
authored
Update index.md
1 parent 14cd9f2 commit 3d92877

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

docs/index.md

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# react-input-auto-format
1+
If you've ever tried to make an input field that automatically formats as you type, you'll know it's actually a pain in the 🍑. That's right, a pain in the peach.
22

3-
A super simple input component that formats as you type.
3+
With this simple React component, you can create your own pattern using the `format` prop, start typing and witness the magic ✨
44

55
```HTML
66
<Input format="## - ## - ##">
@@ -22,13 +22,12 @@ Have fun:
2222
import Input from 'react-input-auto-format';
2323

2424
function Foo () {
25-
return <Input format="## - ## - ##" />;
25+
return <Input format="## / ##" />;
2626
}
2727
```
2828

29-
The `format` prop accepts a pattern. The `#` character represents any number or letter, and you can put whatever else you like in there.
29+
The `format` prop accepts any pattern - it's entirely up to you. Here's some inspiration:
3030

31-
### Examples:
3231

3332
| Style | Pattern | Result |
3433
| ------------ | ------------------ | ------------ |

0 commit comments

Comments
 (0)