Rolling loading

tipjs,object,es6

Nguyên tắc là theo dõi các sự kiện cuộn trang và phân tích mối quan hệ thuộc tính giữa clientHeight , scrollTopscrollHeight .

window.addEventListener('scroll', function() {
  const clientHeight = document.documentElement.clientHeight;
  const scrollTop = document.documentElement.scrollTop;
  const scrollHeight = document.documentElement.scrollHeight;
  if (clientHeight + scrollTop >= scrollHeight) {
    // Xử lý ở đây
    // ...
  }
}, false);

Có thể bạn đã miss một số snippets code

jQuery on hover

Jquery on mouse over example.

So sánh hai array trong javascript

Làm thế nào để đánh giá xem hai mảng có bằng nhau không? Có hai cách đó là sử dụng JSON.stringify() hoặc toString()

Hàm lày ngày trong tuần javascript

Hàm lày ngày trong tuần javascript

encode/decode base64 with JS

Encoding to base64 is done with the btoa command

Lodash sort - Test performance with native js

Lodash sort - Bài viết ngắn gọn muốn đưa ra con số sau khi test về Lodash và Native js. Đây chỉ là check trên phương diện cá nhân...