Install OpenGeometry
Install the OpenGeometry package using your preferred package manager:Peer Dependencies
OpenGeometry requires Three.js for 3D rendering. Install it as a peer dependency:TypeScript Support
If you’re using TypeScript, install the Three.js type definitions:WebAssembly Setup
OpenGeometry uses WebAssembly for high-performance geometric computations. The WASM file needs to be initialized before you can use the library.Development Setup
During development, the WASM file will be loaded from yournode_modules directory. No additional configuration is needed.
Production Setup
For production builds, you’ll need to ensure the WASM file is accessible. Most modern bundlers (Vite, webpack, etc.) handle this automatically.Vite Configuration
Vite automatically handles WASM files. No additional configuration is required.Webpack Configuration
If using webpack 5+, add the following to yourwebpack.config.js:
Verify Installation
Create a simple test file to verify your installation:OpenGeometry uses WebAssembly which loads automatically. The shapes are ready to use immediately after import.
Next Steps
Now that you have OpenGeometry installed, you’re ready to create your first 3D geometry:Quickstart Guide
Follow the quickstart guide to create your first 3D shape