-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #267 from digipolisantwerp/feature/locale-document…
…ation Added locale documentation
- Loading branch information
Showing
3 changed files
with
18 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,13 @@ | ||
``` | ||
<Calendar | ||
locale={"nl"} | ||
format={"DD/MM/YYYY"} | ||
onChange={(date) => console.log('date is ' + date)} | ||
/> | ||
``` | ||
|
||
If you want to use another locale (like e.g. Dutch) you have to manually import it. You can also choose to load more locales and define the right one via the `locale` prop. If no locales are defined React will fall back to English. | ||
|
||
```js static | ||
import 'moment/locale/nl'; | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters