Registry / testing / eslint-plugin-twitch-core-ui

eslint-plugin-twitch-core-ui

JSON →
library24.0.1jsnpmunverified

An ESLint plugin providing custom lint rules for Twitch's Core UI library, version 24.0.1. It includes auto-fixable rules to enforce best practices and migrations within the Core UI component ecosystem. Key rules cover deprecation of legacy Button props, ref handler patterns, and styled layout components. The plugin ships with a recommended config for easy setup. Release cadence is tied to Core UI updates.

npm install eslint-plugin-twitch-core-ui
INSTALL
IMPORT
SIG · ESLINT-PLUGIN-TWIT
E
eslint-plugin-twitch-core-ui
testingjavascriptv24.0.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

plugin
import plugin from 'eslint-plugin-twitch-core-ui'
const plugin = require('eslint-plugin-twitch-core-ui')
ESM default import works with ESLint's plugin resolution.
rules
import { rules } from 'eslint-plugin-twitch-core-ui'
const { rules } = require('eslint-plugin-twitch-core-ui')
Named import for rules object, but typically you use the plugin directly.
configs
import { configs } from 'eslint-plugin-twitch-core-ui'
const { configs } = require('eslint-plugin-twitch-core-ui')
Access pre-built configs like 'recommended' via configs.recommended.

Shows how to enable the plugin using the recommended config or manually in an ESLint config file.

// .eslintrc.js module.exports = { extends: [ 'plugin:twitch-core-ui/recommended', ], rules: { // Override or add rules manually 'twitch-core-ui/no-styled-layout': 'error', }, };
Debug
Known issues
breakingRule no-deprecated-ref-handler-props may cause false positives for components not yet migrated.
fix
Add eslint-disable comments for specific lines or migrate the component to use ref prop.
affects: >=1.0.0
deprecatedStyledLayout and InjectStyledLayout are deprecated in Core UI; the lint rule enforces migration.
fix
Replace with Layout and InjectLayout respectively, autofix available.
affects: >=1.0.0
gotchaThe recommended config may enable rules not yet relevant to your project; review before extending.
fix
Instead of using recommended config, manually enable desired rules.
affects: >=1.0.0
Errors
Common errors & fixes
ESLint: Failed to load plugin 'twitch-core-ui' declared in '.eslintrc'
Plugin not installed as a dev dependency.
fix
Run npm install --save-dev eslint-plugin-twitch-core-ui
Definition for rule 'twitch-core-ui/no-deprecated-button-props' was not found
The rule name is misspelled or not loaded due to incorrect plugin reference.
fix
Check package name in plugins array, e.g., plugins: ['twitch-core-ui']
Upgrade
Version history
24.0.1latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
eslint-plugin-twitch-core-ui — npm install eslint-plugin-twitch-core-ui · libregistry