@loudy/lib 0.0.0 → 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -4,6 +4,7 @@ declare class LoudLibElement {
4
4
  constructor(element: Element);
5
5
  element: Element;
6
6
  on(event: EventHandlers, fn: (e: Event) => void): this;
7
+ addClass(className: string): void;
7
8
  }
8
9
  type EventHandlers = { [K in Extract<keyof GlobalEventHandlers, `on${string}`>]: K extends `on${infer E}` ? E : never }[Extract<keyof GlobalEventHandlers, `on${string}`>];
9
10
  //#endregion
package/dist/index.mjs CHANGED
@@ -11,6 +11,9 @@ var LoudLibElement = class {
11
11
  this.element.addEventListener(event, fn);
12
12
  return this;
13
13
  }
14
+ addClass(className) {
15
+ this.element.classList.add(className);
16
+ }
14
17
  };
15
18
 
16
19
  //#endregion
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@loudy/lib",
3
3
  "type": "module",
4
- "version": "0.0.0",
4
+ "version": "0.0.1",
5
5
  "description": "library for various stuff.",
6
6
  "author": "loudsynth",
7
7
  "license": "MIT",