(getCLS, setCLS)
| 145 | } |
| 146 | |
| 147 | function getServeCallbacks(getCLS, setCLS) { |
| 148 | return function serve(req, res) { |
| 149 | setCLS(Math.random()); |
| 150 | setTimeout(() => { |
| 151 | readFile(__filename, () => { |
| 152 | if (res.destroyed) return; |
| 153 | res.setHeader('content-type', 'application/json'); |
| 154 | res.end(JSON.stringify({ cls: getCLS() })); |
| 155 | }); |
| 156 | }, 10); |
| 157 | }; |
| 158 | } |
| 159 | |
| 160 | const types = { |
| 161 | 'async-resource': buildCurrentResource, |
nothing calls this directly
no test coverage detected
searching dependent graphs…