Skip to content

Commit a04ec10

Browse files
committed
Add useCurrent documentation
1 parent 93297a7 commit a04ec10

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

README.md

+16
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,22 @@ Clicking the *Today* button will set the calendar view and set the date to `now`
171171

172172

173173

174+
#### useCurrent
175+
176+
Default: `false`
177+
178+
Accepts: `bolean`, 'year', 'month', 'day', 'hour', 'minute'
179+
180+
```handlebars
181+
{{bs-datetimepicker date=myDate useCurrent='day'}}
182+
```
183+
184+
If the date is not set, the first time the widget opens will set the date
185+
to current moment (if `true`). Granularity can be specified as a `string`.
186+
187+
188+
189+
174190
#### viewMode
175191

176192
Default: `days`

0 commit comments

Comments
 (0)