({
addFrame = () => undefined,
render = () => undefined,
on,
abort = () => undefined,
}: GifEncoderBuilderOptions = {})
| 538 | } |
| 539 | |
| 540 | export function buildGifEncoder({ |
| 541 | addFrame = () => undefined, |
| 542 | render = () => undefined, |
| 543 | on, |
| 544 | abort = () => undefined, |
| 545 | }: GifEncoderBuilderOptions = {}): GifEncoder { |
| 546 | const gif = new TestGifEncoder({ |
| 547 | addFrame, |
| 548 | abort, |
| 549 | render, |
| 550 | }); |
| 551 | |
| 552 | if (on) { |
| 553 | Object.defineProperty(gif, 'on', { |
| 554 | configurable: true, |
| 555 | value: on, |
| 556 | }); |
| 557 | } |
| 558 | |
| 559 | return gif; |
| 560 | } |
| 561 | |
| 562 | export function buildGifEncoderWithHandlers( |
| 563 | encoderOptions: GifEncoderWithHandlersBuilderOptions = {} |
no outgoing calls
no test coverage detected