# cui-virtual-list-vue3
**Repository Path**: cqb325/cui-virtual-list-vue3
## Basic Information
- **Project Name**: cui-virtual-list-vue3
- **Description**: 虚拟列表vue3版本
- **Primary Language**: NodeJS
- **License**: MIT
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2023-12-27
- **Last Updated**: 2024-01-02
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
CUI-Virtual-List-Vue3
A simple vertical Virtual List based on vue3
[](https://www.npmjs.org/package/cui-virtual-list-vue3)
[](https://npmjs.org/package/cui-virtual-list-vue3)
[](https://npmjs.org/package/cui-virtual-list-vue3)

## Props
// fixed height of container, choose between height/maxHeight
height?: number
// max height of container, choose between height/maxHeight
maxHeight?: number
// item estimated size, use to initialization content height
itemEstimatedSize: number
// prev or next number of items to show
overscan?: number,
// list data
items: any[]
## Example
export const createArray = (count: number) => {
return new Array(count).fill(true).map(() => 1 + Math.round(Math.random() * 20))
};
export const ListItem = (props: any) : JSXElement => {
const style = {...props.style}
return
{new Array(props.item).fill(true).map(() => 'Row').join(" ")} Row {props.index}
}
ListItem.displayName = 'ListItem'
{ListItem}
## Install
# npm
npm install cui-virtual-list-vue3
# yarn
yarn add cui-virtual-list-vue3