Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@reelkit/vue-reel-player

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@reelkit/vue-reel-player

Full-screen vertical-swipe video/image reel player for Vue 3, inspired by Instagram Reels and TikTok

latest
Source
npmnpm
Version
0.2.1
Version published
Maintainers
1
Created
Source

@reelkit/vue-reel-player

npm Bundle size Star on GitHub

Instagram Reels / TikTok-style video player for Vue 3. Opens as a full-screen overlay with vertical swipe navigation. Handles video autoplay, sound continuity on iOS, and multi-media posts. ~5.8 kB gzip.

Live Demo

Installation

npm install @reelkit/vue-reel-player @reelkit/vue lucide-vue-next

Quick Start

<script setup lang="ts">
import { ref } from 'vue';
import { ReelPlayerOverlay, type ContentItem } from '@reelkit/vue-reel-player';
import '@reelkit/vue-reel-player/styles.css';

const isOpen = ref(false);
const content: ContentItem[] = [
  {
    id: '1',
    media: [
      {
        id: 'v1',
        type: 'video',
        src: 'https://example.com/video.mp4',
        poster: 'https://example.com/poster.jpg',
        aspectRatio: 9 / 16,
      },
    ],
    author: { name: 'John Doe', avatar: 'https://example.com/avatar.jpg' },
    likes: 1234,
    description: 'Amazing video!',
  },
];
</script>

<template>
  <button @click="isOpen = true">Open Player</button>
  <ReelPlayerOverlay
    :is-open="isOpen"
    :content="content"
    @close="isOpen = false"
  />
</template>

Features

  • Vertical swipe navigation (touch, mouse, keyboard, wheel)
  • Video autoplay with sound toggle
  • Multi-media posts with horizontal nested slider
  • Instagram-style indicator dots
  • Keyboard navigation (Arrow keys, Escape)
  • Desktop navigation arrows
  • iOS sound continuity via shared <video> element
  • Video position memory across slide changes

Scoped Slots

All of the player's UI is customizable via scoped slots:

SlotScope
slideitem, index, size, isActive, slideKey, defaultContent, …
slideOverlayitem, index, isActive
controlsitem, soundState, activeIndex, content, onClose
navigationitem, activeIndex, count, onPrev, onNext
nestedSlideitem, media, index, size, isActive, isInnerActive, …
nestedNavigationmedia, activeIndex, count, onPrev, onNext
loadingitem, activeIndex
erroritem, activeIndex

Props

PropTypeDefaultDescription
isOpenbooleanrequiredControls overlay visibility
contentContentItem[]requiredContent items to display
initialIndexnumber0Starting slide index
aspectRationumber9/16Desktop container ratio
loopbooleanfalseEnable infinite loop
enableNavKeysbooleantrueEnable keyboard navigation
enableWheelbooleantrueEnable mouse wheel navigation
wheelDebounceMsnumber200Wheel debounce duration (ms)
transitionDurationnumber300Transition duration (ms)
swipeDistanceFactornumber0.12Swipe threshold (0-1)

Events

EventPayloadDescription
closevoidEmitted when player closes
slide-changenumberEmitted after slide change
api-readyReelApiEmitted with imperative API
update:is-openbooleanEmitted on close — enables v-model:is-open

v-model:is-open

Use it to drive the overlay with a single binding instead of pairing :is-open + @close:

<script setup lang="ts">
import { ref } from 'vue';
const open = ref(false);
</script>

<template>
  <button @click="open = true">Open</button>
  <ReelPlayerOverlay v-model:is-open="open" :content="content" />
</template>

The legacy :is-open + @close pattern still works.

Custom content types

ReelPlayerOverlay is generic over your content item shape. Extend BaseContentItem to use any data type, and import the slot-scope types to keep slot bindings strongly typed:

<script setup lang="ts">
import { ref } from 'vue';
import {
  ReelPlayerOverlay,
  type BaseContentItem,
  type SlideOverlaySlotScope,
} from '@reelkit/vue-reel-player';

interface MyItem extends BaseContentItem {
  title: string;
  category: 'video' | 'photo';
}

const open = ref(false);
const items: MyItem[] = [
  /* ... */
];
</script>

<template>
  <ReelPlayerOverlay v-model:is-open="open" :content="items">
    <template #slideOverlay="{ item }: SlideOverlaySlotScope<MyItem>">
      <div class="my-overlay">
        <h2>{{ item.title }}</h2>
        <span>{{ item.category }}</span>
      </div>
    </template>
  </ReelPlayerOverlay>
</template>

The same pattern works for every other slot — import the matching scope type (SlideSlotScope, ControlsSlotScope, NavigationSlotScope, NestedSlideSlotScope, LoadingSlotScope) and annotate the destructure.

Keyboard Shortcuts

KeyAction
ArrowUpPrevious slide
ArrowDownNext slide
ArrowLeftPrevious media (nested)
ArrowRightNext media (nested)
EscapeClose player

Documentation

Docs and interactive demos at reelkit.dev/docs/vue-reel-player.

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

Keywords

vue

FAQs

Package last updated on 27 Apr 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts