get-client-xy
TypeScript icon, indicating that this package has built-in type declarations

2.0.0 • Public • Published

get-client-xy

Get coordinates from a mouse or touch event.

NPM Badge

Install

npm install get-client-xy

Usage

const getClientXY = require("get-client-xy")

const [x, y] = getClientXY(event)

API

getClientXY(event)

event

Type: MouseEvent | TouchEvent

The event to extract the data from.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 2.0.0
    0
    • latest

Version History

Package Sidebar

Install

npm i get-client-xy

Weekly Downloads

533

Version

2.0.0

License

MIT

Unpacked Size

2.56 kB

Total Files

5

Last publish

Collaborators

  • dfcreative
  • richienb
  • dy