How to Integrate MonRect Into Your Project — Step‑by‑StepMonRect is a lightweight library (or component) designed to simplify rectangle-related operations such as collision detection, layout calculations, hit‑testing, and bounding‑box management. This step‑by‑step guide walks you through integrating MonRect into your project, from choosing the right distribution to advanced usage patterns and performance tips.
1. Choose the right MonRect package for your environment
MonRect may be distributed in several forms (check your project needs):
- npm package for Node.js or browser bundlers (Webpack, Vite, Parcel).
- ESM module for modern environments that support import/export.
- UMD build for direct inclusion via a