build: build fix package publishing on JSR
[poolifier.git] / src / pools / pool.ts
index 1fa5b0f5e333a18c706d24705cc297b27d47d2ba..d7b6eeabeb074c31103854ec2f9789d137ff8409 100644 (file)
@@ -20,7 +20,10 @@ import type {
 /**
  * Enumeration of pool types.
  */
-export const PoolTypes = Object.freeze({
+export const PoolTypes: Readonly<{
+  fixed: 'fixed'
+  dynamic: 'dynamic'
+}> = Object.freeze({
   /**
    * Fixed pool type.
    */
@@ -39,7 +42,16 @@ export type PoolType = keyof typeof PoolTypes
 /**
  * Enumeration of pool events.
  */
-export const PoolEvents = Object.freeze({
+export const PoolEvents: Readonly<{
+  ready: 'ready'
+  busy: 'busy'
+  full: 'full'
+  empty: 'empty'
+  destroy: 'destroy'
+  error: 'error'
+  taskError: 'taskError'
+  backPressure: 'backPressure'
+}> = Object.freeze({
   ready: 'ready',
   busy: 'busy',
   full: 'full',