跳至内容

useEntityScope

将“EntityCollection”操作的副作用范围化,并在卸载时自动删除

Usage

ts
TODO;

Type Definitions

typescript
import type { Entity, EntityCollection } from 'cesium';
import type { MaybeRefOrGetter } from 'vue';
export interface UseEntityScopeOptions {
    /**
     * The collection of Entity to be added
     * @default useViewer().value.entities
     */
    collection?: MaybeRefOrGetter<EntityCollection | undefined>;
}
/**
 * Make `add` and `remove` operations of `EntityCollection` scoped,
 * automatically remove `Entity` instance when component is unmounted.
 */
export declare function useEntityScope(options?: UseEntityScopeOptions): import("..").UseCollectionScopeReturn<Entity, any[], any[], any>;
//# sourceMappingURL=index.d.ts.map