Welcome to the React-ThreeJS EaselJS Drawing App โ a powerful tool for creating 2D and 3D visualizations! This app covers you whether you're looking to draw, manipulate shapes, or view objects in a 3D scene. Let's unleash your creativity! ๐โจ This is the perfect boilerplate to kickstart your drawing projects with React, ThreeJS, and EaselJS! ๐
react.threejs.easeljs.drawing-app.demo.mp4
https://react-threejs-easeljs.web.app/
- ๐จ Draw Shapes: Draw rectangles, circles, lines, and custom paths effortlessly with a click-and-drag interface.
- โ Shape Manipulation: Move, drag, and delete shapes as needed. Shapes adjust in real time for a smooth experience!
- ๐ 3D Viewer: Toggle between 2D and view-only 3D mode to see your drawings come to life in a new dimension.
- ๐จ Random Colors: Each shape you create is assigned a random stroke and fill color.
- โก Real-Time Updates: Watch your canvas update instantly as you interact with shapes.
- โจ๏ธ Keyboard Support: Delete selected shapes using the Delete or Backspace keys for quick editing.
This project is built using modern technologies:
- React โ๏ธ
- Three.js ๐
- EaselJS ๐จ
- Vite โก
- Lodash ๐ ๏ธ
- TypeScript ๐ง
- Firebase ๐ฅ
- SonarCloud ๐งช
The project relies on several key libraries:
React: A library for building user interfaces. Three.js: A powerful 3D engine for rendering the 3D view mode. EaselJS: A library for drawing and manipulating 2D shapes. Vite: A fast build tool for modern web development. Lodash: A utility library for working with arrays, objects, and more.
To start the project locally, fork the repo and follow these steps:
1. ๐ด Fork the repository
2. ๐ฅ Clone your forked repository
3. ๐ ๏ธ Run `yarn install` to install dependencies
4. ๐ Run `yarn dev` to start the local development server
The app will run on http://localhost:5173.
If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:
- Configure the top-level
parserOptionsproperty like this:
export default tseslint.config({
languageOptions: {
// other options...
parserOptions: {
project: ['./tsconfig.node.json', './tsconfig.app.json'],
tsconfigRootDir: import.meta.dirname,
},
},
})- Replace
tseslint.configs.recommendedtotseslint.configs.recommendedTypeCheckedortseslint.configs.strictTypeChecked - Optionally add
...tseslint.configs.stylisticTypeChecked - Install eslint-plugin-react and update the config:
// eslint.config.js
import react from 'eslint-plugin-react'
export default tseslint.config({
// Set the react version
settings: { react: { version: '18.3' } },
plugins: {
// Add the react plugin
react,
},
rules: {
// other rules...
// Enable its recommended rules
...react.configs.recommended.rules,
...react.configs['jsx-runtime'].rules,
},
})- โญ Star the repository
- ๐ ๏ธ Submit pull requests, report bugs, or suggest features
Feel free to reach out if you have any questions or need help:
- GitHub: https://github.com/mustafacagri
- Linkedin: @MustafaCagri
Made with โค๏ธ in ๐ Istanbul, using React โ๏ธ, Three.js ๐, EaselJS ๐จ, TypeScript ๐ง, Vite โก, and Lodash ๐ ๏ธ!