利用IntersectionObserver实现图片懒加载
摘要:1 import {useEffect} from 'react'; 2 let observer; 3 export default function useObserverHook(ele,callback,watch=[]) { 4 useEffect(()=>{ 5 const node=d
阅读全文
posted @
2020-12-18 17:20
小白学前端
阅读(188)
推荐(0) 编辑
think-react-store
摘要:think-react-store 基于 react hooks 和 context api 实现的类似的 redux 的数据管理库。支持数据存储,方法调用,可以在 class 组件和 function 组件中使用,支持同步和异步的方法调用。 https://github.com/cpagejs/t
阅读全文
posted @
2020-12-16 17:18
小白学前端
阅读(241)
推荐(0) 编辑
project-libs 一款常用函数集锦
摘要:project-libs 是一个常用函数集锦的工具库,包括浏览器、函数式、常用验证、cookie、数组处理等函数。 https://github.com/cpagejs/project-libs
阅读全文
posted @
2020-12-16 16:48
小白学前端
阅读(211)
推荐(0) 编辑