https://github.com/buttasam/nette-react-template
A ready-to-use template for building web apps with Nette, React/Typescript, and Tailwind. Just run it with Docker and start coding.
https://github.com/buttasam/nette-react-template
docker nette react tailwindcss typscript vite
Last synced: 9 months ago
JSON representation
A ready-to-use template for building web apps with Nette, React/Typescript, and Tailwind. Just run it with Docker and start coding.
- Host: GitHub
- URL: https://github.com/buttasam/nette-react-template
- Owner: buttasam
- License: mit
- Created: 2025-07-06T21:37:44.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-07-06T21:55:12.000Z (9 months ago)
- Last Synced: 2025-07-06T22:35:01.014Z (9 months ago)
- Topics: docker, nette, react, tailwindcss, typscript, vite
- Language: PHP
- Homepage:
- Size: 0 Bytes
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Nette React Template
This project is a ready-to-use starter template using the following technologies:
- Nette + Vite
- React + TypeScript
- Tailwind CSS v4
- MariaDB
It includes a Docker Compose setup designed for local development.
You donβt need to install anything manually β just run a few commands and youβre ready to go.
## π Quick start
> __Prerequisites:__ Docker + DockerΒ Compose
### Using Docker Compose
1. Start the stack:
```
docker compose up --build -d
```
2. Install PHP dependencies and Node modules
```
docker exec nette_react_template_php sh -c "composer install && npm install"
```
3. Launch the Vite dev server (frontend hotβreload)
```
docker exec -it nette_react_template_php npm run dev
```
- hit `q` + `enter` to stop dev server
π Application is running on http://localhost:8000/.
> __Note:__ Nette uses the dev server only when debug mode is enabled (no action needed it's default setup)
### ποΈ Prod build
Compile JS/CSS assets
```
docker exec nette_react_template_php npm run build
```
## Project structure
```
βββ app/ # application (presenters, templates, components)
βββ assets/ # React, Tailwind CSS, and other styles
βββ bin/ # scripts for command line
βββ config/ # configuration
βββ database/ # database seed script
βββ log/ # logged messages and errors
βββ temp/ # temporary files, cache
βββ tests/ # tests
βββ vendor/ # libraries installed by Composer
βββ www/ # public document root (index.php, built assets)
```
> __Note:__ docker compose up automatically seeds MariaDB on first run using database/init.sql.
> __Docs:__ See the [official Nette directory structure](https://doc.nette.org/en/application/directory-structure#toc-basic-project-structure) documentation for more details.
## Common Commands
### Stop containers
```
docker compose down
```
### Format code
```
docker exec nette_react_template_php composer format
```
### Database access
```
docker exec -it nette_react_template_mysql mysql -uroot -proot
```
or connect via database viewer (disable SSL)
### Remove docker volume with database data
```
docker volume rm nette-react-template_db_data
```