@ctx-core/env 13.0.54 → 14.0.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @ctx-core/env
2
2
 
3
+ ## 14.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - \*\_b: ctx is a map: @ctx-core/object: 22.0.0
8
+
9
+ ### Patch Changes
10
+
11
+ - package.json: - module
12
+ - Updated dependencies
13
+ - Updated dependencies
14
+ - @ctx-core/object@22.0.0
15
+ - @ctx-core/error@11.1.9
16
+ - @ctx-core/store@27.0.46
17
+
3
18
  ## 13.0.54
4
19
 
5
20
  ### Patch Changes
package/COMMIT_EDITMSG ADDED
@@ -0,0 +1 @@
1
+
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/CACHE_VERSION$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { Writable$, writable$ } from '@ctx-core/store'\nimport type { env_Ctx } from './env_Ctx.js'\nconst key = 'CACHE_VERSION$'\nexport const CACHE_VERSION$_b:B<env_Ctx, typeof key> = be_(key, ()=>\n\twritable$(\n\t\ttypeof process === 'object' && process.env.CACHE_VERSION\n\t) as CACHE_VERSION$_T\n)\nexport type CACHE_VERSION_T = false|string\nexport interface CACHE_VERSION$_T extends Writable$<CACHE_VERSION_T> {}\nexport {\n\tCACHE_VERSION$_b as b__CACHE_VERSION,\n}\n"],"names":["be_","writable$","key","CACHE_VERSION$_b","process","env","CACHE_VERSION","b__CACHE_VERSION"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAcC,SAAS,QAAQ,CAAiB;AAEtD,KAAK,CAACC,GAAG,GAAG,CAAgB;AAC5B,MAAM,CAAC,KAAK,CAACC,gBAAgB,GAA0BH,GAAG,CAACE,GAAG,MAC7DD,SAAS,CACR,MAAM,CAACG,OAAO,KAAK,CAAQ,WAAIA,OAAO,CAACC,GAAG,CAACC,aAAa;;AAK1D,MAAM,GACLH,gBAAgB,IAAII,gBAAgB"}
1
+ {"version":3,"sources":["../src/CACHE_VERSION$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { Writable$, writable$ } from '@ctx-core/store'\nconst key = 'CACHE_VERSION$'\nexport const CACHE_VERSION$_b:B<CACHE_VERSION$_T> = be_(key, ()=>\n\twritable$(\n\t\ttypeof process === 'object' && process.env.CACHE_VERSION\n\t) as CACHE_VERSION$_T\n)\nexport type CACHE_VERSION_T = false|string\nexport interface CACHE_VERSION$_T extends Writable$<CACHE_VERSION_T> {}\nexport {\n\tCACHE_VERSION$_b as b__CACHE_VERSION,\n}\n"],"names":["be_","writable$","key","CACHE_VERSION$_b","process","env","CACHE_VERSION","b__CACHE_VERSION"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAcC,SAAS,QAAQ,CAAiB;AACtD,KAAK,CAACC,GAAG,GAAG,CAAgB;AAC5B,MAAM,CAAC,KAAK,CAACC,gBAAgB,GAAuBH,GAAG,CAACE,GAAG,MAC1DD,SAAS,CACR,MAAM,CAACG,OAAO,KAAK,CAAQ,WAAIA,OAAO,CAACC,GAAG,CAACC,aAAa;;AAK1D,MAAM,GACLH,gBAAgB,IAAII,gBAAgB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/NODE_ENV$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { writable$, Writable$ } from '@ctx-core/store'\nimport type { env_Ctx } from './env_Ctx.js'\nconst key = 'NODE_ENV$'\nexport const NODE_ENV$_b:B<env_Ctx, typeof key> = be_(key, ()=>\n\twritable$(process.env.NODE_ENV) as NODE_ENV$_T\n)\nexport type NODE_ENV_T = string\nexport interface NODE_ENV$_T extends Writable$<NODE_ENV_T> {}\nexport { NODE_ENV$_b as b__NODE_ENV }\n"],"names":["be_","writable$","key","NODE_ENV$_b","process","env","NODE_ENV","b__NODE_ENV"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,SAAS,QAAmB,CAAiB;AAEtD,KAAK,CAACC,GAAG,GAAG,CAAW;AACvB,MAAM,CAAC,KAAK,CAACC,WAAW,GAA0BH,GAAG,CAACE,GAAG,MACxDD,SAAS,CAACG,OAAO,CAACC,GAAG,CAACC,QAAQ;;AAI/B,MAAM,GAAGH,WAAW,IAAII,WAAW"}
1
+ {"version":3,"sources":["../src/NODE_ENV$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { writable$, Writable$ } from '@ctx-core/store'\nconst key = 'NODE_ENV$'\nexport const NODE_ENV$_b:B<NODE_ENV$_T> = be_(key, ()=>\n\twritable$(process.env.NODE_ENV) as NODE_ENV$_T\n)\nexport type NODE_ENV_T = string\nexport interface NODE_ENV$_T extends Writable$<NODE_ENV_T> {}\nexport { NODE_ENV$_b as b__NODE_ENV }\n"],"names":["be_","writable$","key","NODE_ENV$_b","process","env","NODE_ENV","b__NODE_ENV"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,SAAS,QAAmB,CAAiB;AACtD,KAAK,CAACC,GAAG,GAAG,CAAW;AACvB,MAAM,CAAC,KAAK,CAACC,WAAW,GAAkBH,GAAG,CAACE,GAAG,MAChDD,SAAS,CAACG,OAAO,CAACC,GAAG,CAACC,QAAQ;;AAI/B,MAAM,GAAGH,WAAW,IAAII,WAAW"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/VERSION$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { Writable$, writable$ } from '@ctx-core/store'\nimport type { env_Ctx } from './env_Ctx.js'\nconst key = 'VERSION$'\nexport const VERSION$_b:B<env_Ctx, typeof key> = be_(key, ()=>\n\twritable$(\n\t\t(typeof process === 'object' && (\n\t\t\tprocess.env.VERSION\n\t\t\t|| process.env.HEROKU_SLUG_COMMIT\n\t\t))\n\t\t|| Math.random().toString()\n\t) as VERSION$_T\n)\nexport type VERSION_T = string\nexport interface VERSION$_T extends Writable$<VERSION_T> {}\nexport {\n\tVERSION$_b as b__VERSION,\n}\n"],"names":["be_","writable$","key","VERSION$_b","process","env","VERSION","HEROKU_SLUG_COMMIT","Math","random","toString","b__VERSION"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAcC,SAAS,QAAQ,CAAiB;AAEtD,KAAK,CAACC,GAAG,GAAG,CAAU;AACtB,MAAM,CAAC,KAAK,CAACC,UAAU,GAA0BH,GAAG,CAACE,GAAG,MACvDD,SAAS,CACP,MAAM,CAACG,OAAO,KAAK,CAAQ,YAC3BA,OAAO,CAACC,GAAG,CAACC,OAAO,IAChBF,OAAO,CAACC,GAAG,CAACE,kBAAkB,KAE/BC,IAAI,CAACC,MAAM,GAAGC,QAAQ;;AAK3B,MAAM,GACLP,UAAU,IAAIQ,UAAU"}
1
+ {"version":3,"sources":["../src/VERSION$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { Writable$, writable$ } from '@ctx-core/store'\nconst key = 'VERSION$'\nexport const VERSION$_b:B<VERSION$_T> = be_(key, ()=>\n\twritable$(\n\t\t(typeof process === 'object' && (\n\t\t\tprocess.env.VERSION\n\t\t\t|| process.env.HEROKU_SLUG_COMMIT\n\t\t))\n\t\t|| Math.random().toString()\n\t) as VERSION$_T\n)\nexport type VERSION_T = string\nexport interface VERSION$_T extends Writable$<VERSION_T> {}\nexport {\n\tVERSION$_b as b__VERSION,\n}\n"],"names":["be_","writable$","key","VERSION$_b","process","env","VERSION","HEROKU_SLUG_COMMIT","Math","random","toString","b__VERSION"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAcC,SAAS,QAAQ,CAAiB;AACtD,KAAK,CAACC,GAAG,GAAG,CAAU;AACtB,MAAM,CAAC,KAAK,CAACC,UAAU,GAAiBH,GAAG,CAACE,GAAG,MAC9CD,SAAS,CACP,MAAM,CAACG,OAAO,KAAK,CAAQ,YAC3BA,OAAO,CAACC,GAAG,CAACC,OAAO,IAChBF,OAAO,CAACC,GAAG,CAACE,kBAAkB,KAE/BC,IAAI,CAACC,MAAM,GAAGC,QAAQ;;AAK3B,MAAM,GACLP,UAAU,IAAIQ,UAAU"}
package/dist/index.js CHANGED
@@ -1,6 +1,4 @@
1
1
  export * from './CACHE_VERSION$_b.js';
2
- export * from './env_Ctx.js';
3
- export * from './env_ctx_I.generated.js';
4
2
  export * from './is_development$_b.js';
5
3
  export * from './is_production$_b.js';
6
4
  export * from './is_staging$_b.js';
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from './CACHE_VERSION$_b.js'\nexport * from './env_Ctx.js'\nexport * from './env_ctx_I.generated.js'\nexport * from './is_development$_b.js'\nexport * from './is_production$_b.js'\nexport * from './is_staging$_b.js'\nexport * from './NODE_ENV$_b.js'\nexport * from './throw_missing_env.js'\nexport * from './VERSION$_b.js'\n"],"names":[],"mappings":"cAAc,CAAuB;cACvB,CAAc;cACd,CAA0B;cAC1B,CAAwB;cACxB,CAAuB;cACvB,CAAoB;cACpB,CAAkB;cAClB,CAAwB;cACxB,CAAiB"}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from './CACHE_VERSION$_b.js'\nexport * from './is_development$_b.js'\nexport * from './is_production$_b.js'\nexport * from './is_staging$_b.js'\nexport * from './NODE_ENV$_b.js'\nexport * from './throw_missing_env.js'\nexport * from './VERSION$_b.js'\n"],"names":[],"mappings":"cAAc,CAAuB;cACvB,CAAwB;cACxB,CAAuB;cACvB,CAAoB;cACpB,CAAkB;cAClB,CAAwB;cACxB,CAAiB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/is_development$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { derived$, Readable$ } from '@ctx-core/store'\nimport type { env_Ctx } from './env_Ctx.js'\nimport { NODE_ENV$_b } from './NODE_ENV$_b.js'\nconst key = 'is_development$'\nexport const is_development$_b:B<env_Ctx, typeof key> = be_(key, ctx=>\n\tderived$(NODE_ENV$_b(ctx),\n\t\tNODE_ENV=>\n\t\t\tNODE_ENV === 'dev' || NODE_ENV === 'development.js'\n\t) as is_development$_T\n)\nexport type is_development_T = boolean\nexport interface is_development$_T extends Readable$<is_development_T> {}\nexport { is_development$_b as b__is__development }\n"],"names":["be_","derived$","NODE_ENV$_b","key","is_development$_b","ctx","NODE_ENV","b__is__development"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,QAAQ,QAAmB,CAAiB;AAErD,MAAM,GAAGC,WAAW,QAAQ,CAAkB;AAC9C,KAAK,CAACC,GAAG,GAAG,CAAiB;AAC7B,MAAM,CAAC,KAAK,CAACC,iBAAiB,GAA0BJ,GAAG,CAACG,GAAG,GAAEE,GAAG,GACnEJ,QAAQ,CAACC,WAAW,CAACG,GAAG,IACvBC,QAAQ,GACPA,QAAQ,KAAK,CAAK,QAAIA,QAAQ,KAAK,CAAgB;;;AAKtD,MAAM,GAAGF,iBAAiB,IAAIG,kBAAkB"}
1
+ {"version":3,"sources":["../src/is_development$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { derived$, Readable$ } from '@ctx-core/store'\nimport { NODE_ENV$_b } from './NODE_ENV$_b.js'\nconst key = 'is_development$'\nexport const is_development$_b:B<is_development$_T> = be_(key, ctx=>\n\tderived$(NODE_ENV$_b(ctx),\n\t\tNODE_ENV=>\n\t\t\tNODE_ENV === 'dev' || NODE_ENV === 'development.js'\n\t) as is_development$_T\n)\nexport type is_development_T = boolean\nexport interface is_development$_T extends Readable$<is_development_T> {}\nexport { is_development$_b as b__is__development }\n"],"names":["be_","derived$","NODE_ENV$_b","key","is_development$_b","ctx","NODE_ENV","b__is__development"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,QAAQ,QAAmB,CAAiB;AACrD,MAAM,GAAGC,WAAW,QAAQ,CAAkB;AAC9C,KAAK,CAACC,GAAG,GAAG,CAAiB;AAC7B,MAAM,CAAC,KAAK,CAACC,iBAAiB,GAAwBJ,GAAG,CAACG,GAAG,GAAEE,GAAG,GACjEJ,QAAQ,CAACC,WAAW,CAACG,GAAG,IACvBC,QAAQ,GACPA,QAAQ,KAAK,CAAK,QAAIA,QAAQ,KAAK,CAAgB;;;AAKtD,MAAM,GAAGF,iBAAiB,IAAIG,kBAAkB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/is_production$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { derived$, Readable$ } from '@ctx-core/store'\nimport type { env_Ctx } from './env_Ctx.js'\nimport { NODE_ENV$_b } from './NODE_ENV$_b.js'\nconst key = 'is_production$'\nexport const is_production$_b:B<env_Ctx, typeof key> = be_(key, ctx=>\n\tderived$(NODE_ENV$_b(ctx), NODE_ENV=>\n\t\tNODE_ENV === 'prod' || NODE_ENV === 'production.js'\n\t) as is_production$_T\n)\nexport type is_production_T = boolean\nexport interface is_production$_T extends Readable$<is_production_T> {}\nexport { is_production$_b as b__is__production }\n"],"names":["be_","derived$","NODE_ENV$_b","key","is_production$_b","ctx","NODE_ENV","b__is__production"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,QAAQ,QAAmB,CAAiB;AAErD,MAAM,GAAGC,WAAW,QAAQ,CAAkB;AAC9C,KAAK,CAACC,GAAG,GAAG,CAAgB;AAC5B,MAAM,CAAC,KAAK,CAACC,gBAAgB,GAA0BJ,GAAG,CAACG,GAAG,GAAEE,GAAG,GAClEJ,QAAQ,CAACC,WAAW,CAACG,GAAG,IAAGC,QAAQ,GAClCA,QAAQ,KAAK,CAAM,SAAIA,QAAQ,KAAK,CAAe;;;AAKrD,MAAM,GAAGF,gBAAgB,IAAIG,iBAAiB"}
1
+ {"version":3,"sources":["../src/is_production$_b.ts"],"sourcesContent":["import { B, be_ } from '@ctx-core/object'\nimport { derived$, Readable$ } from '@ctx-core/store'\nimport { NODE_ENV$_b } from './NODE_ENV$_b.js'\nconst key = 'is_production$'\nexport const is_production$_b:B<is_production$_T> = be_(key, ctx=>\n\tderived$(NODE_ENV$_b(ctx), NODE_ENV=>\n\t\tNODE_ENV === 'prod' || NODE_ENV === 'production.js'\n\t) as is_production$_T\n)\nexport type is_production_T = boolean\nexport interface is_production$_T extends Readable$<is_production_T> {}\nexport { is_production$_b as b__is__production }\n"],"names":["be_","derived$","NODE_ENV$_b","key","is_production$_b","ctx","NODE_ENV","b__is__production"],"mappings":"AAAA,MAAM,GAAMA,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,QAAQ,QAAmB,CAAiB;AACrD,MAAM,GAAGC,WAAW,QAAQ,CAAkB;AAC9C,KAAK,CAACC,GAAG,GAAG,CAAgB;AAC5B,MAAM,CAAC,KAAK,CAACC,gBAAgB,GAAuBJ,GAAG,CAACG,GAAG,GAAEE,GAAG,GAC/DJ,QAAQ,CAACC,WAAW,CAACG,GAAG,IAAGC,QAAQ,GAClCA,QAAQ,KAAK,CAAM,SAAIA,QAAQ,KAAK,CAAe;;;AAKrD,MAAM,GAAGF,gBAAgB,IAAIG,iBAAiB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/is_staging$_b.ts"],"sourcesContent":["import { eql_ } from '@ctx-core/function'\nimport { B, be_ } from '@ctx-core/object'\nimport { derived$, Readable$ } from '@ctx-core/store'\nimport type { env_Ctx } from './env_Ctx.js'\nimport { NODE_ENV$_b } from './NODE_ENV$_b.js'\nconst key = 'is_staging$'\nexport const is_staging$_b:B<env_Ctx, typeof key> = be_(key, ctx=>\n\tderived$(\n\t\tNODE_ENV$_b(ctx),\n\t\teql_(['staging'])\n\t) as is_staging$_T\n)\nexport type is_staging_T = boolean\nexport interface is_staging$_T extends Readable$<is_staging_T> {}\nexport { is_staging$_b as b__is__staging }\n"],"names":["eql_","be_","derived$","NODE_ENV$_b","key","is_staging$_b","ctx","b__is__staging"],"mappings":"AAAA,MAAM,GAAGA,IAAI,QAAQ,CAAoB;AACzC,MAAM,GAAMC,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,QAAQ,QAAmB,CAAiB;AAErD,MAAM,GAAGC,WAAW,QAAQ,CAAkB;AAC9C,KAAK,CAACC,GAAG,GAAG,CAAa;AACzB,MAAM,CAAC,KAAK,CAACC,aAAa,GAA0BJ,GAAG,CAACG,GAAG,GAAEE,GAAG,GAC/DJ,QAAQ,CACPC,WAAW,CAACG,GAAG,GACfN,IAAI,CAAC,CAAC;QAAA,CAAS;IAAA,CAAC;;AAKlB,MAAM,GAAGK,aAAa,IAAIE,cAAc"}
1
+ {"version":3,"sources":["../src/is_staging$_b.ts"],"sourcesContent":["import { eql_ } from '@ctx-core/function'\nimport { B, be_ } from '@ctx-core/object'\nimport { derived$, Readable$ } from '@ctx-core/store'\nimport { NODE_ENV$_b } from './NODE_ENV$_b.js'\nconst key = 'is_staging$'\nexport const is_staging$_b:B<is_staging$_T> = be_(key, ctx=>\n\tderived$(\n\t\tNODE_ENV$_b(ctx),\n\t\teql_(['staging'])\n\t) as is_staging$_T\n)\nexport type is_staging_T = boolean\nexport interface is_staging$_T extends Readable$<is_staging_T> {}\nexport { is_staging$_b as b__is__staging }\n"],"names":["eql_","be_","derived$","NODE_ENV$_b","key","is_staging$_b","ctx","b__is__staging"],"mappings":"AAAA,MAAM,GAAGA,IAAI,QAAQ,CAAoB;AACzC,MAAM,GAAMC,GAAG,QAAQ,CAAkB;AACzC,MAAM,GAAGC,QAAQ,QAAmB,CAAiB;AACrD,MAAM,GAAGC,WAAW,QAAQ,CAAkB;AAC9C,KAAK,CAACC,GAAG,GAAG,CAAa;AACzB,MAAM,CAAC,KAAK,CAACC,aAAa,GAAoBJ,GAAG,CAACG,GAAG,GAAEE,GAAG,GACzDJ,QAAQ,CACPC,WAAW,CAACG,GAAG,GACfN,IAAI,CAAC,CAAC;QAAA,CAAS;IAAA,CAAC;;AAKlB,MAAM,GAAGK,aAAa,IAAIE,cAAc"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ctx-core/env",
3
- "version": "13.0.54",
3
+ "version": "14.0.0",
4
4
  "description": "ctx-core env",
5
5
  "keywords": [
6
6
  "ctx-core",
@@ -17,24 +17,21 @@
17
17
  "license": "Apache-2.0",
18
18
  "author": "Brian Takita",
19
19
  "type": "module",
20
- "module": "./dist/index.js",
21
20
  "types": "./src/index.ts",
22
21
  "exports": {
23
22
  ".": {
24
- "require": "./dist/index.cjs",
25
23
  "import": "./dist/index.js"
26
24
  },
27
25
  "./package.json": "./package.json"
28
26
  },
29
27
  "dependencies": {
30
- "@ctx-core/error": "^11.1.8",
28
+ "@ctx-core/error": "^11.1.9",
31
29
  "@ctx-core/function": "^20.2.12",
32
- "@ctx-core/object": "^21.0.30",
33
- "@ctx-core/store": "^27.0.45",
30
+ "@ctx-core/object": "^22.0.0",
31
+ "@ctx-core/store": "^27.0.46",
34
32
  "svelte": "3.44.2"
35
33
  },
36
34
  "devDependencies": {
37
- "@ctx-core/dev-tools": "^7.2.9",
38
35
  "@swc/cli": "^0.1.52",
39
36
  "@swc/core": "^1.2.118",
40
37
  "typescript": "next"
@@ -44,10 +41,9 @@
44
41
  "cache": "~/.npm"
45
42
  },
46
43
  "scripts": {
47
- "build": "npm run generate_ctx_I_file && npm run compile",
44
+ "build": "npm run compile",
48
45
  "clean": "rm -rf dist",
49
46
  "compile": "swc src --out-dir dist --copy-files --source-maps --config-file .swcrc",
50
- "exec": "$@",
51
- "generate_ctx_I_file": "swc $(./node_modules/.bin/generate_ctx_I_file | tail -n1) --out-dir dist --source-maps --config-file .swcrc"
47
+ "exec": "$@"
52
48
  }
53
49
  }
@@ -1,8 +1,7 @@
1
1
  import { B, be_ } from '@ctx-core/object'
2
2
  import { Writable$, writable$ } from '@ctx-core/store'
3
- import type { env_Ctx } from './env_Ctx.js'
4
3
  const key = 'CACHE_VERSION$'
5
- export const CACHE_VERSION$_b:B<env_Ctx, typeof key> = be_(key, ()=>
4
+ export const CACHE_VERSION$_b:B<CACHE_VERSION$_T> = be_(key, ()=>
6
5
  writable$(
7
6
  typeof process === 'object' && process.env.CACHE_VERSION
8
7
  ) as CACHE_VERSION$_T
@@ -1,8 +1,7 @@
1
1
  import { B, be_ } from '@ctx-core/object'
2
2
  import { writable$, Writable$ } from '@ctx-core/store'
3
- import type { env_Ctx } from './env_Ctx.js'
4
3
  const key = 'NODE_ENV$'
5
- export const NODE_ENV$_b:B<env_Ctx, typeof key> = be_(key, ()=>
4
+ export const NODE_ENV$_b:B<NODE_ENV$_T> = be_(key, ()=>
6
5
  writable$(process.env.NODE_ENV) as NODE_ENV$_T
7
6
  )
8
7
  export type NODE_ENV_T = string
package/src/VERSION$_b.ts CHANGED
@@ -1,8 +1,7 @@
1
1
  import { B, be_ } from '@ctx-core/object'
2
2
  import { Writable$, writable$ } from '@ctx-core/store'
3
- import type { env_Ctx } from './env_Ctx.js'
4
3
  const key = 'VERSION$'
5
- export const VERSION$_b:B<env_Ctx, typeof key> = be_(key, ()=>
4
+ export const VERSION$_b:B<VERSION$_T> = be_(key, ()=>
6
5
  writable$(
7
6
  (typeof process === 'object' && (
8
7
  process.env.VERSION
package/src/index.ts CHANGED
@@ -1,6 +1,4 @@
1
1
  export * from './CACHE_VERSION$_b.js'
2
- export * from './env_Ctx.js'
3
- export * from './env_ctx_I.generated.js'
4
2
  export * from './is_development$_b.js'
5
3
  export * from './is_production$_b.js'
6
4
  export * from './is_staging$_b.js'
@@ -1,9 +1,8 @@
1
1
  import { B, be_ } from '@ctx-core/object'
2
2
  import { derived$, Readable$ } from '@ctx-core/store'
3
- import type { env_Ctx } from './env_Ctx.js'
4
3
  import { NODE_ENV$_b } from './NODE_ENV$_b.js'
5
4
  const key = 'is_development$'
6
- export const is_development$_b:B<env_Ctx, typeof key> = be_(key, ctx=>
5
+ export const is_development$_b:B<is_development$_T> = be_(key, ctx=>
7
6
  derived$(NODE_ENV$_b(ctx),
8
7
  NODE_ENV=>
9
8
  NODE_ENV === 'dev' || NODE_ENV === 'development.js'
@@ -1,9 +1,8 @@
1
1
  import { B, be_ } from '@ctx-core/object'
2
2
  import { derived$, Readable$ } from '@ctx-core/store'
3
- import type { env_Ctx } from './env_Ctx.js'
4
3
  import { NODE_ENV$_b } from './NODE_ENV$_b.js'
5
4
  const key = 'is_production$'
6
- export const is_production$_b:B<env_Ctx, typeof key> = be_(key, ctx=>
5
+ export const is_production$_b:B<is_production$_T> = be_(key, ctx=>
7
6
  derived$(NODE_ENV$_b(ctx), NODE_ENV=>
8
7
  NODE_ENV === 'prod' || NODE_ENV === 'production.js'
9
8
  ) as is_production$_T
@@ -1,10 +1,9 @@
1
1
  import { eql_ } from '@ctx-core/function'
2
2
  import { B, be_ } from '@ctx-core/object'
3
3
  import { derived$, Readable$ } from '@ctx-core/store'
4
- import type { env_Ctx } from './env_Ctx.js'
5
4
  import { NODE_ENV$_b } from './NODE_ENV$_b.js'
6
5
  const key = 'is_staging$'
7
- export const is_staging$_b:B<env_Ctx, typeof key> = be_(key, ctx=>
6
+ export const is_staging$_b:B<is_staging$_T> = be_(key, ctx=>
8
7
  derived$(
9
8
  NODE_ENV$_b(ctx),
10
9
  eql_(['staging'])
package/dist/env_Ctx.js DELETED
@@ -1,3 +0,0 @@
1
- export { };
2
-
3
- //# sourceMappingURL=env_Ctx.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/env_Ctx.ts"],"sourcesContent":["import type { env_ctx_I } from './env_ctx_I.generated.js'\nexport interface env_Ctx extends env_ctx_I {}\n"],"names":[],"mappings":"AAAA,MAAM"}
@@ -1,5 +0,0 @@
1
- /*
2
- * This file was generated by `npm run generate_ctx_I_file` in @ctx-core/dev-tools
3
- */ export { };
4
-
5
- //# sourceMappingURL=env_ctx_I.generated.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/env_ctx_I.generated.ts"],"sourcesContent":["/*\n * This file was generated by `npm run generate_ctx_I_file` in @ctx-core/dev-tools\n*/\nimport type { CACHE_VERSION$_T } from './CACHE_VERSION$_b.js'\nimport type { NODE_ENV$_T } from './NODE_ENV$_b.js'\nimport type { VERSION$_T } from './VERSION$_b.js'\nimport type { is_development$_T } from './is_development$_b.js'\nimport type { is_production$_T } from './is_production$_b.js'\nimport type { is_staging$_T } from './is_staging$_b.js'\nexport interface env_ctx_I {\n\tCACHE_VERSION$?:CACHE_VERSION$_T\n\tNODE_ENV$?:NODE_ENV$_T\n\tVERSION$?:VERSION$_T\n\tis_development$?:is_development$_T\n\tis_production$?:is_production$_T\n\tis_staging$?:is_staging$_T\n}"],"names":[],"mappings":"AAAA,EAEE,AAFF;;AAEE,AAFF,EAEE,CACF,MAAM"}
package/src/env_Ctx.ts DELETED
@@ -1,2 +0,0 @@
1
- import type { env_ctx_I } from './env_ctx_I.generated.js'
2
- export interface env_Ctx extends env_ctx_I {}
@@ -1,17 +0,0 @@
1
- /*
2
- * This file was generated by `npm run generate_ctx_I_file` in @ctx-core/dev-tools
3
- */
4
- import type { CACHE_VERSION$_T } from './CACHE_VERSION$_b.js'
5
- import type { NODE_ENV$_T } from './NODE_ENV$_b.js'
6
- import type { VERSION$_T } from './VERSION$_b.js'
7
- import type { is_development$_T } from './is_development$_b.js'
8
- import type { is_production$_T } from './is_production$_b.js'
9
- import type { is_staging$_T } from './is_staging$_b.js'
10
- export interface env_ctx_I {
11
- CACHE_VERSION$?:CACHE_VERSION$_T
12
- NODE_ENV$?:NODE_ENV$_T
13
- VERSION$?:VERSION$_T
14
- is_development$?:is_development$_T
15
- is_production$?:is_production$_T
16
- is_staging$?:is_staging$_T
17
- }