Disclaimer: This package is a not (yet) well tested beta version. If xou have feedback or orther inputs, don't hesitate to contact me.
This is a very small package with which you can create a simple Slide-Effect on your Website, similar to this preview. https://www.lea-moser.ch/slides_lea
- Install the package via your terminal
npm i slides_lea
- Import the package in your project JS file
const SLIDES = require('slides_lea');
- To check if it is installed properly run
If everything work's fine, you should see further instructions in your browser-console.
Requirements HTML & CSS
For a good unterstanding of how this package is supposed to work, check out the source code of the example on GitHub.
- The elements you want to apply the effect on should be placed directly into the body or a main container with a height of auto.
- The elements you want to apply the effect on should all at least have a height of 100vh.
- The elements have to be positioned absolute.
Run the following command and pass the correct items into the function.
SLIDES.init('[selector of your elements]');