Home / File/ error.nested-hook-in-normal-function.js — react Source File

error.nested-hook-in-normal-function.js — react Source File

Architecture documentation for error.nested-hook-in-normal-function.js, a javascript file in the react codebase. 1 imports, 0 dependents.

File javascript TestingUtilities Fixtures 1 imports 1 functions

Entity Profile

Dependency Diagram

graph LR
  a6eb8e7f_a445_6269_a9bc_056aeb4e6b70["error.nested-hook-in-normal-function.js"]
  ac587885_e294_a1e9_b13f_5e7b920fdb42["react"]
  a6eb8e7f_a445_6269_a9bc_056aeb4e6b70 --> ac587885_e294_a1e9_b13f_5e7b920fdb42
  style a6eb8e7f_a445_6269_a9bc_056aeb4e6b70 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

// @validateNoDynamicallyCreatedComponentsOrHooks
import {useState} from 'react';

function createCustomHook(config) {
  function useConfiguredState() {
    const [state, setState] = useState(0);

    const increment = () => {
      setState(state + config.step);
    };

    return [state, increment];
  }

  return useConfiguredState;
}

export const FIXTURE_ENTRYPOINT = {
  fn: createCustomHook,
  isComponent: false,
  params: [{step: 1}],
};

Subdomains

Functions

Dependencies

  • react

Frequently Asked Questions

What does error.nested-hook-in-normal-function.js do?
error.nested-hook-in-normal-function.js is a source file in the react codebase, written in javascript. It belongs to the TestingUtilities domain, Fixtures subdomain.
What functions are defined in error.nested-hook-in-normal-function.js?
error.nested-hook-in-normal-function.js defines 1 function(s): createCustomHook.
What does error.nested-hook-in-normal-function.js depend on?
error.nested-hook-in-normal-function.js imports 1 module(s): react.
Where is error.nested-hook-in-normal-function.js in the architecture?
error.nested-hook-in-normal-function.js is located at compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/error.nested-hook-in-normal-function.js (domain: TestingUtilities, subdomain: Fixtures, directory: compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free