diff --git a/packages/eslint-plugin-react-hooks/src/RulesOfHooks.js b/packages/eslint-plugin-react-hooks/src/RulesOfHooks.js index 111cb054ad0ab..405a6641a335d 100644 --- a/packages/eslint-plugin-react-hooks/src/RulesOfHooks.js +++ b/packages/eslint-plugin-react-hooks/src/RulesOfHooks.js @@ -293,7 +293,7 @@ export default { // hook functions. const codePathFunctionName = getFunctionName(codePathNode); - // This is a valid code path for React hooks if we are direcly in a React + // This is a valid code path for React hooks if we are directly in a React // function component or we are in a hook function. const isSomewhereInsideComponentOrHook = isInsideComponentOrHook( codePathNode, @@ -422,7 +422,7 @@ export default { // false positives due to feature flag checks. We're less // sensitive to them in classes because hooks would produce // runtime errors in classes anyway, and because a use*() - // call in a class, if it works, is unambigously *not* a hook. + // call in a class, if it works, is unambiguously *not* a hook. } else if (codePathFunctionName) { // Custom message if we found an invalid function name. const message = @@ -476,7 +476,7 @@ export default { }; /** - * Gets tbe static name of a function AST node. For function declarations it is + * Gets the static name of a function AST node. For function declarations it is * easy. For anonymous function expressions it is much harder. If you search for * `IsAnonymousFunctionDefinition()` in the ECMAScript spec you'll find places * where JS gives anonymous function expressions names. We roughly detect the diff --git a/packages/react-reconciler/src/ReactChildFiber.js b/packages/react-reconciler/src/ReactChildFiber.js index 29e1a5c12939a..4fca72c2f6384 100644 --- a/packages/react-reconciler/src/ReactChildFiber.js +++ b/packages/react-reconciler/src/ReactChildFiber.js @@ -736,7 +736,7 @@ function ChildReconciler(shouldTrackSideEffects) { newChildren: Array<*>, expirationTime: ExpirationTime, ): Fiber | null { - // This algorithm can't optimize by searching from boths ends since we + // This algorithm can't optimize by searching from both ends since we // don't have backpointers on fibers. I'm trying to see how far we can get // with that model. If it ends up not being worth the tradeoffs, we can // add it later. diff --git a/packages/react-reconciler/src/ReactFiberHooks.js b/packages/react-reconciler/src/ReactFiberHooks.js index 1443fb544cdd1..ba7b556a1b95b 100644 --- a/packages/react-reconciler/src/ReactFiberHooks.js +++ b/packages/react-reconciler/src/ReactFiberHooks.js @@ -1009,7 +1009,7 @@ function updateMemo( let shouldWarnForUnbatchedSetState = false; if (__DEV__) { - // jest isnt' a 'global', it's just exposed to tests via a wrapped function + // jest isn't a 'global', it's just exposed to tests via a wrapped function // further, this isn't a test file, so flow doesn't recognize the symbol. So... // $FlowExpectedError - because requirements don't give a damn about your type sigs. if ('undefined' !== typeof jest) { diff --git a/packages/react-reconciler/src/ReactFiberScheduler.js b/packages/react-reconciler/src/ReactFiberScheduler.js index baa100f0d266a..de4fa2b0a053e 100644 --- a/packages/react-reconciler/src/ReactFiberScheduler.js +++ b/packages/react-reconciler/src/ReactFiberScheduler.js @@ -1455,7 +1455,7 @@ function renderRoot(root: FiberRoot, isYieldy: boolean): void { return; } else if ( // There's no lower priority work, but we're rendering asynchronously. - // Synchronsouly attempt to render the same level one more time. This is + // Synchronously attempt to render the same level one more time. This is // similar to a suspend, but without a timeout because we're not waiting // for a promise to resolve. !root.didError && diff --git a/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js b/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js index ec5ca92aa060b..0ed4014dfb29e 100644 --- a/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js +++ b/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js @@ -352,7 +352,7 @@ describe('ReactHooks', () => { ]); expect(root).toMatchRenderedOutput('0 (light)'); - // Updating the theme to the same value does't cause the consumers + // Updating the theme to the same value doesn't cause the consumers // to re-render. setTheme('light'); expect(root).toFlushAndYield([]); diff --git a/packages/react-reconciler/src/forks/ReactFiberErrorDialog.www.js b/packages/react-reconciler/src/forks/ReactFiberErrorDialog.www.js index 79befcb844d11..eb676a8afbce1 100644 --- a/packages/react-reconciler/src/forks/ReactFiberErrorDialog.www.js +++ b/packages/react-reconciler/src/forks/ReactFiberErrorDialog.www.js @@ -15,7 +15,7 @@ import invariant from 'shared/invariant'; const ReactFiberErrorDialogWWW = require('ReactFiberErrorDialog'); invariant( typeof ReactFiberErrorDialogWWW.showErrorDialog === 'function', - 'Expected ReactFiberErrorDialog.showErrorDialog to existbe a function.', + 'Expected ReactFiberErrorDialog.showErrorDialog to be a function.', ); export function showErrorDialog(capturedError: CapturedError): boolean { diff --git a/packages/scheduler/src/__tests__/SchedulerDOM-test.js b/packages/scheduler/src/__tests__/SchedulerDOM-test.js index 9cdec37285afc..77fac5ffe672d 100644 --- a/packages/scheduler/src/__tests__/SchedulerDOM-test.js +++ b/packages/scheduler/src/__tests__/SchedulerDOM-test.js @@ -140,7 +140,7 @@ describe('SchedulerDOM', () => { expect(callbackLog).toEqual(['A', 'B']); }); - it("accepts callbacks betweeen animationFrame and postMessage and doesn't stall", () => { + it("accepts callbacks between animationFrame and postMessage and doesn't stall", () => { const {unstable_scheduleCallback: scheduleCallback} = Scheduler; const callbackLog = []; const callbackA = jest.fn(() => callbackLog.push('A')); diff --git a/packages/shared/invokeGuardedCallbackImpl.js b/packages/shared/invokeGuardedCallbackImpl.js index 74ec54c871b0b..d3502063a5623 100644 --- a/packages/shared/invokeGuardedCallbackImpl.js +++ b/packages/shared/invokeGuardedCallbackImpl.js @@ -36,7 +36,7 @@ if (__DEV__) { // invokeGuardedCallback uses a try-catch, all user exceptions are treated // like caught exceptions, and the DevTools won't pause unless the developer // takes the extra step of enabling pause on caught exceptions. This is - // untintuitive, though, because even though React has caught the error, from + // unintuitive, though, because even though React has caught the error, from // the developer's perspective, the error is uncaught. // // To preserve the expected "Pause on exceptions" behavior, we don't use a