animere
Version:
CSS-driven scroll-based animations
24 lines (23 loc) • 697 B
TypeScript
import { animate, isCrawler, prefersReducedMotion } from './utils';
export interface AnimereOptions {
/**
* The prefix for `data` attributes
* @default 'animere'
*/
prefix?: string;
/**
* The ratio of intersection area (threshold) visible until an animation should appear
* @default 0.2
*/
offset?: number;
/**
* Custom handler to determine when to initialize Animere
* @default undefined
*/
shouldInitialize?: () => boolean;
}
export { animate, isCrawler, prefersReducedMotion };
/**
* CSS-driven scroll-based animations
*/
export declare function createAnimere({ prefix, offset, shouldInitialize, }?: AnimereOptions): void;