Skip to content

Commit f25d0b7

Browse files
refactor: use v-model trim modifier
1 parent 106902d commit f25d0b7

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

app/pages/index.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ function handleSubmit() {
77
router.push({
88
name: 'search',
99
query: {
10-
q: searchQuery.value.trim(),
10+
q: searchQuery.value,
1111
},
1212
})
1313
}
@@ -68,7 +68,7 @@ defineOgImageComponent('Default', {
6868
<input
6969
id="home-search"
7070
ref="searchInputRef"
71-
v-model="searchQuery"
71+
v-model.trim="searchQuery"
7272
type="search"
7373
name="q"
7474
:placeholder="$t('search.placeholder')"

0 commit comments

Comments
 (0)