Skip to content

Commit acf95b5

Browse files
committed
improve update performance
1 parent d8c746b commit acf95b5

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/components/mdDatePicker/mdDatePicker.vue

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,11 @@
4141
<md-button class="md-current-date" @click.native="showMonthPicker">{{ locale.months[month.getMonth()] }} {{ month.getFullYear() }}</md-button>
4242

4343
<div class="md-datepicker-week-days">
44-
<span v-for="day in locale.shorterDays">{{ day }}</span>
44+
<span v-for="day in locale.shorterDays" v-once>{{ day }}</span>
4545
</div>
4646

4747
<div class="md-datepicker-days">
48-
<span class="md-empty" v-for="day in startOfMonth(month).getDay()"></span>
48+
<span class="md-empty" v-for="day in startOfMonth(month).getDay()" v-once></span>
4949

5050
<md-button
5151
class="md-icon-button"
@@ -55,7 +55,8 @@
5555
'md-today': isToday(day),
5656
'md-selected': isSelectedDay(day)
5757
}"
58-
@click.native="setDate(day)">
58+
@click.native="setDate(day)"
59+
v-once>
5960
{{ day }}
6061
</md-button>
6162
</div>

0 commit comments

Comments
 (0)