♻️ (stacked note) simplify ini
This commit is contained in:
@@ -10,15 +10,13 @@ export const useQueryStackedNotes = () => {
|
|||||||
const { query } = useRoute()
|
const { query } = useRoute()
|
||||||
if (initial) {
|
if (initial) {
|
||||||
initial = false
|
initial = false
|
||||||
stackedNotes.value = query.stackedNotes
|
stackedNotes.value = Array.isArray(query.stackedNotes)
|
||||||
? Array.isArray(query.stackedNotes)
|
? (query.stackedNotes
|
||||||
? (query.stackedNotes
|
.map((n) => n?.toString())
|
||||||
.map((n) => n?.toString())
|
.filter((n) => !!n) as string[])
|
||||||
.filter((n) => !!n) as string[])
|
: ([query.stackedNotes]
|
||||||
: ([query.stackedNotes]
|
.map((n) => n?.toString())
|
||||||
.map((n) => n?.toString())
|
.filter((n) => !!n) as string[])
|
||||||
.filter((n) => !!n) as string[])
|
|
||||||
: ([] as string[])
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user