This is a solution to the Browser extensions manager UI challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.
Users should be able to:
- Toggle extensions between active and inactive states
- Filter active and inactive extensions
- Remove extensions from the list
- Select their color theme
- View the optimal layout for the interface depending on their device's screen size
- See hover and focus states for all interactive elements on the page
- Website - Carla Johanna
- Frontend Mentor - @devcjoha
- X - @CarlitaJohanna
- Solution URL: code
- Live Site URL: Deploy Vercel
- Live Site URL: Deploy-Github-Pages
- React (component-based architecture).
- Vite (development and packaging).
- Functional components and hooks (useState, useEffect).
- Tailwind custom properties.
- Responsive design.
- Select light/dark theme.
- Toggle to enable or disable extensions.
- Filter extensions by activation.
- Detailed extensions, expanding the data.json file.
-
Local: Use
/as the base for routes. -
Production (GitHub Pages): Use
/reactjs-conference-ticket-generator/as the base.
# Ejecuta el proyecto en desarrollo local
npm run dev
# Build estándar (no recomendado para GitHub Pages)
npm run build
# Build para GitHub Pages (usa base name correcto)
npm run build:gh
# Vista previa del build
npm run preview-
The basename is dynamically configured using the
GITHUB_PAGESvariable. -
In local development: you don't need to define anything.
-
In production: the
build:ghscript automatically definesGITHUB_PAGES=true.
React Router requires the basename to match the site's base URL. This logic prevents errors such as:
<Router basename="/reactjs-conference-ticket-generator"> is not able to match the URL "/"Thanks to this configuration, you don't need to modify your code every time you change environments.
This project uses environment variables to manage paths and dynamic deployments. To maintain security and avoid conflicts, the actual .env files are excluded from the repository using .gitignore.
📄 Example File An .env.example file is included as a template:
# .env.example
VITE_BASE_URL=/
GITHUB_PAGES=false🛠️ How to Use It?
Copy the example file:
cp .env.example .env
Adjust the values according to your environment:
VITE_BASE_URL=/
GITHUB_PAGES=false
For production (GitHub Pages):VITE_BASE_URL=/reactjs-conference-ticket-generator/
GITHUB_PAGES=trueUse the scripts defined in package.json:
npm run dev # desarrollo local
npm run build:gh # build para GitHub Pages- Website - Carla Johanna
- Frontend Mentor - @devcjoha
- X - @CarlitaJohanna