jQuery plugin to fade-in at random.
https://sutara79.github.io/jquery.random-fade-in/
- GitHub: Clone or download.
- npm:
npm i jquery.random-fade-in
- CDN (jsDelivr):
- jquery.random-fade-in.min.js: v1.3.3
<div class="box-container">
<div><!-- Wrapper (Required) -->
<p>foo</p><!-- Target to fade-in -->
</div>
<div>
<p>bar</p>
</div>
<div>
<p>baz</p>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.2.1.min.js"></script>
<script src="jquery.random-fade-in.min.js"></script>
.box-container div p {
display: none; /* Required */
}
$('.box-container').randomFadeIn();
name | type | default | description |
---|---|---|---|
1st arg | string, number | 'slow' |
Duration. Same to jQuery ".fadeIn()". |
2nd arg | boolean | true |
Whether to repeat. |
- jQuery: >=3.0.0 (because of XSS vulnerability)
- Browser: Chrome58, Firefox52, IE11, Edge14