MCPcopy Create free account
hub / github.com/Bytez-com/docs / constructor

Method constructor

docs/scripts/generatePages/Component.js:2–6  ·  view source on GitHub ↗
({ name, props = {}, children = [], textContent })

Source from the content-addressed store, hash-verified

1class Component {
2 constructor({ name, props = {}, children = [], textContent }) {
3 this.name = name;
4 this.props = props;
5 this.children = children;
6 }
7
8 toString(indent = 1, depth = 0) {
9 const props = Object.entries(this.props).map(([key, value]) => {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected