You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

parallax-scroll-component

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

parallax-scroll-component

A smooth parallax scrolling component

1.0.4
latest
npm
Version published
Maintainers
1
Created
Source

Parallax Scroll Component

A smooth parallax scrolling component for modern web applications.

Installation

npm install parallax-scroll-component

Usage

import ParallaxScroll from 'parallax-scroll-component';

const images = [
  'path/to/image1.jpg',
  'path/to/image2.jpg',
  'path/to/image3.jpg'
];

const parallax = new ParallaxScroll('#container', {
  images: images,
  transitionDuration: 800, // optional, default 800ms
  easing: 'ease-in-out'   // optional, default 'ease-in-out'
});

// Programmatic control
parallax.next(); // Go to next slide
parallax.prev(); // Go to previous slide
parallax.goTo(1); // Go to specific index

Options

OptionTypeDefaultDescription
imagesArray[]Required. Array of image URLs
transitionDurationNumber800Animation duration in milliseconds
easingString'ease-in-out'CSS transition timing function

Methods

  • next(): Go to next slide
  • prev(): Go to previous slide
  • goTo(index): Go to specific slide index

License

MIT

Keywords

parallax

FAQs

Package last updated on 09 Jul 2025

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