我对Vuetify的Datepicker有问题。我在nuxt环境中使用它。
我使用了以下代码:
<v-template>
<v-menu
ref="datePicker"
:close-on-content-click="false"
v-model="dateDialog"
:nudge-right="40"
:return-value.sync="date"
lazy
offset-y
full-width
min-width="290px"
>
<v-text-field
slot="activator"
v-model="date"
label="Datepicker"
prepend-icon="event"
readonly
></v-text-field>
<v-date-picker
v-model="date"
no-title
color="secondary"
:first-day-of-week="1"
:reactive="true"
>
<v-spacer></v-spacer>
<v-btn flat color="black" v-on:click="dateDialog = false">Close</v-btn>
</v-date-picker>
</v-menu>
</v-template>
<script>
export default {
name: 'TimePicker',
data() {
return {
date: '2019-01-15',
dateDialog: false,
};
}
}
</script>
一切正常。但是每次我打开对话框时,都会在控制台中收到以下警告:
[Vue warn]: The computed property "locale" is already defined as a prop.
found in
---> <VDatePickerDateTable>
<VPicker>
<VDatePicker>
<ThemeProvider>
<VMenu>
...
有人知道此警告的原因吗?我正在使用
"nuxt": "^2.1.0"
"vue": "^2.5.21"
"vuetify": "^1.3.14"