@posisung/use-scroll
v1.0.2
Published
x,y의 좌표값을 쉽게 구해주는 커스텀 훅
Downloads
4
Readme
@posisung/use-scroll
x,y의 좌표값을 쉽게 구해주는 커스텀 훅
Installation
npm
npm i @posisung/use-scroll
Usage
import React from "react";
import useScroll from "@posisung/use-scroll";
function App() {
const { currentX, currentY } = useScroll();
return (
<h1>
We are in: {currentX} / {currentY}
</h1>
);
}