From 0794aacdbf8b3a995cdbb49966c716cf8d6d224f Mon Sep 17 00:00:00 2001 From: Sathya Gunasekaran Date: Tue, 14 Nov 2023 16:59:10 +0000 Subject: [PATCH] Turn off validateNoSetStateInRender in babel-plugin There's false positives that we found in the Eslint plugin --- .../packages/babel-plugin-react-forget/src/HIR/Environment.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/packages/babel-plugin-react-forget/src/HIR/Environment.ts b/compiler/packages/babel-plugin-react-forget/src/HIR/Environment.ts index 40eca65b5e..f42f02b670 100644 --- a/compiler/packages/babel-plugin-react-forget/src/HIR/Environment.ts +++ b/compiler/packages/babel-plugin-react-forget/src/HIR/Environment.ts @@ -140,7 +140,7 @@ const EnvironmentConfigSchema = z.object({ * Validates that setState is not unconditionally called during render, as it can lead to * infinite loops. */ - validateNoSetStateInRender: z.boolean().default(true), + validateNoSetStateInRender: z.boolean().default(false), /** * Extension of validateNoSetStateInRender which also validates that setState is not