@aicdev/snowflakejs

0.0.3 • Public • Published

snowflakeJS

Description

With snowflakeJS you can easily let it snow on your webpage. There is no need for special css or canvas, just pure javascript.

Live demo

Demo

Screenshot

Preview: alt text

How to use when you clone/checkout this repository

If you check it out from this repository please run "yarn install" to install all necessary dependencies. After that you can run "yarn build" to create a production bundle or "yarn start" to launch a webservice on port 8080 and see snowflakeJS in action.

How to use from snowflake.min.js

Incluse the snowflake.min.js (located in dist folder) file in your webpage. After that you can use it like follow:

 <script type="text/javascript" src="snowflake.min.js"></script></head>
const snowflake = new SnowflakeJs(25,250,5000,5,25);
snowflake.init();

Currently it comes as umd definition.

How to use when install with npm

It comes as es6 module. You can simply import it to your project.

import {SnowflakeJs} from "@aicdev/snowflakejs";

const snowflake = new SnowflakeJs();
snowflake.init();

Parameters in detail:

  • 25 = FPS
  • 250 = inital count of snowflakes
  • 5000 = lifetime in ms
  • 5 = max fall speed
  • 25 = max size of snowflake

LET IT SNOW.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.3
    698
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.3
    698
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i @aicdev/snowflakejs

Weekly Downloads

610

Version

0.0.3

License

Apache-2.0

Unpacked Size

412 kB

Total Files

16

Last publish

Collaborators

  • aicdev