🌐 AI搜索 & 代理 主页
Skip to content

Datepicker doesn't update value without hovering over it #4827

@RuneHanssens

Description

@RuneHanssens

Describe the bug

When the v-model of the datepicker changes externally, it doesn't update the displayed value untill you hover over it. By default I initialize the v-model to new Date() but in some cases I will overwrite this value by something I fetch from my API.

I worked like this:

<b-form-datepicker
              id="datepicker"
              v-model="date"
              value-as-date
              required
></b-form-datepicker>
@Component
export default class MyComponent extends Vue {
private date = new Date();
...
async mounted() {
    if ( ... ) {
      this.date = await ...
    }
  }
}

Expected behavior

The datepicker should update when it's v-model updates.

Versions

Libraries:

  • BootstrapVue: 2.5.0
  • Bootstrap: 4.4.1
  • Vue: 2.6.11

Environment:

  • Browser: Chrome

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions