@boatzako/ngx-parallax-scroll
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

NgxParallaxScroll

License Minified

Parallax scroll for Angular9+. Demo

Getting Started

You can install @boatzako/ngx-parallax-scroll by using npm.

npm install @boatzako/ngx-parallax-scroll --save

Usage

Import ngx-parallax-scroll module

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { AppComponent } from './app.component';

import { NgxParallaxScrollModule } from '@boatzako/ngx-parallax-scroll'; // <-- add

@NgModule({
  imports: [
    BrowserModule, 
    NgxParallaxScrollModule  // <-- add
  ],
  declarations: [ 
    AppComponent,
  ],
  bootstrap: [ AppComponent ]
})
export class AppModule { }

Then in HTML

<ngx-parallax-scroll>
  <img parallax-img src="/assets/your-image.jpg" alt="">
</ngx-parallax-scroll>

API.

Component

Selector: ngx-parallax-scroll

Inputs

Input Type Default Required Description
styleClass string no Style class of the component.

Directive

Selector: parallax-img

Inputs

Input Type Default Required Description
ratio number 1 no speed when scrolling

Authors

License

This project is licensed under the MIT License - see the LICENSE file for details

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i @boatzako/ngx-parallax-scroll

      Weekly Downloads

      7

      Version

      1.0.0

      License

      MIT

      Unpacked Size

      96.4 kB

      Total Files

      27

      Last publish

      Collaborators

      • boatzako