⬅️ Back to Table of Contents
📄 demo.vue
📊 Analysis Summary
Metric |
Count |
🔧 Functions |
1 |
📦 Imports |
4 |
📊 Variables & Constants |
2 |
🟢 Vue Composition API |
1 |
📚 Table of Contents
🛠️ File Location:
📂 packages/core/useSorted/demo.vue
📦 Imports
Name |
Source |
rand |
@vueuse/core |
useSorted |
@vueuse/core |
computed |
vue |
shallowRef |
vue |
Variables & Constants
Name |
Type |
Kind |
Value |
Exported |
objArr |
{ name: string; age: number; }[] |
let/var |
`[{ |
|
name: 'John', |
|
|
|
|
age: 40, |
|
|
|
|
}, { |
|
|
|
|
name: 'Jane', |
|
|
|
|
age: 20, |
|
|
|
|
}, { |
|
|
|
|
name: 'Joe', |
|
|
|
|
age: 30, |
|
|
|
|
}, { |
|
|
|
|
name: 'Jenny', |
|
|
|
|
age: 22, |
|
|
|
|
}]` |
✗ |
|
|
|
arr |
any[] |
let/var |
[] |
✗ |
Vue Composition API
Name |
Type |
Reactive Variables |
Composables |
computed |
computed |
none |
none |
Functions
randomArr(): void
Code
function randomArr() {
const arr = []
for (let i = 0; i < rand(10, 20); i++)
arr.push(rand(0, 100))
arrText.value = arr.join(',')
}
- Return Type:
void
- Calls:
rand (from @vueuse/core)
arr.push
arr.join