Skip to content

Commit

Permalink
Integrate alternative frontend (#166)
Browse files Browse the repository at this point in the history
The "step-by-step frontend" started as an educational project, but
became the playground to explore an alternative frontend design. It
reached the maturity to be integrated in the main branch. That's the
goal of this PR.

NOTE: The alternative frontend is contained in the folder named
`<repo>/frontend_v2/`.

---------

Co-authored-by: Sam Burdick <samuelmburdick@gmail.com>
  • Loading branch information
giangiac and smburdick authored Mar 5, 2024
1 parent eb7d8c8 commit 647fafa
Show file tree
Hide file tree
Showing 27 changed files with 20,072 additions and 0 deletions.
23 changes: 23 additions & 0 deletions frontend_v2/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
23 changes: 23 additions & 0 deletions frontend_v2/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
define INFO_MSG
----------------------
Install and launch the frontend app:

> npm install
> npm start

----------------------
A few useful commands:

Get the PID of the processes running on port 3000:
> lsof -i :3000

Kill the process given the PID:
> kill -9 PID

endef

export INFO_MSG
info:
@echo "$$INFO_MSG"

.PHONY: info
53 changes: 53 additions & 0 deletions frontend_v2/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Step-by-step coding of the frontend

Are you new to JavaScript, React and Pixi?
Do you want to contribute or simply understand the code powering the visual frontend of `tqecjs`?
Look no further.

In this folder we will re-build the frontend adding a few lines of codes at a time.
The commit message will make clear which functionality is added (or, at least, the goal is to have informative commits).

**NOTE:** The step-by-step frontend does not exactly match the official one in the `<repo>/frontend` folder.
This helps to better understand certain design choices while at the same time providing a playground for alternatives.



## Installation and execution

From this folder, install by typing:
```bash
npm start
```

Run the app in the development mode by typing:
```bash
npm start
```
Open [http://localhost:3000](http://localhost:3000) to view it in your browser.

The page will reload when you make changes.
You may also see any lint errors in the console.

Launch the test runner in the interactive watch mode.
```bash
npm test
```
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.

Build the app for production to the `build` folder:
```bash
npm run build
```
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!
See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.



## Learn More

You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).

To learn React, check out the [React documentation](https://reactjs.org/).
Loading

0 comments on commit 647fafa

Please sign in to comment.