Skip to content

Latest commit

 

History

History
53 lines (36 loc) · 1.71 KB

README.md

File metadata and controls

53 lines (36 loc) · 1.71 KB

Dev Custom Methods

This repository contains custom methods that help you work with React, TypeScript, and Vite. These techniques will speed up your programming process and make your code easier to understand.

Installation

Run the following command to clone the repository:

git clone https://github.com/Rasulwebs/dev-custom-methods.git

React + TypeScript + Vite

Getting Started

First, run the development server:

npm run dev
# or
yarn dev

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

Currently, two official plugins are available:

Expanding the ESLint configuration

If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:

  • Configure the top-level parserOptions property like this:
export default {
  // other rules...
  parserOptions: {
    ecmaVersion: 'latest',
    sourceType: 'module',
    project: ['./tsconfig.json', './tsconfig.node.json'],
    tsconfigRootDir: __dirname,
  },
}
  • Replace plugin:@typescript-eslint/recommended to plugin:@typescript-eslint/recommended-type-checked or plugin:@typescript-eslint/strict-type-checked
  • Optionally add plugin:@typescript-eslint/stylistic-type-checked
  • Install eslint-plugin-react and add plugin:react/recommended & plugin:react/jsx-runtime to the extends list