feat: add preloadItemCount for List, incase we need preload more items before scroll to end
This commit is contained in:
@@ -88,8 +88,8 @@ export class List extends Superview {
|
||||
* @param from
|
||||
* @returns Returns the item of index which can dragged or not.
|
||||
*/
|
||||
@Property
|
||||
itemCanDrag?: (from: number) => boolean
|
||||
@Property
|
||||
itemCanDrag?: (from: number) => boolean
|
||||
|
||||
/**
|
||||
* @param from
|
||||
@@ -104,6 +104,9 @@ export class List extends Superview {
|
||||
@Property
|
||||
onDragged?: (from: number, to: number) => void
|
||||
|
||||
@Property
|
||||
preloadItemCount?: number
|
||||
|
||||
scrollToItem(context: BridgeContext, index: number, config?: { animated?: boolean, }) {
|
||||
const animated = config?.animated
|
||||
return this.nativeChannel(context, 'scrollToItem')({ index, animated, }) as Promise<any>
|
||||
|
Reference in New Issue
Block a user