jQuery Plugin For Custom Snowfall Effect - letItSnow.js

jQuery Plugin For Custom Snowfall Effect - letItSnow.js
File Size: 8.73 KB
Views Total: 3712
Last Update:
Publish Date:
Official Website: Go to website
License: MIT
   

letItSnow.js is an extremely lightweight jQuery plugin that adds a customizable snowfall effect to your winter or Christmas themed webpage.

How to use it:

1. Include jQuery library and the jQuery letitsnow.js plugin on the webpage.

<script src="//code.jquery.com/jquery-1.11.3.min.js"></script>
<script src="src/letItSnow.js"></script>

2. Include jQuery UI library for additional easing effects.

<script src="//code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>

3. Create an empty element for the snowfall effect.

<div id="snowspawner"></div>

4. Initialize the plugin to generate a default snowfall effect on the webpage.

$('#snowspawner').letItSnow();

5. Customize the snowfall effect with the following options.

$('#snowspawner').letItSnow({

  // color of the snowflakes
  color: '#fff',

  // max / min size
  size_min: 1,
  size_max: 5,

  // z-index
  zindex: 99999,

  // max amount of snowflakes
  maxcount: 100,

  // horizontal movement of snowflakes
  wind: 250,

  // easing effects
  easing_x: "easeInBack",
  easing_y: "easeInCubic",

  // aniamtion speed
  fall_time: 10000
  
});

This awesome jQuery plugin is developed by M1nified. For more Advanced Usages, please check the demo page or visit the official website.