MCPcopy Create free account
hub / github.com/testing-library/react-testing-library / render

Method render

src/__tests__/stopwatch.js:26–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

24 clearInterval(this.timer)
25 }
26 render() {
27 const {lapse, running} = this.state
28 return (
29 <div>
30 <span>{lapse}ms</span>
31 <button onClick={this.handleRunClick}>
32 {running ? 'Stop' : 'Start'}
33 </button>
34 <button onClick={this.handleClearClick}>Clear</button>
35 </div>
36 )
37 }
38}
39
40const sleep = t => new Promise(resolve => setTimeout(resolve, t))

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected