An open API service indexing awesome lists of open source software.

https://github.com/srijan-petwal/hello-cocco

my experiments and learnings with threeJs and react-three/fibre. Follow the link below.
https://github.com/srijan-petwal/hello-cocco

blender react reactthree reactthreefiber threejs

Last synced: about 1 month ago
JSON representation

my experiments and learnings with threeJs and react-three/fibre. Follow the link below.

Awesome Lists containing this project

README

          

# πŸ§šβ€β™€οΈ Cocco's World (More like Hello worldπŸ˜„)
>[!IMPORTANT]
> πŸ§ͺ A playground of experiments and learnings with `Three.js`, `React Three Fiber`, and `Blender`.
> A journey into the world of interactive 3D experiences β€” one scene at a time.

#### Docker Hub repo
[![Docker Image](https://img.shields.io/badge/Docker%20Hub-cocco--world-blue?logo=docker)](https://hub.docker.com/repository/docker/srijan5/cocco-world/general)

---

## πŸ“Έ Screenshots

### 🧚 Scene Preview
![Scene Preview-1](ScreenShot-2.png)
![Scene Preview-2](CoccoWorld.png)

---

### 🌐 **Live Demo with Netlify**
πŸš€ [coccos-world.netlify.app](https://coccos-world.netlify.app)

## ☁️ **Live Demo with AWS EC2 Deployment**
>[!NOTE]
> πŸš€ **Now hosted on a custom EC2 instance via Docker!**
> This deployment showcases my growing expertise in DevOps β€” moving beyond platforms like Netlify for a more hands-on infrastructure experience.

πŸ”— [http://16.171.199.186:3000](http://16.171.199.186:3000)
_(Hosted on AWS EC2 β€” may take a few seconds to wake up if idle)_

---

### EC2- Instance Screenshot

![EC2 Dashboard](EC2-instance.png)

---

### πŸ’‘About Why AWS EC2 Deployment?

- πŸ› οΈ To **learn and practice real-world deployment**.
- 🐳 Run the app inside a **Docker container** on a **Linux VM**.
- πŸ” Handle **firewall settings, ports, and SSH access** manually.
- 🌍 Gain **deeper insight** into how full-stack apps run on the cloud.

---

### πŸ§ͺ Tech Stack Used

- Amazon EC2 (Ubuntu)
- Docker (Containerized deployment)
- Public IP with exposed port `3000`

---

### πŸ“¦ Deployed Container Command

```bash
docker run --restart=always -p 3000:3000 srijan5/cocco-world

```

## πŸŽ₯ Project Videos

### πŸ”Ή Demo 1: Scene Interaction Preview
[🎞️ Watch Demo 1](https://youtu.be/G2m8G8DD-as)

### πŸ”Ή Demo 2: Animation + Tweak Controls
[🎬 Watch Demo 2](https://youtu.be/UJzaEgI9rnQ)

>[!NOTE]
>Credit for all the pre-built models goes to their respective creaters.I tweaked them, gave some of them animations and optimized them a bit. All of them are under various free-use licenses.

---

## 🧠 About

This project is my personal **3D lab** β€” a place where I explore:

- 🎨 Loading and animating **Blender models**
- πŸŒ€ Creating smooth interactions using **React Three Fiber**
- πŸ’‘ Playing with lighting, materials, cameras, shadows, and scene depth
- πŸ” Learning best practices for structuring 3D components in React

>[!NOTE]
> If it's 3D and on the web, this is where I tinker with it!

---
## πŸš€ Tech Stack

| Frontend | 3D/Rendering | Assets |
|----------|--------------|--------|
| `React.js` | `Three.js` | `Blender (GLTF)` |
| `React Three Fiber` | `Drei` | `Custom shaders` *(LEARNINGπŸ§“)* |
| `JavaScript (ES6)` | `Canvas/WebGL` | β€” |

---

## πŸ› οΈ How to Run Locally(try playing with it yourself)

```bash
git clone https://github.com/Srijan-Petwal/hello-cocco.git
cd coccos-world
npm install
npm run dev

```
---

## 🐳 Now Runs in Docker!

>[!TIP]
> You can now run the entire project inside a Docker container β€” no need to install Node, Vite, or any dependencies manually.
>This makes previewing the project locally much easier and cleaner. Ideal for sandbox testing, sharing, or running in isolated environments.
---

## 🧰 What It Takes to Run Locally with Docker

To run this project locally using Docker, you need just a few things set up:

#### βœ… Prerequisites

- **Docker Desktop installed**
β†’ [Download Docker](https://www.docker.com/products/docker-desktop)
- **Working internet connection** (for the first-time image pull)

---

#### πŸš€ Steps to Run in Docker

```bash
# Pull and run the container
docker run -it -p 3000:3000 srijan5/cocco-world
```