JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 31
  • Score
    100M100P100Q90152F
  • License MIT

Framework-agnostic, virtualized, single-item slider engine with zero dependencies

Package Exports

  • @reelkit/core
  • @reelkit/core/package.json

Readme

@reelkit/core

npm Bundle size Coverage Star on GitHub

The engine behind ReelKit — handles slider logic, gesture recognition, and transitions without depending on any UI framework. Ships its own signal-based reactive system so you don't need RxJS or similar.

Installation

npm install @reelkit/core

Quick Start

import { createSliderController } from '@reelkit/core';

const slider = createSliderController({
  count: 100,
  direction: 'vertical',
});

// Navigate
slider.next();
slider.prev();
slider.goTo(5);

// Read state via signals
console.log(slider.currentIndex.value); // 5

// Subscribe to changes
slider.currentIndex.subscribe((index) => {
  console.log('Slide changed:', index);
});

Features

  • Renders only 3 slides at a time (virtualized), handles 10,000+ items
  • Zero dependencies, ~7.4 kB gzip
  • Factory functions over classes — createSliderController, createGestureController, createKeyboardController, createWheelController
  • Built-in Signal, ComputedSignal, and reaction primitives for reactive state
  • Touch gestures with momentum and configurable thresholds
  • Keyboard and wheel navigation with debouncing
  • Infinite loop mode
  • Optional ResizeObserver-based auto-sizing
  • Strict TypeScript throughout

Documentation

API reference and guides at reelkit.dev.

Support

If ReelKit saved you some time, a star on GitHub would mean a lot — it's a small thing, but it really helps the project get noticed.

Star on GitHub

License

MIT