Skip to content

Commit

Permalink
chore: import with tree-shaking
Browse files Browse the repository at this point in the history
  • Loading branch information
wazolab committed Aug 13, 2024
1 parent 54ef658 commit 90a21a1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions components/LogItem.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script setup lang="ts">
import LazyComponent from 'v-lazy-component'
import _ from 'underscore'
import { compact, uniq } from 'underscore'
import type { Log, ObjType } from '~/libs/types'
import { objTypeFull } from '~/libs/types'
Expand All @@ -19,8 +19,8 @@ function objtypeFull(objtype: ObjType) {
}
function uniqHistoryIds(log: Log) {
return _.uniq(
_.compact([log.base, log.change])
return uniq(
compact([log.base, log.change])
.map((object) => ({ objtype: object.objtype, id: object.id })),
(object) => `${object.objtype}${object.id}`,
)
Expand Down

0 comments on commit 90a21a1

Please sign in to comment.