Counter.jsx — astro Source File
Architecture documentation for Counter.jsx, a javascript file in the astro codebase. 1 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR a7b63195_7841_e8c9_a5dc_63ce9c30965a["Counter.jsx"] d9988dd0_c044_f9d2_85cd_a31a0a2bdf80["react"] a7b63195_7841_e8c9_a5dc_63ce9c30965a --> d9988dd0_c044_f9d2_85cd_a31a0a2bdf80 style a7b63195_7841_e8c9_a5dc_63ce9c30965a fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import React, { useState } from 'react';
export default function Counter({ children, count: initialCount = 0, id }) {
const [count, setCount] = useState(initialCount);
const add = () => setCount((i) => i + 1);
const subtract = () => setCount((i) => i - 1);
return (
<>
<div id={id} className="counter">
<button className="decrement" onClick={subtract}>-</button>
<pre>{count}</pre>
<button className="increment" onClick={add}>+</button>
</div>
<div className="counter-message">{children}</div>
</>
);
}
Domain
Subdomains
Functions
Dependencies
- react
Source
Frequently Asked Questions
What does Counter.jsx do?
Counter.jsx is a source file in the astro codebase, written in javascript. It belongs to the E2ETesting domain, TestFixtures subdomain.
What functions are defined in Counter.jsx?
Counter.jsx defines 1 function(s): Counter.
What does Counter.jsx depend on?
Counter.jsx imports 1 module(s): react.
Where is Counter.jsx in the architecture?
Counter.jsx is located at packages/astro/e2e/fixtures/client-idle-timeout/src/components/Counter.jsx (domain: E2ETesting, subdomain: TestFixtures, directory: packages/astro/e2e/fixtures/client-idle-timeout/src/components).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free