Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

counter cdn

 <!-- jquery js -->
 <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
 <!-- waypoint js -->
 <script src="https://cdnjs.cloudflare.com/ajax/libs/waypoints/4.0.1/jquery.waypoints.min.js"></script>
 <!-- counter up2 js -->
 <script src="https://cdnjs.cloudflare.com/ajax/libs/counterup2/2.0.2/index.js"></script>

// counter up 2 js initialize
	jQuery(function ($) {
		'use strict';
		var counterUp = window.counterUp['default']; // import counterUp from "counterup2"
		var $counters = $('.counter');
		/* Start counting, do this on DOM ready or with Waypoints. */
		$counters.each(function (ignore, counter) {
			var waypoint = new Waypoint({
				element: $(this),
				handler: function () {
					counterUp(counter, {
						duration: 5000,
						delay: 16,
					});
					this.destroy();
				},
				offset: 'bottom-in-view',
			});
		});
	});




//counterup js plugin old version use this code 


//jquery cdn
<script src=" https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js "></script>

//waypoint cdn
<script src=" https://cdnjs.cloudflare.com/ajax/libs/waypoints/4.0.1/jquery.waypoints.min.js "></script>

//counterup cdn
<script src=" https://cdnjs.cloudflare.com/ajax/libs/Counter-Up/1.0.0/jquery.counterup.min.js "></script>

// counterup inint

	$('.counter1').counterUp({
      delay: 20,
      time: 1500,
    });

Comment

PREVIOUS NEXT
Code Example
Javascript :: How do I get the number of days between two dates in JavaScript 
Javascript :: how to get mouse x and y in javascript 
Javascript :: javascript knowing when space is pressed 
Javascript :: bootstrap modal title center 
Javascript :: javascript remove spaces at the beginning of the end of the string 
Javascript :: angular clone array without reference 
Javascript :: javascript int to float 
Javascript :: select first option in dropdown jquery 
Javascript :: disable sequelize logging 
Javascript :: jquery checkbox is checked 
Javascript :: javascript random number between 1 and 10 
Javascript :: disable eslint for line 
Javascript :: decimal parse thousand separator javascript 
Javascript :: on keyup jquery 
Javascript :: Uncaught TypeError: $(...).select2 is not a function 
Javascript :: javascript detect internet explorer 
Javascript :: E: Unable to locate package nodejs 
Javascript :: react simbu 
Javascript :: how to refresh slick after tab function 
Javascript :: display none js 
Javascript :: foreach document.getelementsbyclassname 
Javascript :: random number javascript 
Javascript :: javascript check if blank space 
Javascript :: bootstrap show modal on page load 
Javascript :: get window width jquery 
Javascript :: change id in jquery 
Javascript :: best way to detect mobile device jquery 
Javascript :: javascript angle equation of a line 
Javascript :: cypress set window size 
Javascript :: space between react native 
ADD CONTENT
Topic
Content
Source link
Name
9+4 =