semibran / rect

Basic helper methods for rectangles

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

rect

Basic helper methods for rectangles

The following methods can work on any objects of the form { x, y, width, height }.

install

npm install semibran/rect

usage

const { contains, intersects } = require('rect')

contains(a, b)

Determines if rectangle a contains rectangle b.

equals(a, b)

Determines if the four rectangle properties of a and b are equivalent.

license

MIT

About

Basic helper methods for rectangles

License:MIT License


Languages

Language:JavaScript 100.0%