MCPcopy Create free account
hub / github.com/DavidHDev/react-bits / render

Method render

src/tailwind/TextAnimations/ASCIIText/ASCIIText.jsx:202–211  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

200 }
201
202 render() {
203 this.context.clearRect(0, 0, this.canvas.width, this.canvas.height);
204 this.context.fillStyle = this.color;
205 this.context.font = this.font;
206
207 const metrics = this.context.measureText(this.txt);
208 const yPos = 10 + metrics.actualBoundingBoxAscent;
209
210 this.context.fillText(this.txt, 10, yPos);
211 }
212
213 get width() {
214 return this.canvas.width;

Callers 3

renderMethod · 0.45
setMeshMethod · 0.45
renderMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected