ph-position
v1.0.0-beta.0
Published
position boundary detect
Downloads
1
Readme
🚀 Welcome to your new awesome project!
This project has been created using webpack-cli, you can now run
npm i ph-position
import getPosition from 'ph-position'
const {offsetWidth,offsetHeight} = dom
const {x,y} = PhPosition({offsetWidth,offsetHeight},target.getBoundingClientRect(),{top:boolean,dir:vt|hr|''})
dom.style.cssText = `left:${x}px,top:${y}px`