Skip to content

kreattixcom/react-template

Repository files navigation

React + TypeScript Template Repository

This repository serves as a clean and reusable template for React projects built with TypeScript. It includes essential configurations and an example to help you get started quickly.

Features

  • React: A JavaScript library for building user interfaces.
  • TypeScript: Strongly typed JavaScript for better developer experience.
  • Redux Toolkit: Integrated state management with an example counter feature.
  • React Router: Preconfigured routing for navigation.
  • Prettier: Code formatting enforced for consistency.
  • ESLint: Static code analysis to find and fix issues.

Getting Started

Prerequisites

Ensure you have the following installed:

Using the Template

  1. Click on the "Use this template" Button At the top-right area of the GitHub repository page, click the "Use this template" button to create a new repository based on this template.

  2. Clone Your New Repository

    git clone <your-repository-url>
    cd <your-repository-name>
  3. Install Dependencies

    npm install
    # or
    yarn install
    # or
    bun install
  4. Start the Development Server

    npm run dev
    # or
    yarn run dev
    # or
    bun run dev

    Your application will be running at http://localhost:5173.

Project Structure

.
├── src
│   ├── app         # Redux store setup
│   ├── features    # Feature-specific code (e.g., counter)
│   ├── pages       # Page components for routing
│   └── main.tsx   # Application entry point
├── eslint.config.json  # ESLint configuration
├── .prettierrc     # Prettier configuration
├── tsconfig.json   # TypeScript configuration
└── README.md       # Project documentation

Usage

Counter Example

This template includes an example counter component using Redux Toolkit. To see it in action:

  1. Navigate to the http://localhost:5173 in your application.
  2. Increment the counter using the buttons.

Contributing

Contributions are welcome! To contribute:

  1. Fork the repository.
  2. Create a new branch for your feature or fix.
  3. Submit a pull request with a detailed explanation of your changes.

License

This project is licensed under the MIT License.


Feel free to use this repository as a starting point for your projects. If you find it helpful, give it a star ⭐ and share it with others!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published