Star Wars Frontend
This is a Star Wars App that uses ViteJS, and TypeScript. This app consumes the Star Wars Backend API
Showcase
Prerequisites
Before running the application, make sure you have the following installed:
- Node.js (v20 or later)
- yarn (v1.22.19 or later)
Getting Started
Follow the steps below to get the application up and running on your local machine:
-
Clone the repository:
git clone https://github.com/vinibispo/starwars-frontend.git
-
Navigate to the project directory:
cd starwars-frontend
-
Install the dependencies:
yarn --frozen-lockfile
-
Start the development server:
yarn dev
This will start the development server and your app will be accessible at http://localhost:5173.
Available Scripts
In the project directory, you can run the following scripts:
yarn dev
: Starts the development server.yarn build
: Builds the production-ready app in thedist
directory.yarn preview
: Serves the production build locally for testing.yarn lint
: Runs the ESLint linter to check for code issues.yarn type-check
: Runs the TypeScript Check for code issues.
Project Structure
The project structure follows the standard setup of a ViteJS project with TypeScript:
โโโ index.html
โโโ package.json
โโโ public
โย ย โโโ _redirects
โโโ src
โย ย โโโ app.tsx
โย ย โโโ assets
โย ย โย ย โโโ background.jpg
โย ย โย ย โโโ character.svg
โย ย โย ย โโโ film.svg
โย ย โย ย โโโ planet.png
โย ย โย ย โโโ planet.svg
โย ย โย ย โโโ star-wars-theme-song.mp3
โย ย โย ย โโโ star.svg
โย ย โย ย โโโ wallpaper.png
โย ย โย ย โโโ wars.svg
โย ย โโโ hooks
โย ย โย ย โโโ characters.ts
โย ย โย ย โโโ films.ts
โย ย โย ย โโโ planets.ts
โย ย โย ย โโโ user.ts
โย ย โโโ main.tsx
โย ย โโโ pages
โย ย โย ย โโโ characters
โย ย โย ย โย ย โโโ id.tsx
โย ย โย ย โย ย โโโ index.tsx
โย ย โย ย โโโ films
โย ย โย ย โย ย โโโ id.tsx
โย ย โย ย โย ย โโโ index.tsx
โย ย โย ย โโโ home
โย ย โย ย โย ย โโโ index.tsx
โย ย โย ย โโโ planets
โย ย โย ย โย ย โโโ id.tsx
โย ย โย ย โย ย โโโ index.tsx
โย ย โย ย โโโ users
โย ย โย ย โโโ forgot-password.tsx
โย ย โย ย โโโ reset-password.tsx
โย ย โย ย โโโ shared
โย ย โย ย โย ย โโโ form.ts
โย ย โย ย โโโ signin.tsx
โย ย โย ย โโโ signup.tsx
โย ย โโโ resources
โย ย โย ย โโโ api.ts
โย ย โย ย โโโ schema
โย ย โย ย โย ย โโโ characters.ts
โย ย โย ย โย ย โโโ films.ts
โย ย โย ย โย ย โโโ planets.ts
โย ย โย ย โย ย โโโ user.ts
โย ย โย ย โโโ storage.ts
โย ย โโโ router.tsx
โย ย โโโ shared
โย ย โย ย โโโ card.tsx
โย ย โย ย โโโ contexts
โย ย โย ย โย ย โโโ auth-context.tsx
โย ย โย ย โโโ layout.tsx
โย ย โย ย โโโ navbar.tsx
โย ย โย ย โโโ pagination
โย ย โย ย โย ย โโโ arrow-left.tsx
โย ย โย ย โย ย โโโ arrow-right.tsx
โย ย โย ย โย ย โโโ index.tsx
โย ย โย ย โโโ styles.ts
โย ย โโโ ui
โย ย โย ย โโโ container.ts
โย ย โย ย โโโ sign-in.tsx
โย ย โย ย โโโ styles
โย ย โย ย โโโ global.ts
โย ย โย ย โโโ sign-out.tsx
โย ย โโโ vite-env.d.ts
โโโ tsconfig.json
โโโ tsconfig.node.json
โโโ vite.config.ts
โโโ yarn.lock
You can modify and extend the project structure to suit your needs.
Learn More
To learn more about the technologies used in this project, refer to the official documentation:
License
This project is licensed under the MIT License.
Contributing
Contributions are welcome! If you find any issues or have suggestions for improvement, please open an issue or submit a pull request.