@lls/typings 24.21.0 → 24.22.0-02234c55

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.
@@ -1,7 +1,16 @@
1
+ import type { AsyncLocalStorage } from 'node:async_hooks'
1
2
  import type { Polypad as PolypadType } from '@typings/polypad'
2
3
  import type { AnyFunction, TODO } from '@typings/utils'
3
4
  import type CheerioModule from 'cheerio'
4
5
 
6
+ type LlsNamespace = 'UNIVERSAL_VARS'
7
+ export type UniversalVars = {
8
+ NO_CACHE?: boolean
9
+ SSR_INIT_LOCATION?: string
10
+ FLAGS?: Record<string, TODO>
11
+ }
12
+ type Store = Map<LlsNamespace, (UniversalVars & Record<string, any>) | undefined>
13
+
5
14
  declare global {
6
15
  // https://stackoverflow.com/questions/35074713/extending-typescript-global-object-in-node-js
7
16
  var cheerio: typeof CheerioModule
@@ -19,13 +28,14 @@ declare global {
19
28
  }
20
29
  var WEBFLOW_NAVBAR: string | undefined
21
30
 
22
- var UNIVERSAL_VARS: Record<string, unknown> | undefined
31
+ var UNIVERSAL_VARS: UniversalVars
32
+ var llsStorageReady: AsyncLocalStorage<Store>
33
+ var llsStoragePromise: Promise<AsyncLocalStorage<Store>>
23
34
 
24
35
  namespace NodeJS {
25
36
  interface ProcessEnv {
26
37
  NODE_ENV: 'local' | 'development' | 'production'
27
38
  CONF_ENV: 'local' | 'development' | 'test' | 'preprod' | 'production' | 'prod'
28
- SSR_INIT_LOCATION?: string
29
39
  }
30
40
  }
31
41
  var bun: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lls/typings",
3
- "version": "24.21.0",
3
+ "version": "24.22.0-02234c55",
4
4
  "description": "types custom du monorepo",
5
5
  "main": "index.js",
6
6
  "keywords": [],