source: imaps-frontend/node_modules/eslint-plugin-react/lib/rules/no-will-update-set-state.js

main
Last change on this file was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago

Update repo after prototype presentation

  • Property mode set to 100644
File size: 441 bytes
Line 
1/**
2 * @fileoverview Prevent usage of setState in componentWillUpdate
3 * @author Yannick Croissant
4 */
5
6'use strict';
7
8const makeNoMethodSetStateRule = require('../util/makeNoMethodSetStateRule');
9const testReactVersion = require('../util/version').testReactVersion;
10
11/** @type {import('eslint').Rule.RuleModule} */
12module.exports = makeNoMethodSetStateRule(
13 'componentWillUpdate',
14 (context) => testReactVersion(context, '>= 16.3.0')
15);
Note: See TracBrowser for help on using the repository browser.