From 3fffe95614bcbc266d2c86920b1c834df64a0af2 Mon Sep 17 00:00:00 2001 From: Saiyam jain Date: Sun, 25 Oct 2026 02:28:02 +0530 Subject: [PATCH] fix: correct typos in user-facing invariant error messages These typos appear in runtime-thrown invariant messages that developers see when they misuse these APIs: - StateSafePureComponent.js: 'acceessed' -> 'accessed' ('this.state should not be acceessed during state updates') - CellRenderMask.js: 'number os cells' -> 'number of cells' ('CellRenderMask must contain a non-negative number os cells') --- packages/virtualized-lists/Lists/CellRenderMask.js | 2 +- packages/virtualized-lists/Lists/StateSafePureComponent.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/virtualized-lists/Lists/CellRenderMask.js b/packages/virtualized-lists/Lists/CellRenderMask.js index 8c7e110857e5..146b43e58542 100644 --- a/packages/virtualized-lists/Lists/CellRenderMask.js +++ b/packages/virtualized-lists/Lists/CellRenderMask.js @@ -23,7 +23,7 @@ export class CellRenderMask { constructor(numCells: number) { invariant( numCells >= 0, - 'CellRenderMask must contain a non-negative number os cells', + 'CellRenderMask must contain a non-negative number of cells', ); this._numCells = numCells; diff --git a/packages/virtualized-lists/Lists/StateSafePureComponent.js b/packages/virtualized-lists/Lists/StateSafePureComponent.js index e4e5cf6ead4f..e12fe1c8e185 100644 --- a/packages/virtualized-lists/Lists/StateSafePureComponent.js +++ b/packages/virtualized-lists/Lists/StateSafePureComponent.js @@ -74,7 +74,7 @@ export default class StateSafePureComponent< get() { invariant( !that._inAsyncStateUpdate, - '"this.state" should not be acceessed during state updates', + '"this.state" should not be accessed during state updates', ); return state; },