Skip to content

Instantly share code, notes, and snippets.

@tai221
tai221 / app.js
Created November 28, 2022 17:42 — forked from JeffreyWay/app.js
Swappable Heading example
class SwappableHeading {
constructor(element, headings = []) {
this.element = element;
this.headings = headings;
this.current = 1;
}
async swap() {
while (true) {
await this.wait(2000);