Open this example in the interactive library
Source code
const entries: readonly (readonly [string, number])[] = [
["api", 2],
["web", 4],
];
console.log(((s: ReadonlySet<string>) => s.has("api"))(new Set(["api"])));
Sample output
true

Open this example in the interactive library
const entries: readonly (readonly [string, number])[] = [
["api", 2],
["web", 4],
];
console.log(((s: ReadonlySet<string>) => s.has("api"))(new Set(["api"])));
true