README
Vue Bootstrap 4 DatetimePicker
Vue.js component for eonasdan-bootstrap-datetimepicker
JSFiddle
Demo onVersions
:point_right: If you are looking for the documentation of an older version then switch to respective version branch.
Package Version | Bootstrap CSS version | Underlying Library | API Docs (same for both) |
---|---|---|---|
4.x | 3.x | eonasdan-bootstrap-datetimepicker (Official) | Docs |
5.x | 4.x | pc-bootstrap4-datetimepicker (Fork) | Docs |
Features
- Reactive
v-model
value- You can change datepicker value programmatically
- Reactive config options
- You can change config options dynamically
- Component will watch for changes and apply them
- You are suggested to modify config via Vue.set
- Emits all possible events
- Works with vee-validate and other validation library
Requirements
- Bootstrap ^4 (only css)
- jQuery >=1.8.3
- Moment.js ^2.22
Installation
# npm
npm install vue-bootstrap-datetimepicker --save
# Yarn
yarn add vue-bootstrap-datetimepicker
Using Webpack?
- Webpack users need to configure ProvidePlugin
// webpack.config.js
plugins: [
new webpack.ProvidePlugin({
Vue: ['vue/dist/vue.esm.js', 'default'],
jQuery: 'jquery',
'window.jQuery': 'jquery',
$: 'jquery',
moment: 'moment',
}),
]
Using Laravel Mix?
- Update your
webpack.mix.js
file, ref
// webpack.mix.js
mix.autoload({
'jquery': ['