eslint-plugin-reanimated

[![NPM](https://img.shields.io/npm/v/eslint-plugin-reanimated)](https://www.npmjs.com/package/eslint-plugin-reanimated) [![CI & CD](https://github.com/wcandillon/eslint-plugin-reanimated/workflows/CI%20&%20CD/badge.svg)](https://github.com/wcandillon/esli

MIT 26 个版本
安装
npm install eslint-plugin-reanimated
yarn add eslint-plugin-reanimated
pnpm add eslint-plugin-reanimated
bun add eslint-plugin-reanimated
README

NPM

The goal of this plugin is to help you when writing animation worklets with Reanimated.

Installation

This plugin requires your project to use TypeScript (>=4.1.3).

yarn add eslint-plugin-reanimated --dev

External type declaration need to expose the @worklet JSDoc. In the case of react-native-redash, this is done starting version 16.0.6 (see js-function-in-worklet).

Example Configuration

The plugin relies on TypeScript compiler services to resolve types. You need to set your tsconfig.json file in your eslint configuration via parserOptions.

{
  "extends": "react-native-wcandillon",
  "plugins": ["reanimated"],
  "parserOptions": {
    "project": "./tsconfig.json"
  },
  "rules": {
    "reanimated/js-function-in-worklet": 2,
  }
}

Rules

版本列表
2.0.1 2023-08-21
2.0.0 2022-08-10
1.2.7 2022-06-27
1.2.6 2022-06-27
1.2.5 2022-06-26
1.2.4 2021-11-03
1.2.3 2021-10-31
1.2.2 2021-05-02
1.2.1 2021-03-02
1.2.0 2021-02-25
1.1.0 2021-02-02
1.0.14 2021-01-22
1.0.13 2021-01-22
1.0.12 2021-01-16
1.0.11 2021-01-16
1.0.10 2021-01-16
1.0.9 2021-01-16
1.0.8 2021-01-16
1.0.7 2021-01-16
1.0.6 2021-01-15
1.0.5 2021-01-15
1.0.4 2021-01-15
1.0.3 2021-01-11
1.0.2 2021-01-11
1.0.1 2021-01-11
1.0.0 2021-01-10