PageSourceSearch

https://www.northalabamadumpsters.com/cp/resources/views/test_slot/slot/plugins/SignalSlot.js

js northalabamadumpsters.com collected 2026-10-04 01:32:30 UTC 1,100 bytes, 39 lines download raw bytes

1import { delay } from "../utils.js";
2import Slot from "../Slot.js";
3
4export default function SignalSlot(classDef) {
5    console.log("wrapped in SignalSlot");
6    return function(opts) {
7        classDef.call(this, opts);
8        console.log("signal slot invoked");
9
10        this.match = async handlers => {
11            for (;;) {
12                const [op, ...args] = await this.capture();
13                const handler = handlers[op] ?? null;
14                if (handler) {
15                    return handler(this, ...args);
16                }
17            }
18        };
19
20        this.expect = async (...ops) => {
21            for (;;) {
22                const [op, ...args] = await this.capture();
23                if (ops.includes(op)) {
24                    return [op, ...args];
25                }
26            }
27        };
28
29        this.broadcast = async (...args) => {
30            await Promise.all(
31                ([...this.children]).map(c =>
32                    c.answer(...args)));
33        };
34
35        this.emit = async (...args) => {
36            this.parent?.answer(...args);
37        };
38    };
39}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.