Files
bzzz/install/config-ui/node_modules/eslint-plugin-react/lib/rules/no-will-update-set-state.js
anthonyrawlins c177363a19 Save current BZZZ config-ui state before CHORUS branding update
🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-19 00:19:00 +10:00

16 lines
441 B
JavaScript

/**
* @fileoverview Prevent usage of setState in componentWillUpdate
* @author Yannick Croissant
*/
'use strict';
const makeNoMethodSetStateRule = require('../util/makeNoMethodSetStateRule');
const testReactVersion = require('../util/version').testReactVersion;
/** @type {import('eslint').Rule.RuleModule} */
module.exports = makeNoMethodSetStateRule(
'componentWillUpdate',
(context) => testReactVersion(context, '>= 16.3.0')
);