0.4.3 • Published 4 years ago

@yama-dev/js-random-module v0.4.3

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

RANDOM MODULE

Feature

It's a random action utility.

Demo

Installation,Download

Using

NPM Usage

# install npm.
npm install --save-dev @yama-dev/js-random-module
// import.
import RANDOM_MODULE from '@yama-dev/js-random-module';

Basic Standalone Usage

<div class="js-bg">
  <div class="js-bg-item">test-1</div>
  <div class="js-bg-item">test-2</div>
  <div class="js-bg-item">test-3</div>
  <div class="js-bg-item">test-4</div>
  <div class="js-bg-item">test-5</div>
</div>

<script src="./js-random-module.js"></script>
<script>
var RAM = new RANDOM_MODULE('.js-bg-item',{
  elemWrap: '.js-bg',
  durationX2: 3000,
  interval: 1000,
  intervalDeflection: 500,
  addClassName: ['is-active','is-current'],
  autoStart: true,
  preStartCount: 1,
  positionRandom: true,
  repeat: true
});
</script>

Dependencies

none


For Developer

Contribution

  1. Fork it ( https://github.com/yama-dev/js-random-module/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Develop

at Development

Install node modules.

$ npm install

Run npm script 'develop'

$ npm run develop

Run npm script 'production'

$ npm run production

Licence

MIT

Author

yama-dev