You will need a text editor to write your code. I recommend using Visual Studio Code with the Prettier extension, although you can choose whichever one you prefer.
Throughout this README, we will ask you to use various command-line interfaces (CLIs). You can type these commands into your system's default terminal:
- Windows: Command Prompt or PowerShell or WSL
- macOS: Terminal
- Linux: varies depending on distribution (e.g. GNOME Terminal, Konsole)
Most code editors also come with an integrated terminal, which you can also use.
Git is a commonly-used version control system for source code.
Although having git is not strictly necessary to download the code on your computer its the recommended way to do so.
Git will also became handy later if you want to make changes to the code base.
You need to install the Node.js runtime and its bundled npm package manager onto your system.
I recommend that you use the latest long-term support (LTS) version. The project was tested under the version 16.13.1.
Psss checkout Node Version Manger (nvm) if you want to manage multiples version on your system.
I personaly use Yarn for my package manager.
But you can use npm, simply replace yarn with npm when typing the yarn commands.
Within the directory of choice clone the following repository.
git clone git@github.com:Lukylix/LucasGarcia_12_04032022.git sport-see
If you want to use the api you can also clone the backend:
git clone git@github.com:OpenClassrooms-Student-Center/P9-front-end-dashboard.git sport-see-back
git clone https://github.com/Lukylix/LucasGarcia_12_04032022.git sport-see
If you want to use the api you can also clone the backend:
git clone https://github.com/OpenClassrooms-Student-Center/P9-front-end-dashboard.git sport-see-back
Moove into the previously cloned respositories and type:
yarn
You must edit the .env file before running the project like so :
VITE_API_HOST and VITE_API_PORT are optional in this configuration.
VITE_DATA_SOURCE=mock
VITE_API_HOST=localhost
VITE_API_PORT=3000
VITE_DATA_SOURCE=api
In the project directory, you can run:
Runs the app in the development mode.
Open http://localhost:8000 to view it in your browser.
The page will reload when you make changes.
You may also see any lint errors in the console.
Builds the app for production to the build
folder.
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. s Your app is ready to be deployed!
See the section about deployment for more information.
This command start a web server with the build
folder as the root directory.
This command formats all files supported by Prettier in the current directory and its subdirectories. It use .prettierignore file to ignore things that should not be formatted and .prettierrc.json for its styling configuration.