@powerlines/plugin-env 0.16.157 → 0.16.158

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.
Files changed (109) hide show
  1. package/package.json +9 -9
  2. package/dist/_virtual/_rolldown/runtime.cjs +0 -1
  3. package/dist/babel/index.cjs +0 -1
  4. package/dist/babel/index.d.cts +0 -2
  5. package/dist/babel/index.d.mts +0 -2
  6. package/dist/babel/index.mjs +0 -1
  7. package/dist/babel/plugin.cjs +0 -5
  8. package/dist/babel/plugin.d.cts +0 -8
  9. package/dist/babel/plugin.d.cts.map +0 -1
  10. package/dist/babel/plugin.d.mts +0 -8
  11. package/dist/babel/plugin.d.mts.map +0 -1
  12. package/dist/babel/plugin.mjs +0 -6
  13. package/dist/babel/plugin.mjs.map +0 -1
  14. package/dist/components/docs.cjs +0 -1
  15. package/dist/components/docs.d.cts +0 -24
  16. package/dist/components/docs.d.cts.map +0 -1
  17. package/dist/components/docs.d.mts +0 -24
  18. package/dist/components/docs.d.mts.map +0 -1
  19. package/dist/components/docs.mjs +0 -2
  20. package/dist/components/docs.mjs.map +0 -1
  21. package/dist/components/env-builtin.cjs +0 -98
  22. package/dist/components/env-builtin.d.cts +0 -21
  23. package/dist/components/env-builtin.d.cts.map +0 -1
  24. package/dist/components/env-builtin.d.mts +0 -21
  25. package/dist/components/env-builtin.d.mts.map +0 -1
  26. package/dist/components/env-builtin.mjs +0 -96
  27. package/dist/components/env-builtin.mjs.map +0 -1
  28. package/dist/components/index.cjs +0 -1
  29. package/dist/components/index.d.cts +0 -3
  30. package/dist/components/index.d.mts +0 -3
  31. package/dist/components/index.mjs +0 -1
  32. package/dist/helpers/automd-generator.cjs +0 -1
  33. package/dist/helpers/automd-generator.d.cts +0 -14
  34. package/dist/helpers/automd-generator.d.cts.map +0 -1
  35. package/dist/helpers/automd-generator.d.mts +0 -14
  36. package/dist/helpers/automd-generator.d.mts.map +0 -1
  37. package/dist/helpers/automd-generator.mjs +0 -2
  38. package/dist/helpers/automd-generator.mjs.map +0 -1
  39. package/dist/helpers/create-reflection-resource.cjs +0 -1
  40. package/dist/helpers/create-reflection-resource.d.cts +0 -13
  41. package/dist/helpers/create-reflection-resource.d.cts.map +0 -1
  42. package/dist/helpers/create-reflection-resource.d.mts +0 -13
  43. package/dist/helpers/create-reflection-resource.d.mts.map +0 -1
  44. package/dist/helpers/create-reflection-resource.mjs +0 -2
  45. package/dist/helpers/create-reflection-resource.mjs.map +0 -1
  46. package/dist/helpers/index.cjs +0 -1
  47. package/dist/helpers/index.d.cts +0 -7
  48. package/dist/helpers/index.d.mts +0 -7
  49. package/dist/helpers/index.mjs +0 -1
  50. package/dist/helpers/load.cjs +0 -1
  51. package/dist/helpers/load.d.cts +0 -36
  52. package/dist/helpers/load.d.cts.map +0 -1
  53. package/dist/helpers/load.d.mts +0 -36
  54. package/dist/helpers/load.d.mts.map +0 -1
  55. package/dist/helpers/load.mjs +0 -2
  56. package/dist/helpers/load.mjs.map +0 -1
  57. package/dist/helpers/persistence.cjs +0 -1
  58. package/dist/helpers/persistence.d.cts +0 -84
  59. package/dist/helpers/persistence.d.cts.map +0 -1
  60. package/dist/helpers/persistence.d.mts +0 -84
  61. package/dist/helpers/persistence.d.mts.map +0 -1
  62. package/dist/helpers/persistence.mjs +0 -2
  63. package/dist/helpers/persistence.mjs.map +0 -1
  64. package/dist/helpers/reflect.cjs +0 -1
  65. package/dist/helpers/reflect.d.cts +0 -68
  66. package/dist/helpers/reflect.d.cts.map +0 -1
  67. package/dist/helpers/reflect.d.mts +0 -68
  68. package/dist/helpers/reflect.d.mts.map +0 -1
  69. package/dist/helpers/reflect.mjs +0 -2
  70. package/dist/helpers/reflect.mjs.map +0 -1
  71. package/dist/helpers/source-file-env.cjs +0 -1
  72. package/dist/helpers/source-file-env.d.cts +0 -9
  73. package/dist/helpers/source-file-env.d.cts.map +0 -1
  74. package/dist/helpers/source-file-env.d.mts +0 -9
  75. package/dist/helpers/source-file-env.d.mts.map +0 -1
  76. package/dist/helpers/source-file-env.mjs +0 -2
  77. package/dist/helpers/source-file-env.mjs.map +0 -1
  78. package/dist/helpers/template-helpers.cjs +0 -1
  79. package/dist/helpers/template-helpers.d.cts +0 -15
  80. package/dist/helpers/template-helpers.d.cts.map +0 -1
  81. package/dist/helpers/template-helpers.d.mts +0 -15
  82. package/dist/helpers/template-helpers.d.mts.map +0 -1
  83. package/dist/helpers/template-helpers.mjs +0 -2
  84. package/dist/helpers/template-helpers.mjs.map +0 -1
  85. package/dist/index.cjs +0 -1
  86. package/dist/index.d.cts +0 -17
  87. package/dist/index.d.cts.map +0 -1
  88. package/dist/index.d.mts +0 -17
  89. package/dist/index.d.mts.map +0 -1
  90. package/dist/index.mjs +0 -2
  91. package/dist/index.mjs.map +0 -1
  92. package/dist/types/index.cjs +0 -1
  93. package/dist/types/index.d.cts +0 -3
  94. package/dist/types/index.d.mts +0 -3
  95. package/dist/types/index.mjs +0 -1
  96. package/dist/types/plugin.cjs +0 -1
  97. package/dist/types/plugin.d.cts +0 -163
  98. package/dist/types/plugin.d.cts.map +0 -1
  99. package/dist/types/plugin.d.mts +0 -163
  100. package/dist/types/plugin.d.mts.map +0 -1
  101. package/dist/types/plugin.mjs +0 -2
  102. package/dist/types/plugin.mjs.map +0 -1
  103. package/dist/types/runtime.cjs +0 -1
  104. package/dist/types/runtime.d.cts +0 -934
  105. package/dist/types/runtime.d.cts.map +0 -1
  106. package/dist/types/runtime.d.mts +0 -934
  107. package/dist/types/runtime.d.mts.map +0 -1
  108. package/dist/types/runtime.mjs +0 -2
  109. package/dist/types/runtime.mjs.map +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@powerlines/plugin-env",
3
- "version": "0.16.157",
3
+ "version": "0.16.158",
4
4
  "private": false,
5
5
  "description": "A package containing a Powerlines plugin for injecting static .env configuration values to the code so that they're accessible at runtime.",
6
6
  "keywords": ["dotenv", "powerlines", "storm-software", "powerlines-plugin"],
@@ -292,12 +292,12 @@
292
292
  "@alloy-js/typescript": "0.23.0-dev.4",
293
293
  "@babel/core": "8.0.0-rc.3",
294
294
  "@babel/types": "8.0.0-rc.3",
295
- "@powerlines/plugin-alloy": "^0.26.49",
296
- "@powerlines/plugin-automd": "^0.1.431",
297
- "@powerlines/plugin-babel": "^0.12.424",
298
- "@powerlines/plugin-plugin": "^0.12.382",
299
- "@powerlines/deepkit": "^0.8.32",
300
- "@powerlines/plugin-deepkit": "^0.11.313",
295
+ "@powerlines/plugin-alloy": "^0.26.51",
296
+ "@powerlines/plugin-automd": "^0.1.432",
297
+ "@powerlines/plugin-babel": "^0.12.425",
298
+ "@powerlines/plugin-plugin": "^0.12.383",
299
+ "@powerlines/deepkit": "^0.8.33",
300
+ "@powerlines/plugin-deepkit": "^0.11.314",
301
301
  "@storm-software/config-tools": "^1.189.78",
302
302
  "@stryke/capnp": "^0.12.93",
303
303
  "@stryke/convert": "^0.7.0",
@@ -311,10 +311,10 @@
311
311
  "@stryke/types": "^0.11.4",
312
312
  "automd": "^0.4.3",
313
313
  "defu": "^6.1.7",
314
- "powerlines": "^0.43.27",
314
+ "powerlines": "^0.43.28",
315
315
  "c12": "^3.3.4"
316
316
  },
317
317
  "devDependencies": { "@types/node": "^25.6.0", "vite": "^8.0.10" },
318
318
  "publishConfig": { "access": "public" },
319
- "gitHead": "ad851a239011b884c15b0444db518d74927fd13f"
319
+ "gitHead": "efeaec793549f37c700f2e876bf6097c37375c46"
320
320
  }
@@ -1 +0,0 @@
1
- var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},s=(n,r,a)=>(a=n==null?{}:e(i(n)),o(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n));exports.__toESM=s;
@@ -1 +0,0 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./plugin.cjs`);exports.envBabelPlugin=e.envBabelPlugin;
@@ -1,2 +0,0 @@
1
- import { envBabelPlugin } from "./plugin.cjs";
2
- export { envBabelPlugin };
@@ -1,2 +0,0 @@
1
- import { envBabelPlugin } from "./plugin.mjs";
2
- export { envBabelPlugin };
@@ -1 +0,0 @@
1
- import{envBabelPlugin as e}from"./plugin.mjs";export{e as envBabelPlugin};
@@ -1,5 +0,0 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`../_virtual/_rolldown/runtime.cjs`);const e=require(`../types/plugin.cjs`);let t=require(`@powerlines/deepkit/utilities`),n=require(`@powerlines/plugin-babel/helpers/create-plugin`),r=require(`@powerlines/plugin-babel/helpers/module-helpers`),i=require(`@storm-software/config-tools/types`);function a(e,t){return e.__type=t,e}const o=(n.createBabelPlugin.Ω=[[()=>e.__ΩEnvPluginContext,`n!`]],(0,n.createBabelPlugin)(`env`,a(({log:e,context:n})=>{function o(r,o,s=!1,c=!1){let l=n.env.types.env?.getProperties().filter(a(e=>e.getAlias().length>0,[`prop`,``,`P"2!"/"`]));if(r.name){let u=r.name.replace(RegExp(`^(${n.config.env.prefix.join(`|`)})_`),``);if(e(i.LogLevelLabel.TRACE,`Environment variable ${u} found in ${o.filename||`unknown file`}.`),n.env.types.env?.hasProperty(u)||l.some(a(e=>e.getAlias().includes(u),[`prop`,``,`P"2!"/"`]))){let r=n.env.types.env.hasProperty(u)?n.env.types.env.getProperty(u):l.find(a(e=>e.getAlias().includes(u),[`prop`,``,`P"2!"/"`]));if(!r||r.isIgnored())return;if(n.env.used.env.hasProperty(u)||(e(i.LogLevelLabel.DEBUG,`Adding "${u}" environment variables found in "${o.filename||`unknown file`}" to used environment configuration reflection object.`),n.env.used.env.addProperty(r.property)),n.config.env.inject&&s){let e=n.env.parsed?.[u];if(e===void 0){let t=n.config.env.prefix.find(a(e=>n.env.parsed[`${e.replace(/_$/g,``)}_${u}`],[`pre`,``,`P"2!"/"`]));t&&(e=n.env.parsed[`${t.replace(/_$/g,``)}_${u}`])}if(e??=r.getDefaultValue(),r.isValueRequired()&&e===void 0)throw Error(`Environment variable \`${u}\` is not defined in the .env configuration files`);return(0,t.stringifyDefaultValue)(r,e)}}else if(n.config.env.validate)throw Error(`The "${u}" environment variable is not defined in the \`env\` type definition, but is used in the source code file ${o.filename?o.filename:`unknown`}.
2
-
3
- The following environment configuration names are defined in the \`env\` type definition: \n${n.env.types.env?.getPropertyNames().sort(a((e,t)=>String(e).localeCompare(String(t)),[`a`,`b`,``,`P"2!"2""/#`])).map(a(e=>` - ${String(e)} ${l.some(a(t=>t.getNameAsString()===String(e)&&t.getAlias().length>0,[`prop`,``,`P"2!"/"`]))?`(Alias: ${l?.find(a(t=>t.getNameAsString()===String(e),[`prop`,``,`P"2!"/"`]))?.getAlias().join(`, `)})`:``}`,[`typeDef`,``,`P"2!"/"`])).join(`
4
- `)} \n\nUsing the following env prefix: \n${n.config.env.prefix.map(a(e=>` - ${e}`,[`prefix`,``,`P"2!"/"`])).join(`
5
- `)} \n\nPlease check your \`env\` configuration option. If you are using a custom dotenv type definition, please make sure that the configuration names match the ones in the code. \n\n`);else o.filename&&c&&n.warn(`The "${u}" environment variable is used in the source code file ${o.filename}, but is not defined in the \`env\` type definition. If this is intentional, you can ignore this warning. Otherwise, please check your \`env\` configuration option. If you are using a custom dotenv type definition, please make sure that the configuration names match the ones in the code.`)}}return o.__type=[`node`,`pass`,`isInjectable`,`isUsingBuiltin`,`extractEnv`,`P!2!!2""2#"2$"/%`],{visitor:{MemberExpression:a(function(e,t){if(e.get(`object`)?.get(`property`)?.isIdentifier({name:`env`})&&e.get(`object`)?.get(`object`)?.isIdentifier({name:`process`})&&e.get(`property`)?.isIdentifier()){let i=e.get(`property`)?.node;if(!i.name)return;o(i,t,!1,!1),e.replaceWithSourceString(`env.${i.name}`),(0,r.addImport)(e,{module:`${n.config.framework||`powerlines`}:env`,name:`env`,imported:`env`})}else if(e.get(`object`)?.get(`property`)?.isIdentifier({name:`env`})&&e.get(`object`)?.get(`object`)?.isMetaProperty()&&e.get(`property`)?.isIdentifier()){let i=e.get(`property`)?.node;if(!i.name)return;o(i,t,!1,!1),e.replaceWithSourceString(`env.${i.name}`),(0,r.addImport)(e,{module:`${n.config.framework||`powerlines`}:env`,name:`env`,imported:`env`})}else if(e.get(`object`)?.isIdentifier({name:`env`})&&e.get(`property`)?.isIdentifier()){let n=e.get(`property`)?.node;if(!n.name)return;o(n,t,!1,!0)}},[`NodePath`,`path`,`pass`,`MemberExpression`,`P"w!2"!2#"/$`])}}},[`param0`,``,`P"2!"/"`])));exports.envBabelPlugin=o;
@@ -1,8 +0,0 @@
1
- import { EnvPluginContext, EnvPluginResolvedConfig } from "../types/plugin.cjs";
2
- import * as _$_powerlines_plugin_babel0 from "@powerlines/plugin-babel";
3
-
4
- //#region src/babel/plugin.d.ts
5
- declare const envBabelPlugin: _$_powerlines_plugin_babel0.DeclareBabelTransformPluginReturn<EnvPluginContext<EnvPluginResolvedConfig>, object>;
6
- //#endregion
7
- export { envBabelPlugin };
8
- //# sourceMappingURL=plugin.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/babel/plugin.ts"],"mappings":";;;;cAiCa,cAAA,EAAc,2BAAA,CAAA,iCAAA,CAAA,gBAAA,CAgM1B,uBAAA"}
@@ -1,8 +0,0 @@
1
- import { EnvPluginContext, EnvPluginResolvedConfig } from "../types/plugin.mjs";
2
- import * as _$_powerlines_plugin_babel0 from "@powerlines/plugin-babel";
3
-
4
- //#region src/babel/plugin.d.ts
5
- declare const envBabelPlugin: _$_powerlines_plugin_babel0.DeclareBabelTransformPluginReturn<EnvPluginContext<EnvPluginResolvedConfig>, object>;
6
- //#endregion
7
- export { envBabelPlugin };
8
- //# sourceMappingURL=plugin.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/babel/plugin.ts"],"mappings":";;;;cAiCa,cAAA,EAAc,2BAAA,CAAA,iCAAA,CAAA,gBAAA,CAgM1B,uBAAA"}
@@ -1,6 +0,0 @@
1
- import{__ΩEnvPluginContext as e}from"../types/plugin.mjs";import{stringifyDefaultValue as t}from"@powerlines/deepkit/utilities";import{createBabelPlugin as n}from"@powerlines/plugin-babel/helpers/create-plugin";import{addImport as r}from"@powerlines/plugin-babel/helpers/module-helpers";import{LogLevelLabel as i}from"@storm-software/config-tools/types";function a(e,t){return e.__type=t,e}const o=(n.Ω=[[()=>e,`n!`]],n(`env`,a(({log:e,context:n})=>{function o(r,o,s=!1,c=!1){let l=n.env.types.env?.getProperties().filter(a(e=>e.getAlias().length>0,[`prop`,``,`P"2!"/"`]));if(r.name){let u=r.name.replace(RegExp(`^(${n.config.env.prefix.join(`|`)})_`),``);if(e(i.TRACE,`Environment variable ${u} found in ${o.filename||`unknown file`}.`),n.env.types.env?.hasProperty(u)||l.some(a(e=>e.getAlias().includes(u),[`prop`,``,`P"2!"/"`]))){let r=n.env.types.env.hasProperty(u)?n.env.types.env.getProperty(u):l.find(a(e=>e.getAlias().includes(u),[`prop`,``,`P"2!"/"`]));if(!r||r.isIgnored())return;if(n.env.used.env.hasProperty(u)||(e(i.DEBUG,`Adding "${u}" environment variables found in "${o.filename||`unknown file`}" to used environment configuration reflection object.`),n.env.used.env.addProperty(r.property)),n.config.env.inject&&s){let e=n.env.parsed?.[u];if(e===void 0){let t=n.config.env.prefix.find(a(e=>n.env.parsed[`${e.replace(/_$/g,``)}_${u}`],[`pre`,``,`P"2!"/"`]));t&&(e=n.env.parsed[`${t.replace(/_$/g,``)}_${u}`])}if(e??=r.getDefaultValue(),r.isValueRequired()&&e===void 0)throw Error(`Environment variable \`${u}\` is not defined in the .env configuration files`);return t(r,e)}}else if(n.config.env.validate)throw Error(`The "${u}" environment variable is not defined in the \`env\` type definition, but is used in the source code file ${o.filename?o.filename:`unknown`}.
2
-
3
- The following environment configuration names are defined in the \`env\` type definition: \n${n.env.types.env?.getPropertyNames().sort(a((e,t)=>String(e).localeCompare(String(t)),[`a`,`b`,``,`P"2!"2""/#`])).map(a(e=>` - ${String(e)} ${l.some(a(t=>t.getNameAsString()===String(e)&&t.getAlias().length>0,[`prop`,``,`P"2!"/"`]))?`(Alias: ${l?.find(a(t=>t.getNameAsString()===String(e),[`prop`,``,`P"2!"/"`]))?.getAlias().join(`, `)})`:``}`,[`typeDef`,``,`P"2!"/"`])).join(`
4
- `)} \n\nUsing the following env prefix: \n${n.config.env.prefix.map(a(e=>` - ${e}`,[`prefix`,``,`P"2!"/"`])).join(`
5
- `)} \n\nPlease check your \`env\` configuration option. If you are using a custom dotenv type definition, please make sure that the configuration names match the ones in the code. \n\n`);else o.filename&&c&&n.warn(`The "${u}" environment variable is used in the source code file ${o.filename}, but is not defined in the \`env\` type definition. If this is intentional, you can ignore this warning. Otherwise, please check your \`env\` configuration option. If you are using a custom dotenv type definition, please make sure that the configuration names match the ones in the code.`)}}return o.__type=[`node`,`pass`,`isInjectable`,`isUsingBuiltin`,`extractEnv`,`P!2!!2""2#"2$"/%`],{visitor:{MemberExpression:a(function(e,t){if(e.get(`object`)?.get(`property`)?.isIdentifier({name:`env`})&&e.get(`object`)?.get(`object`)?.isIdentifier({name:`process`})&&e.get(`property`)?.isIdentifier()){let i=e.get(`property`)?.node;if(!i.name)return;o(i,t,!1,!1),e.replaceWithSourceString(`env.${i.name}`),r(e,{module:`${n.config.framework||`powerlines`}:env`,name:`env`,imported:`env`})}else if(e.get(`object`)?.get(`property`)?.isIdentifier({name:`env`})&&e.get(`object`)?.get(`object`)?.isMetaProperty()&&e.get(`property`)?.isIdentifier()){let i=e.get(`property`)?.node;if(!i.name)return;o(i,t,!1,!1),e.replaceWithSourceString(`env.${i.name}`),r(e,{module:`${n.config.framework||`powerlines`}:env`,name:`env`,imported:`env`})}else if(e.get(`object`)?.isIdentifier({name:`env`})&&e.get(`property`)?.isIdentifier()){let n=e.get(`property`)?.node;if(!n.name)return;o(n,t,!1,!0)}},[`NodePath`,`path`,`pass`,`MemberExpression`,`P"w!2"!2#"/$`])}}},[`param0`,``,`P"2!"/"`])));export{o as envBabelPlugin};
6
- //# sourceMappingURL=plugin.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plugin.mjs","names":[],"sources":["../../src/babel/plugin.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { NodePath } from \"@babel/core\";\nimport * as t from \"@babel/types\";\nimport { stringifyDefaultValue } from \"@powerlines/deepkit/utilities\";\nimport { createBabelPlugin } from \"@powerlines/plugin-babel/helpers/create-plugin\";\nimport { addImport } from \"@powerlines/plugin-babel/helpers/module-helpers\";\nimport { BabelPluginPass } from \"@powerlines/plugin-babel/types/config\";\nimport { LogLevelLabel } from \"@storm-software/config-tools/types\";\nimport { EnvPluginContext } from \"../types/plugin\";\n\n/*\n * The Powerlines - Environment Configuration Babel Plugin\n *\n * @param babel - The Babel core module\n * @returns The Babel plugin object\n */\nexport const envBabelPlugin = createBabelPlugin<EnvPluginContext>(\n \"env\",\n ({ log, context }) => {\n function extractEnv(\n node: t.Identifier,\n pass: BabelPluginPass,\n isInjectable = false,\n isUsingBuiltin = false\n ) {\n const envTypesAliasProperties = context.env.types.env\n ?.getProperties()\n .filter(prop => prop.getAlias().length > 0);\n\n if (node.name) {\n const name = node.name.replace(\n new RegExp(`^(${context.config.env.prefix.join(\"|\")})_`),\n \"\"\n );\n\n log(\n LogLevelLabel.TRACE,\n `Environment variable ${name} found in ${\n pass.filename || \"unknown file\"\n }.`\n );\n\n if (\n context.env.types.env?.hasProperty(name) ||\n envTypesAliasProperties.some(prop => prop.getAlias().includes(name))\n ) {\n const envProperty = context.env.types.env.hasProperty(name)\n ? context.env.types.env.getProperty(name)\n : envTypesAliasProperties.find(prop =>\n prop.getAlias().includes(name)\n );\n if (!envProperty || envProperty.isIgnored()) {\n return;\n }\n\n if (!context.env.used.env.hasProperty(name)) {\n log(\n LogLevelLabel.DEBUG,\n `Adding \"${name}\" environment variables found in \"${\n pass.filename || \"unknown file\"\n }\" to used environment configuration reflection object.`\n );\n\n context.env.used.env.addProperty(envProperty.property);\n }\n\n if (context.config.env.inject && isInjectable) {\n let value = context.env.parsed?.[name];\n if (value === undefined) {\n const prefix = context.config.env.prefix.find(pre => {\n return context.env.parsed[`${pre.replace(/_$/g, \"\")}_${name}`];\n });\n if (prefix) {\n value =\n context.env.parsed[`${prefix.replace(/_$/g, \"\")}_${name}`];\n }\n }\n\n value ??= envProperty.getDefaultValue();\n\n if (envProperty.isValueRequired() && value === undefined) {\n throw new Error(\n `Environment variable \\`${name}\\` is not defined in the .env configuration files`\n );\n }\n\n return stringifyDefaultValue(envProperty, value);\n }\n } else if (context.config.env.validate) {\n throw new Error(\n `The \"${name}\" environment variable is not defined in the \\`env\\` type definition, but is used in the source code file ${\n pass.filename ? pass.filename : \"unknown\"\n }.\n\n The following environment configuration names are defined in the \\`env\\` type definition: \\n${context.env.types.env\n ?.getPropertyNames()\n .sort((a, b) => String(a).localeCompare(String(b)))\n .map(\n typeDef =>\n ` - ${String(typeDef)} ${\n envTypesAliasProperties.some(\n prop =>\n prop.getNameAsString() === String(typeDef) &&\n prop.getAlias().length > 0\n )\n ? `(Alias: ${envTypesAliasProperties\n ?.find(\n prop => prop.getNameAsString() === String(typeDef)\n )\n ?.getAlias()\n .join(\", \")})`\n : \"\"\n }`\n )\n .join(\n \"\\n\"\n )} \\n\\nUsing the following env prefix: \\n${context.config.env.prefix\n .map(prefix => ` - ${prefix}`)\n .join(\n \"\\n\"\n )} \\n\\nPlease check your \\`env\\` configuration option. If you are using a custom dotenv type definition, please make sure that the configuration names match the ones in the code. \\n\\n`\n );\n } else if (pass.filename && isUsingBuiltin) {\n context.warn(\n `The \"${\n name\n }\" environment variable is used in the source code file ${\n pass.filename\n }, but is not defined in the \\`env\\` type definition. If this is intentional, you can ignore this warning. Otherwise, please check your \\`env\\` configuration option. If you are using a custom dotenv type definition, please make sure that the configuration names match the ones in the code.`\n );\n }\n }\n\n return undefined;\n }\n\n return {\n visitor: {\n MemberExpression(\n path: NodePath<t.MemberExpression>,\n pass: BabelPluginPass\n ) {\n if (\n path\n .get(\"object\")\n ?.get(\"property\")\n ?.isIdentifier({ name: \"env\" }) &&\n path\n .get(\"object\")\n ?.get(\"object\")\n ?.isIdentifier({ name: \"process\" }) &&\n path.get(\"property\")?.isIdentifier()\n ) {\n // process.env.CONFIG_NAME\n\n const identifier = path.get(\"property\")?.node as t.Identifier;\n if (!identifier.name) {\n return;\n }\n\n extractEnv(identifier, pass, false, false);\n\n path.replaceWithSourceString(`env.${identifier.name}`);\n addImport(path, {\n module: `${context.config.framework || \"powerlines\"}:env`,\n name: \"env\",\n imported: \"env\"\n });\n } else if (\n path\n .get(\"object\")\n ?.get(\"property\")\n ?.isIdentifier({ name: \"env\" }) &&\n path.get(\"object\")?.get(\"object\")?.isMetaProperty() &&\n path.get(\"property\")?.isIdentifier()\n ) {\n // import.meta.env.CONFIG_NAME\n\n const identifier = path.get(\"property\")?.node as t.Identifier;\n if (!identifier.name) {\n return;\n }\n\n extractEnv(identifier, pass, false, false);\n\n path.replaceWithSourceString(`env.${identifier.name}`);\n addImport(path, {\n module: `${context.config.framework || \"powerlines\"}:env`,\n name: \"env\",\n imported: \"env\"\n });\n } else if (\n path.get(\"object\")?.isIdentifier({ name: \"env\" }) &&\n path.get(\"property\")?.isIdentifier()\n ) {\n // env.CONFIG_NAME\n\n const identifier = path.get(\"property\")?.node as t.Identifier;\n if (!identifier.name) {\n return;\n }\n\n extractEnv(identifier, pass, false, true);\n }\n }\n }\n };\n }\n);\n"],"mappings":"kWAEA,SAAS,EAAY,EAAK,EAAC,CAE1B,kBAAK,EAYN,MAAa,GAAkB,EAAkB,EAAI,CAAC,KAAO,EAAS,KAAA,CAAA,CAAA,EAAA,MAAA,GAAA,CAAA,MAEtE,aACM,CACN,SAAS,EAAA,EAAA,EAAwB,EAAO,GAAW,EAAkB,GAAA,CACrE,IAAS,EAA2B,EAAA,IAAW,MAAO,KAAK,eAAe,CAAC,OAAO,EAAA,GAAA,EAAA,UAAA,CAAA,OAAA,EAAA,CAAA,OAAA,GAAA,UAAA,CAAA,CAAA,CAClF,GAAQ,EAAC,KAAU,CACb,IAAG,EAAA,EAAe,KAAG,QAAO,OAAW,KAAO,EAAM,OAAM,IAAO,OAAA,KAAA,IAAA,CAAA,IAAA,CAAA,GAAA,CAEjE,GADA,EAAG,EAAe,MAAO,wBAAuB,EAAM,YAAM,EAAA,UAAA,eAAA,GAAA,CACzD,EAAA,IAAA,MAAmB,KAAK,YAAU,EAAO,EAAA,EAAA,KAAA,EAAA,GAAA,EAAA,UAAA,CAAA,SAAA,EAAA,CAAA,CAAA,OAAA,GAAA,UAAA,CAAA,CAAA,CAAA,kIAEjD,GAAA,CAAA,GAAA,EAAA,WAAA,CACM,OAMA,GAJG,EAAW,IAAC,KAAM,IAAK,YAAA,EAAA,GAC7B,EAAQ,EAAgB,MAAC,WAAA,EAAA,oCAAA,EAAA,UAAA,eAAA,wDAAA,CAC3B,EAAA,IAAA,KAAA,IAAA,YAAA,EAAA,SAAA,EAEK,EAAA,OAAA,IAAA,QAAA,EAAA,CACG,IAAA,EAAY,EAAE,IAAA,SAAA,GACpB,GAAS,IAAU,IAAA,GAAA,CACX,IAAE,EAAU,EAAA,OAAA,IAAA,OAAA,KAAA,EAAA,GACZ,EAAe,IAAA,OAAA,GAAA,EAAA,QAAA,MAAA,GAAA,CAAA,GAAA,KACrB,CAAA,MAAe,GAAK,UAAA,CAAA,CAAA,CACpB,IACA,EAAA,EAAA,IAAA,OAAA,GAAA,EAAA,QAAA,MAAA,GAAA,CAAA,GAAA,SAGG,IAAW,EAAS,iBAAoB,iCAEvC,MAAW,MAAA,0BAAA,EAAA,mDAAA,CAEX,OAAI,EAAoB,EAAkB,EAAM,UAEjD,EAAA,OAAA,IAAA,SAAA,MAAA,MAAA,QAAA,EAAA,4GAAA,EAAA,SAAA,EAAA,SAAA,UAAA;;wGAGoB,EAAA,IAAA,MAAA,KAAA,kBAAA,CAAA,KAAA,GAAA,EAAA,IAAA,OAAA,EAAA,CAAA,cAAA,OAAA,EAAA,CAAA,CAAA,CAAA,IAAA,IAAA,GAAA,aAAA,CAAA,CAAA,CAAA,IAAA,EAAA,GAAA,MAAA,OAAA,EAAA,CAAA,GAAA,EAAA,KAAA,EAAA,GAAA,EAAA,iBAAA,GAAA,OAAA,EAAA,EAAA,EAAA,UAAA,CAAA,OAAA,EAAA,CAAA,OAAA,GAAA,UAAA,CAAA,CAAA,CAAA,WAAA,GAAA,KAAA,EAAA,GAAA,EAAA,iBAAA,GAAA,OAAA,EAAA,CAAA,CAAA,OAAA,GAAA,UAAA,CAAA,CAAA,EAAA,UAAA,CAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,UAAA,GAAA,UAAA,CAAA,CAAA,CAAA,KAAA;EAAA,CAAA,yCAAA,EAAA,OAAA,IAAA,OAAA,IAAA,EAAA,GAAA,MAAA,IAAA,CAAA,SAAA,GAAA,UAAA,CAAA,CAAA,CAAA,KAAA;EAAA,CAAA,uLAAA,MAClB,EAAW,UAAY,GAC1B,EAAQ,KAAC,QAAY,EAAC,yDAAY,EAAA,SAAA,kSAAA,EAMxC,MADA,GAAQ,OAAY,CAAA,OAAS,OAAE,eAAmB,iBAAA,aAAA,mBAAA,CAC3C,CACL,QAAM,CACJ,iBAAU,EAAqB,SAA0B,EAAK,EAAA,CAC5D,GAAI,EAAE,IAAO,SAAK,EAAM,IAAI,WAAW,EAAC,aAAI,CAC1C,KAAI,MACL,CAAC,EAAI,EAAE,IAAK,SAAW,EAAA,IAAA,SAAa,EAAA,aAAA,CACnC,KAAK,UACN,CAAC,EAAI,EAAC,IAAA,WAAe,EAAA,cAAY,CAAU,CAE1C,IAAA,EAAA,EAAA,IAAA,WAAA,EAAA,gBAEE,OAEF,EAAI,EAAmB,EAAA,GAAA,GAAA,CACvB,EAAK,wBAAiB,OAAY,EAAU,OAAU,CACtD,EAAU,EAAC,CACT,OAAQ,GAAA,EAAK,OAAY,WAAc,aAAW,MAClD,KAAC,qBAEF,CAAC,SACF,EAAA,IAAA,SAAA,EAAA,IAAA,WAAA,EAAA,aAAA,CAAA,KAAA,MAED,CAAC,EAAI,EAAA,IAAQ,SAAU,EAAC,IAAA,SAAU,EAAA,gBAAc,EAAA,EAAA,IAAA,WAAA,EAAA,cAAA,CAAA,CAE/C,IAAM,EAAU,EAAA,IAAW,WAAA,EAAA,KAC3B,GAAI,CAAA,EAAY,KACd,OAEF,EAAQ,EAAQ,EAAA,GAAA,GAAA,CAChB,EAAK,wBAAO,OAAA,EAAA,OAAA,CACZ,EAAQ,EAAQ,CACd,OAAE,GAAA,EAAA,OAAA,WAAA,aAAA,MACF,KAAA,qBAED,CAAC,wCAEF,KAAM,MACP,CAAC,EAAI,EAAK,IAAI,WAAM,EAAA,cAAA,CAAA,CAEnB,IAAK,EAAA,EAAA,IAAA,WAAA,EAAA,KACL,GAAE,CAAA,EAAA,KAAA,OAGF,EAAA,EAAA,EAAA,GAAA,GAAA,GAED,CAAC,WAAU,OAAK,OAAA,mBAAA,eAAA,CAAA,CACpB,CACF,EACA,CAAC,SAAS,GAAA,UAAA,CAAA,CAAA"}
@@ -1 +0,0 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`../_virtual/_rolldown/runtime.cjs`);const e=require(`../types/plugin.cjs`);let t=require(`@powerlines/deepkit/vendor/type`),n=require(`powerlines/plugin-utils`),r=require(`@alloy-js/core/jsx-runtime`),i=require(`@alloy-js/core`),a=require(`@alloy-js/markdown`),o=require(`@powerlines/plugin-alloy/core/components/spacing`),s=require(`@powerlines/plugin-alloy/core/contexts/context`),c=require(`@powerlines/plugin-alloy/markdown/components/heading`),l=require(`@powerlines/plugin-alloy/markdown/components/markdown-file`),u=require(`@powerlines/plugin-alloy/markdown/components/markdown-table`),d=require(`@stryke/path/join`);const f=[`T`,`Partial`,`l+e#!e"!fRb!Pde"!gN#"w"y`];function p(e,t){return e.__type=t,e}const m=[()=>f,`levelOffset`,0,`The heading level offset to apply to the generated documentation.`,`reflection`,`EnvDocsFileProps`,`P!o!"'4"8>#?$!4%Mw&y`];function h(f){let{levelOffset:m=0,reflection:h,...g}=f,_=(s.usePowerlines.Ω=[[()=>e.__ΩEnvPluginContext,`n!`]],(0,s.usePowerlines)());return(0,r.createComponent)(l.MarkdownFile,(0,r.mergeProps)({get path(){return(0,d.joinPaths)((0,n.getDocsOutputPath)(_.config.root),`env.md`)}},g,{get children(){return[(0,r.createComponent)(c.Heading,{level:1+m,children:`Environment Configuration`}),i.code`Below is a list of environment variables used by the`,(0,r.createComponent)(i.Show,{get when(){return!!_.packageJson.name},get children(){return(0,r.createComponent)(a.Link,{get href(){return`https://www.npmjs.com/package/${_.packageJson.name}`},get title(){return _.packageJson.name}})}}),i.code`package. These values can be updated in the \`.env\` file in the root of the project.`,(0,r.createComponent)(o.Spacing,{}),(0,r.createComponent)(c.Heading,{level:2+m,children:`Environment Variables`}),(0,r.createComponent)(o.Spacing,{}),i.code`The below list of environment variables are used as configuration parameters to drive the processing of the application. The data contained in these variables are **not** considered sensitive or confidential. Any values provided in these variables will be available in plain text.`,(0,r.createComponent)(o.Spacing,{}),(0,r.createComponent)(u.MarkdownTable,{get data(){return h?.getProperties().filter(p(e=>!e.isHidden()&&!e.isIgnored()&&!e.isReadonly()&&!e.isInternal(),[`property`,``,`P"2!"/"`])).sort(p((e,t)=>e.getNameAsString().localeCompare(t.getNameAsString()),[`a`,`b`,``,`P"2!"2""/#`])).map(p(e=>({name:e.getNameAsString().trim(),description:(e.getDescription()??``).trim(),type:(0,t.stringifyType)(e.getType()).trim().replaceAll(/\s*(?:\||&)\s*/g,`, or `),defaultValue:e.hasDefault()?String(e.getDefaultValue())?.includes(`"`)?e.getDefaultValue():`\`${e.getDefaultValue()}\``:``,required:e.isValueRequired()?``:`✔`}),[`reflectionProperty`,``,`P"2!"/"`]))??[]}})]}}))}h.__type=[()=>m,`props`,`EnvDocsFile`,`Generates the environment configuration markdown documentation for the Powerlines project.`,`Pn!2""/#?$`],exports.EnvDocsFile=h,exports.__ΩEnvDocsFileProps=m;
@@ -1,24 +0,0 @@
1
- import * as _$_alloy_js_core0 from "@alloy-js/core";
2
- import { ReflectionClass } from "@powerlines/deepkit/vendor/type";
3
- import { MarkdownFileProps } from "@powerlines/plugin-alloy/markdown/components/markdown-file";
4
-
5
- //#region src/components/docs.d.ts
6
- interface EnvDocsFileProps extends Partial<MarkdownFileProps> {
7
- /**
8
- * The heading level offset to apply to the generated documentation.
9
- *
10
- * @remarks
11
- * This is useful when nesting the documentation within other markdown files.
12
- *
13
- * @defaultValue 0
14
- */
15
- levelOffset?: number;
16
- reflection: ReflectionClass<any>;
17
- }
18
- /**
19
- * Generates the environment configuration markdown documentation for the Powerlines project.
20
- */
21
- declare function EnvDocsFile(props: EnvDocsFileProps): _$_alloy_js_core0.Children;
22
- //#endregion
23
- export { EnvDocsFile, EnvDocsFileProps };
24
- //# sourceMappingURL=docs.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"docs.d.cts","names":[],"sources":["../../src/components/docs.tsx"],"mappings":";;;;;UAoCiB,gBAAA,SAAyB,OAAA,CAAQ,iBAAA;;;AAAlD;;;;;;EASE,WAAA;EAEA,UAAA,EAAY,eAAA;AAAA;;;;iBAME,WAAA,CAAY,KAAA,EAAO,gBAAA,GAAgB,iBAAA,CAAA,QAAA"}
@@ -1,24 +0,0 @@
1
- import { ReflectionClass } from "@powerlines/deepkit/vendor/type";
2
- import * as _$_alloy_js_core0 from "@alloy-js/core";
3
- import { MarkdownFileProps } from "@powerlines/plugin-alloy/markdown/components/markdown-file";
4
-
5
- //#region src/components/docs.d.ts
6
- interface EnvDocsFileProps extends Partial<MarkdownFileProps> {
7
- /**
8
- * The heading level offset to apply to the generated documentation.
9
- *
10
- * @remarks
11
- * This is useful when nesting the documentation within other markdown files.
12
- *
13
- * @defaultValue 0
14
- */
15
- levelOffset?: number;
16
- reflection: ReflectionClass<any>;
17
- }
18
- /**
19
- * Generates the environment configuration markdown documentation for the Powerlines project.
20
- */
21
- declare function EnvDocsFile(props: EnvDocsFileProps): _$_alloy_js_core0.Children;
22
- //#endregion
23
- export { EnvDocsFile, EnvDocsFileProps };
24
- //# sourceMappingURL=docs.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"docs.d.mts","names":[],"sources":["../../src/components/docs.tsx"],"mappings":";;;;;UAoCiB,gBAAA,SAAyB,OAAA,CAAQ,iBAAA;;;AAAlD;;;;;;EASE,WAAA;EAEA,UAAA,EAAY,eAAA;AAAA;;;;iBAME,WAAA,CAAY,KAAA,EAAO,gBAAA,GAAgB,iBAAA,CAAA,QAAA"}
@@ -1,2 +0,0 @@
1
- import{__ΩEnvPluginContext as e}from"../types/plugin.mjs";import{stringifyType as t}from"@powerlines/deepkit/vendor/type";import{getDocsOutputPath as n}from"powerlines/plugin-utils";import{createComponent as r,mergeProps as i}from"@alloy-js/core/jsx-runtime";import{Show as a,code as o}from"@alloy-js/core";import{Link as s}from"@alloy-js/markdown";import{Spacing as c}from"@powerlines/plugin-alloy/core/components/spacing";import{usePowerlines as l}from"@powerlines/plugin-alloy/core/contexts/context";import{Heading as u}from"@powerlines/plugin-alloy/markdown/components/heading";import{MarkdownFile as d}from"@powerlines/plugin-alloy/markdown/components/markdown-file";import{MarkdownTable as f}from"@powerlines/plugin-alloy/markdown/components/markdown-table";import{joinPaths as p}from"@stryke/path/join";const m=[`T`,`Partial`,`l+e#!e"!fRb!Pde"!gN#"w"y`];function h(e,t){return e.__type=t,e}const g=[()=>m,`levelOffset`,0,`The heading level offset to apply to the generated documentation.`,`reflection`,`EnvDocsFileProps`,`P!o!"'4"8>#?$!4%Mw&y`];function _(m){let{levelOffset:g=0,reflection:_,...v}=m,y=(l.Ω=[[()=>e,`n!`]],l());return r(d,i({get path(){return p(n(y.config.root),`env.md`)}},v,{get children(){return[r(u,{level:1+g,children:`Environment Configuration`}),o`Below is a list of environment variables used by the`,r(a,{get when(){return!!y.packageJson.name},get children(){return r(s,{get href(){return`https://www.npmjs.com/package/${y.packageJson.name}`},get title(){return y.packageJson.name}})}}),o`package. These values can be updated in the \`.env\` file in the root of the project.`,r(c,{}),r(u,{level:2+g,children:`Environment Variables`}),r(c,{}),o`The below list of environment variables are used as configuration parameters to drive the processing of the application. The data contained in these variables are **not** considered sensitive or confidential. Any values provided in these variables will be available in plain text.`,r(c,{}),r(f,{get data(){return _?.getProperties().filter(h(e=>!e.isHidden()&&!e.isIgnored()&&!e.isReadonly()&&!e.isInternal(),[`property`,``,`P"2!"/"`])).sort(h((e,t)=>e.getNameAsString().localeCompare(t.getNameAsString()),[`a`,`b`,``,`P"2!"2""/#`])).map(h(e=>({name:e.getNameAsString().trim(),description:(e.getDescription()??``).trim(),type:t(e.getType()).trim().replaceAll(/\s*(?:\||&)\s*/g,`, or `),defaultValue:e.hasDefault()?String(e.getDefaultValue())?.includes(`"`)?e.getDefaultValue():`\`${e.getDefaultValue()}\``:``,required:e.isValueRequired()?``:`✔`}),[`reflectionProperty`,``,`P"2!"/"`]))??[]}})]}}))}_.__type=[()=>g,`props`,`EnvDocsFile`,`Generates the environment configuration markdown documentation for the Powerlines project.`,`Pn!2""/#?$`];export{_ as EnvDocsFile,g as __ΩEnvDocsFileProps};
2
- //# sourceMappingURL=docs.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"docs.mjs","names":[],"sources":["../../src/components/docs.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, Show } from \"@alloy-js/core\";\nimport { Link } from \"@alloy-js/markdown\";\nimport {\n ReflectionClass,\n stringifyType\n} from \"@powerlines/deepkit/vendor/type\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core/components/spacing\";\nimport { usePowerlines } from \"@powerlines/plugin-alloy/core/contexts/context\";\nimport { Heading } from \"@powerlines/plugin-alloy/markdown/components/heading\";\nimport {\n MarkdownFile,\n MarkdownFileProps\n} from \"@powerlines/plugin-alloy/markdown/components/markdown-file\";\nimport { MarkdownTable } from \"@powerlines/plugin-alloy/markdown/components/markdown-table\";\nimport { joinPaths } from \"@stryke/path/join\";\nimport { getDocsOutputPath } from \"powerlines/plugin-utils\";\nimport { EnvPluginContext } from \"../types/plugin\";\n\nexport interface EnvDocsFileProps extends Partial<MarkdownFileProps> {\n /**\n * The heading level offset to apply to the generated documentation.\n *\n * @remarks\n * This is useful when nesting the documentation within other markdown files.\n *\n * @defaultValue 0\n */\n levelOffset?: number;\n\n reflection: ReflectionClass<any>;\n}\n\n/**\n * Generates the environment configuration markdown documentation for the Powerlines project.\n */\nexport function EnvDocsFile(props: EnvDocsFileProps) {\n const { levelOffset = 0, reflection, ...rest } = props;\n\n const context = usePowerlines<EnvPluginContext>();\n\n return (\n <MarkdownFile\n path={joinPaths(getDocsOutputPath(context.config.root), \"env.md\")}\n {...rest}>\n <Heading level={1 + levelOffset}>Environment Configuration</Heading>\n {code`Below is a list of environment variables used by the`}\n <Show when={!!context.packageJson.name}>\n <Link\n href={`https://www.npmjs.com/package/${context.packageJson.name}`}\n title={context.packageJson.name!}\n />\n </Show>\n {code`package. These values can be updated in the \\`.env\\` file in the root of the project.`}\n <Spacing />\n <Heading level={2 + levelOffset}>Environment Variables</Heading>\n <Spacing />\n {code`The below list of environment variables are used as configuration parameters to drive the processing of the application. The data contained in these variables are **not** considered sensitive or confidential. Any values provided in these variables will be available in plain text.`}\n <Spacing />\n <MarkdownTable\n data={\n reflection\n ?.getProperties()\n .filter(\n property =>\n !property.isHidden() &&\n !property.isIgnored() &&\n !property.isReadonly() &&\n !property.isInternal()\n )\n .sort((a, b) =>\n a.getNameAsString().localeCompare(b.getNameAsString())\n )\n .map(reflectionProperty => {\n return {\n name: reflectionProperty.getNameAsString().trim(),\n description: (reflectionProperty.getDescription() ?? \"\").trim(),\n type: stringifyType(reflectionProperty.getType())\n .trim()\n .replaceAll(/\\s*(?:\\||&)\\s*/g, \", or \"),\n defaultValue: reflectionProperty.hasDefault()\n ? String(reflectionProperty.getDefaultValue())?.includes('\"')\n ? reflectionProperty.getDefaultValue()\n : `\\`${reflectionProperty.getDefaultValue()}\\``\n : \"\",\n required: reflectionProperty.isValueRequired() ? \"\" : \"✔\"\n };\n }) ?? []\n }\n />\n </MarkdownFile>\n );\n}\n"],"mappings":"61BAIA,SAAM,EAAS,EAAW,EAAM,CAE/B,MADA,GAAG,OAAU,EACL,6JAkCT,SAAM,EAAA,EAAA,CACJ,GAAG,CACF,cAAA,EACC,aACA,GAAA,GACF,6BAEA,OAAA,EAAY,EAAoB,EAAA,CAClC,IAAA,MAAA,sCAGG,CAAA,EAAA,CACD,IAAA,UAAA,CACI,MAAC,CAAA,EAAqB,EAAO,CAC3B,MAAE,EAAA,uCAEH,CAAC,CAAA,CAAA,uDAA2C,EAAA,EAAA,YAE1C,MAAA,CAAA,CAAA,EAAA,YAAA,MAEH,IAAM,UAAU,CACZ,OAAK,EAAA,EAAA,CACR,IAAQ,MAAQ,CACX,MAAS,iCAAgC,EAAQ,YAAI,QAExD,IAAA,OAAA,CACK,OAAG,EAAY,YAAU,MAE9B,CAAA,EAEF,CAAA,CAAA,CAAK,wFAAsF,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA,EAAA,CAC3F,MAAQ,EAAC,EACT,SAAQ,wBACR,CAAA,CAAA,EAAS,EAAA,EAAA,CAAA,CAAA,CAAA,2RAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA,EAAA,CACT,IAAK,MAAI,CACT,OAAS,GAAA,eAAA,CAAA,OAAA,EAAA,GAAA,CAAA,EAAA,UAAA,EAAA,CAAA,EAAA,WAAA,EAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,YAAA,CAAA,CAAA,WAAA,GAAA,UAAA,CAAA,CAAA,CAAA,KAAA,GAAA,EAAA,IAAA,EAAA,iBAAA,CAAA,cAAA,EAAA,iBAAA,CAAA,CAAA,CAAA,IAAA,IAAA,GAAA,aAAA,CAAA,CAAA,CAAA,IAAA,EAAA,IACT,CACM,KAAA,EAAA,iBAAA,CAAA,MAAA,CACH,aAAA,EAAA,gBAAA,EAAA,IAAA,MAAA,CACI,KAAA,EAAc,EAAA,SAAA,CAAA,CAAA,MAAA,CAAA,WAAA,kBAAA,QAAA,CACf,aAAM,EAAA,YAAA,CAAA,OAAA,EAAA,iBAAA,CAAA,EAAA,SAAA,IAAA,CAAA,EAAA,iBAAA,CAAA,KAAA,EAAA,iBAAA,CAAA,IAAA,GACL,SAAU,EAAA,iBAAA,CAAA,GAAA,IACX,EACA,CAAC,qBAAsB,GAAG,UAAA,CAAA,CAAA,EAAA,EAAA,EAEhC,CAAC,CAAC,EAEN,CAAC,CAAC,CAEL,EAAY,OAAA,KAAA,EAAA,QAAA,cAAA,6FAAA,aAAA"}
@@ -1,98 +0,0 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`../_virtual/_rolldown/runtime.cjs`),t=require(`../types/plugin.cjs`),n=require(`../helpers/load.cjs`);let r=require(`@stryke/string-format/title-case`),i=require(`@powerlines/deepkit/vendor/type`),a=require(`defu`);a=e.__toESM(a);let o=require(`@alloy-js/core/jsx-runtime`),s=require(`@alloy-js/core`),c=require(`@powerlines/plugin-alloy/core/components/spacing`),l=require(`@powerlines/plugin-alloy/core/contexts/context`),u=require(`@alloy-js/typescript`),d=require(`@powerlines/plugin-alloy/helpers/refkey`),f=require(`@powerlines/plugin-alloy/typescript/components/builtin-file`),p=require(`@powerlines/plugin-alloy/typescript/components/interface-declaration`),m=require(`@powerlines/plugin-alloy/typescript/components/object-declaration`),h=require(`@powerlines/plugin-alloy/typescript/components/tsdoc`),g=require(`@powerlines/plugin-alloy/typescript/components/tsdoc-reflection`),_=require(`@stryke/helpers/get-unique`);const v=[`T`,`K`,()=>y,()=>b,`Omit`,`b!b"e!!e!!ge!"o$#o##w%y`],y=[`T`,`K`,`Pick`,`l+e#!e"!fRb!b"Pde""N#!w#y`],b=[`T`,`U`,`Exclude`,`l6!Re$!RPe#!e$"qk#%QRb!b"Pde"!p)w#y`];function x(e,t){return e.__type=t,e}function S(e){let[{defaultValue:n,reflection:r}]=(0,s.splitProps)(e,[`defaultValue`,`reflection`]),i=(l.usePowerlines.Ω=[[()=>t.__ΩEnvPluginContext,`n!`]],(0,l.usePowerlines)());return[(0,o.createComponent)(p.InterfaceDeclaration,{name:`UnprefixedEnv`,defaultValue:n,reflection:r,export:!0}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:`The environment configuration object with prefixed keys.`,get children(){return(0,o.createComponent)(h.TSDocRemarks,{children:"The `Env` type extends the `UnprefixedEnv` interface by including additional keys that are prefixed according to the project's configuration. This allows for flexibility in accessing environment variables with different naming conventions."})}}),(0,o.createComponent)(u.InterfaceDeclaration,{name:`Env`,export:!0,extends:`UnprefixedEnv`,get children(){return(0,o.createComponent)(s.For,{get each(){return(0,_.getUnique)(i.config.env.prefix).map(x(e=>e.replace(/_$/,``),[`prefix`,``,`P"2!"/"`]))},doubleHardline:!0,get children(){return x(e=>(0,o.createComponent)(s.For,{get each(){return r?.getProperties().filter(x(e=>!e.isIgnored(),[`property`,``,`P"2!"/"`]))??[]},doubleHardline:!0,get children(){return x(t=>[(0,o.createComponent)(g.TSDocReflectionProperty,{reflection:t}),(0,o.createComponent)(u.InterfaceMember,{get name(){return`${e}_${t.getNameAsString()}`},get type(){return`UnprefixedEnv["${t.getNameAsString()}"]`},get readonly(){return t.isReadonly()}})],[`property`,``,`P"2!"/"`])}}),[`prefix`,``,`P"2!"/"`])}})}}),(0,o.createComponent)(c.Spacing,{})]}S.__type=[()=>v,`name`,`props`,`EnvTypeDefinition`,`Generates the environment configuration typescript definition for the Powerlines project.`,`P!."o!#2#"/$?%`];const C=[()=>t.__ΩEnvPluginContext,`context`,`name`,`ConfigPropertyConditionalProps`,`P!n!4"&4#Mw$y`];function w(e){let[{context:t,name:n}]=(0,s.splitProps)(e,[`context`,`name`]);return s.code`propertyName === "${n}" || propertyName.replace(/^(${(0,_.getUnique)(t.config.env.prefix.sort(x((e,t)=>e.startsWith(t)?-1:t.startsWith(e)?1:e.localeCompare(t),[`a`,`b`,``,`P"2!"2""/#`])).map(x(e=>`${e.replace(/_$/,``)}_`,[`prefix`,``,`P"2!"/"`]))).join(`|`)})/g, "").toLowerCase().replace(/[\\s\\-_]+/g, "") === "${n.toLowerCase().replace(/[\s\-_]+/g,``)}"`}w.__type=[()=>C,`props`,`ConfigPropertyConditional`,`Pn!2""/#`];const T=[`index`,()=>t.__ΩEnvPluginContext,`context`,`property`,`ConfigPropertyProps`,`P!'4!n"4#!4$Mw%y`];function E(e){let[{context:t,property:n,index:r}]=(0,s.splitProps)(e,[`context`,`property`,`index`]);return[r===0?(0,o.createComponent)(u.IfStatement,{get condition(){return[(0,o.createComponent)(w,{get name(){return n.getNameAsString()},context:t}),(0,o.createComponent)(s.Show,{get when(){return(0,o.memo)(()=>!!n.getAlias())()&&n.getAlias().length>0},get children(){return[s.code` || `,(0,o.createComponent)(s.For,{get each(){return n.getAlias()},joiner:s.code` || `,get children(){return x(e=>(0,o.createComponent)(w,{name:e,context:t}),[`alias`,``,`P"2!"/"`])}})]}})]},get children(){return s.code`return target["${n.getNameAsString()}"];`}}):(0,o.createComponent)(u.ElseIfClause,{get condition(){return[(0,o.createComponent)(w,{get name(){return n.getNameAsString()},context:t}),(0,o.createComponent)(s.Show,{get when(){return(0,o.memo)(()=>!!n.getAlias())()&&n.getAlias().length>0},get children(){return[s.code` || `,(0,o.createComponent)(s.For,{get each(){return n.getAlias()},joiner:s.code` || `,get children(){return x(e=>(0,o.createComponent)(w,{name:e,context:t}),[`alias`,``,`P"2!"/"`])}})]}})]},get children(){return s.code`return target["${n.getNameAsString()}"];`}})]}E.__type=[()=>T,`props`,`ConfigPropertyGet`,`Pn!2""/#`];function D(e){let[{context:t,property:n,index:r}]=(0,s.splitProps)(e,[`context`,`property`,`index`]);return[r===0?(0,o.createComponent)(u.IfStatement,{get condition(){return[(0,o.createComponent)(w,{get name(){return n.getNameAsString()},context:t}),(0,o.createComponent)(s.Show,{get when(){return(0,o.memo)(()=>!!n.getAlias())()&&n.getAlias().length>0},get children(){return[s.code` || `,(0,o.createComponent)(s.For,{get each(){return n.getAlias()},joiner:s.code` || `,get children(){return x(e=>(0,o.createComponent)(w,{name:e,context:t}),[`alias`,``,`P"2!"/"`])}})]}})]},get children(){return s.code`
2
- target["${n.getNameAsString()}"] = newValue;
3
- return true;
4
- `}}):(0,o.createComponent)(u.ElseIfClause,{get condition(){return[(0,o.createComponent)(w,{get name(){return n.getNameAsString()},context:t}),(0,o.createComponent)(s.Show,{get when(){return(0,o.memo)(()=>!!n.getAlias())()&&n.getAlias().length>0},get children(){return[s.code` || `,(0,o.createComponent)(s.For,{get each(){return n.getAlias()},joiner:s.code` || `,get children(){return x(e=>(0,o.createComponent)(w,{name:e,context:t}),[`alias`,``,`P"2!"/"`])}})]}})]},get children(){return s.code`
5
- target["${n.getNameAsString()}"] = newValue;
6
- return true;
7
- `}})]}D.__type=[()=>T,`props`,`ConfigPropertySet`,`Pn!2""/#`];const O=[()=>v,`id`,`Children`,`defaultConfig`,`reflection`,`EnvBuiltinProps`,`P!."o!#"w#4$8!4%Mw&y`],k=(0,d.refkey)(`createEnv`),A=(0,d.refkey)(`env`),j=(0,d.refkey)(`EnvSerializer`);function M(e){let[{defaultConfig:d,reflection:p,children:g},v]=(0,s.splitProps)(e,[`defaultConfig`,`reflection`,`children`]),y=(l.usePowerlines.Ω=[[()=>t.__ΩEnvPluginContext,`n!`]],(0,l.usePowerlines)()),b=(0,s.computed)(()=>y&&n.loadEnvFromContext(y,process.env)),C=(0,s.computed)(()=>{let e=new i.ReflectionClass({kind:i.ReflectionKind.objectLiteral,description:`The initial environment configuration state for the ${(0,r.titleCase)(y?.config?.name)} project.`,types:[]},p);return e.getProperties().filter(x(e=>e.isRuntime()||e.getTags().runtime===!0,[`property`,``,`P"2!"/"`])).forEach(x(t=>{e.removeProperty(t.getNameAsString())},[`property`,``,`P"2!"/"`])),e}),w=(0,s.computed)(()=>p?.getProperties().filter(x(e=>!e.isIgnored(),[`property`,``,`P"2!"/"`])).sort(x((e,t)=>e.getNameAsString().localeCompare(t.getNameAsString()),[`a`,`b`,``,`P"2!"2""/#`]))??[]),T=(0,s.computed)(()=>p?.getProperties().filter(x(e=>!e.isIgnored()&&!e.isReadonly(),[`property`,``,`P"2!"/"`])).sort(x((e,t)=>e.getNameAsString().localeCompare(t.getNameAsString()),[`a`,`b`,``,`P"2!"2""/#`]))??[]);return(0,o.createComponent)(f.BuiltinFile,(0,o.mergeProps)({id:`env`,description:`The environment configuration module provides an interface to define environment configuration parameters.`},v,{get imports(){return(0,a.default)({"@powerlines/deepkit/vendor/type":[`serializeFunction`,`deserializeFunction`,`ReflectionKind`,`Serializer`,`NamingStrategy`,`TemplateState`,`Type`,`TypeProperty`,`TypePropertySignature`]},v.imports??{})},get children(){return[(0,o.createComponent)(s.Show,{get when(){return!!p},get children(){return[(0,o.createComponent)(S,{defaultValue:b,reflection:p}),(0,o.createIntrinsic)(`hbr`,{}),(0,o.createIntrinsic)(`hbr`,{})]}}),(0,o.createComponent)(m.ObjectDeclaration,{name:`initialEnv`,type:`Partial<Env>`,defaultValue:b,reflection:C,export:!0,const:!0,doc:`The initial environment configuration object values for the runtime.`}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:`The environment configuration serializer for the Powerlines application.`,get children(){return[(0,o.createComponent)(h.TSDocLink,{children:`https://deepkit.io/docs/serialization/serializers`}),(0,o.createComponent)(h.TSDocLink,{children:`https://github.com/marcj/untitled-code/blob/master/packages/type/src/serializer.ts#L1918`}),(0,o.createComponent)(h.TSDocRemarks,{children:`This serializer is used to serialize and deserialize the Powerlines environment configuration.`})]}}),(0,o.createComponent)(u.ClassDeclaration,{refkey:j,name:`EnvSerializer`,extends:`Serializer`,export:!0,get children(){return(0,o.createComponent)(u.ClassMethod,{name:`constructor`,public:!0,doc:"Initializes a new instance of the `EnvSerializer` class.",children:s.code`super("env");
8
-
9
- this.deserializeRegistry.register(
10
- ReflectionKind.boolean,
11
- (type: Type, state: TemplateState) => {
12
- state.addSetter(
13
- \`typeof \${state.accessor.toString()} !== "boolean" ? \${state.accessor.toString()} === 1 || \${state.accessor.toString()} === "1" || \${state.accessor.toString()}.toLowerCase() === "t" || \${state.accessor.toString()}.toLowerCase() === "true" || \${state.accessor.toString()}.toLowerCase() === "y" || \${state.accessor.toString()}.toLowerCase() === "yes" : \${state.accessor.toString()}\`
14
- );
15
- }
16
- ); `})}}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{name:`envNamingStrategy`,const:!0,doc:`The environment naming strategy for the runtime.`,get initializer(){return s.code`new class extends NamingStrategy {
17
- constructor() {
18
- super("env");
19
- }
20
-
21
- getPropertyName(type: TypeProperty | TypePropertySignature, forSerializer: string): string | undefined {
22
- const name = super.getPropertyName(type, forSerializer);
23
- if (!name) {
24
- return name;
25
- }
26
-
27
- return name.replace(/^(${(0,_.getUnique)(y.config.env.prefix).map(x(e=>e.replace(/_$/,``),[`prefix`,``,`P"2!"/"`])).join(`|`)})_/, "");
28
- }
29
- }; `}}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:`A {@link EnvSerializer | environment configuration serializer} instance for the Powerlines application.`,get children(){return[(0,o.createComponent)(h.TSDocLink,{children:`https://deepkit.io/docs/serialization/serializers`}),(0,o.createComponent)(h.TSDocLink,{children:`https://github.com/marcj/untitled-code/blob/master/packages/type/src/serializer.ts#L1918`}),(0,o.createComponent)(h.TSDocRemarks,{children:`This serializer is used to serialize and deserialize the Powerlines environment configuration.`})]}}),(0,o.createComponent)(u.VarDeclaration,{name:`envSerializer`,const:!0,get initializer(){return(0,o.createComponent)(u.NewExpression,{args:[],target:`EnvSerializer`})}}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{name:`_serializeEnv`,const:!0,initializer:`serializeFunction<Env>(envSerializer, envNamingStrategy)`}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:`Serialize a environment configuration object to JSON data objects (not a JSON string).`,get children(){return[(0,o.createComponent)(h.TSDocRemarks,{children:"The resulting JSON object can be stringified using `JSON.stringify()`."}),(0,o.createComponent)(h.TSDocExample,{children:`const json = serializeEnv(env);`}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDocParam,{name:`input`,children:`The environment configuration object to serialize.`}),(0,o.createComponent)(h.TSDocReturns,{children:`The serialized environment configuration as JSON data objects.`}),(0,o.createComponent)(h.TSDocThrows,{children:`ValidationError when serialization or validation fails.`})]}}),(0,o.createComponent)(u.FunctionDeclaration,{name:`serializeEnv`,export:!0,parameters:[{name:`input`,type:`Env`}],children:s.code` return _serializeEnv(input, { loosely: true }); `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{name:`_deserializeEnv`,const:!0,initializer:`deserializeFunction<Env>(envSerializer, envNamingStrategy)`}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:`Deserialize a environment configuration object from JSON data objects to JavaScript objects, without running any validators.`,get children(){return[(0,o.createComponent)(h.TSDocRemarks,{children:`Types that are already correct will be used as-is.`}),(0,o.createComponent)(h.TSDocExample,{children:`const env = deserializeEnv(json);`}),(0,o.createComponent)(h.TSDocThrows,{children:`ValidationError when deserialization fails.`})]}}),(0,o.createComponent)(u.FunctionDeclaration,{name:`deserializeEnv`,export:!0,parameters:[{name:`input`,type:`Env`}],children:s.code` return _deserializeEnv(input, { loosely: true }); `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:`Initializes the Powerlines environment configuration module.`,get children(){return[(0,o.createComponent)(h.TSDocRemarks,{children:`This function initializes the Powerlines environment configuration object.`}),(0,o.createComponent)(h.TSDocParam,{name:`environmentConfig`,children:`The dynamic/runtime configuration - this could include the current environment variables or any other environment-specific settings provided by the runtime.`}),(0,o.createComponent)(h.TSDocReturns,{children:`The initialized Powerlines configuration object.`})]}}),(0,o.createComponent)(s.Show,{get when(){return!!y?.entryPath},get children(){return(0,o.createComponent)(u.FunctionDeclaration,{refkey:k,async:!1,export:!0,name:`createEnv`,parameters:[{name:`environmentConfig`,type:`Partial<Env>`,optional:!1,default:`{}`}],returnType:`Env`,get children(){return[s.code`
30
- return new Proxy<Env>(
31
- deserializeEnv({
32
- ...initialEnv,
33
- ...environmentConfig
34
- } as Env),
35
- {
36
- get: (target: UnprefixedEnv, propertyName: string) => { `,(0,o.createIntrinsic)(`hbr`,{}),(0,o.createComponent)(s.For,{each:w,get children(){return x((e,t)=>(0,o.createComponent)(E,{index:t,context:y,property:e}),[`property`,`index`,``,`P!2!'2""/#`])}}),s.code`
37
- return undefined;
38
- }, `,(0,o.createComponent)(c.Spacing,{}),s.code` set: (target: UnprefixedEnv, propertyName: string, newValue: any) => { `,(0,o.createIntrinsic)(`hbr`,{}),(0,o.createComponent)(s.For,{each:T,ender:s.code` else `,get children(){return x((e,t)=>(0,o.createComponent)(D,{index:t,context:y,property:e}),[`property`,`index`,``,`P!2!'2""/#`])}}),(0,o.createIntrinsic)(`hbr`,{}),s.code`return false;
39
- }
40
- }
41
- );
42
- `]}})}}),(0,o.createComponent)(c.Spacing,{}),(0,o.createIntrinsic)(`hbr`,{}),(0,o.createComponent)(h.TSDoc,{heading:`The environment configuration object.`,get children(){return(0,o.createComponent)(h.TSDocRemarks,{children:`This object provides access to the environment configuration parameters in the application runtime.`})}}),(0,o.createComponent)(u.VarDeclaration,{refkey:A,name:`env`,type:`Env`,export:!0,const:!0,get initializer(){return[s.code`createEnv(${d||`{}`} as Partial<Env>);`]}}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{export:!0,const:!0,name:`isCI`,doc:`Detect if the application is running in a continuous integration (CI) environment.`,initializer:s.code`Boolean(
43
- env.CI ||
44
- env.RUN_ID ||
45
- env.AGOLA_GIT_REF ||
46
- env.AC_APPCIRCLE ||
47
- env.APPVEYOR ||
48
- env.CODEBUILD ||
49
- env.TF_BUILD ||
50
- env.bamboo_planKey ||
51
- env.BITBUCKET_COMMIT ||
52
- env.BITRISE_IO ||
53
- env.BUDDY_WORKSPACE_ID ||
54
- env.BUILDKITE ||
55
- env.CIRCLECI ||
56
- env.CIRRUS_CI ||
57
- env.CF_BUILD_ID ||
58
- env.CM_BUILD_ID ||
59
- env.CI_NAME ||
60
- env.DRONE ||
61
- env.DSARI ||
62
- env.EARTHLY_CI ||
63
- env.EAS_BUILD ||
64
- env.GERRIT_PROJECT ||
65
- env.GITEA_ACTIONS ||
66
- env.GITHUB_ACTIONS ||
67
- env.GITLAB_CI ||
68
- env.GOCD ||
69
- env.BUILDER_OUTPUT ||
70
- env.HARNESS_BUILD_ID ||
71
- env.JENKINS_URL ||
72
- env.LAYERCI ||
73
- env.MAGNUM ||
74
- env.NETLIFY ||
75
- env.NEVERCODE ||
76
- env.PROW_JOB_ID ||
77
- env.RELEASE_BUILD_ID ||
78
- env.RENDER ||
79
- env.SAILCI ||
80
- env.HUDSON ||
81
- env.SCREWDRIVER ||
82
- env.SEMAPHORE ||
83
- env.SOURCEHUT ||
84
- env.STRIDER ||
85
- env.TASK_ID ||
86
- env.RUN_ID ||
87
- env.TEAMCITY_VERSION ||
88
- env.TRAVIS ||
89
- env.VELA ||
90
- env.NOW_BUILDER ||
91
- env.APPCENTER_BUILD_ID ||
92
- env.CI_XCODE_PROJECT ||
93
- env.XCS || false
94
- ); `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(h.TSDoc,{heading:"Detect the \\`mode\\` of the current runtime environment.",get children(){return(0,o.createComponent)(h.TSDocRemarks,{children:s.code`The \`mode\` is determined by the \`MODE\` environment variable, or falls back to the \`NEXT_PUBLIC_VERCEL_ENV\`, \`NODE_ENV\`, or defaults to \`production\`. While the value can potentially be any string, it is generally recommended to only allow a value in the following list:
95
- - \`production\`
96
- - \`test\`
97
- - \`development\`
98
- `})}}),(0,o.createComponent)(u.VarDeclaration,{export:!0,const:!0,name:`mode`,initializer:s.code`String(env.MODE) || "production"; `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{export:!0,const:!0,name:`isProduction`,doc:'Detect if the application is running in `"production"` mode',initializer:s.code`["prd", "prod", "production"].includes(mode.toLowerCase()); `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{export:!0,const:!0,name:`isTest`,doc:'Detect if the application is running in `"test"` mode',initializer:s.code`["tst", "test", "testing", "stg", "stage", "staging"].includes(mode.toLowerCase()) || env.TEST; `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{export:!0,const:!0,name:`isDevelopment`,doc:'Detect if the application is running in `"development"` mode',initializer:s.code`["dev", "development"].includes(mode.toLowerCase()); `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(u.VarDeclaration,{export:!0,const:!0,name:`isDebug`,doc:`Detect if the application is currently being debugged`,initializer:s.code`Boolean(isDevelopment && env.DEBUG); `}),(0,o.createComponent)(c.Spacing,{}),(0,o.createComponent)(s.Show,{get when(){return!!g},children:g})]}}))}M.__type=[()=>O,`props`,`EnvBuiltin`,`Generates the environment configuration module for the Powerlines project.`,`Pn!2""/#?$`],exports.EnvBuiltin=M,exports.EnvTypeDefinition=S,exports.__ΩEnvBuiltinProps=O;
@@ -1,21 +0,0 @@
1
- import { Children } from "@alloy-js/core";
2
- import { ReflectionClass } from "@powerlines/deepkit/vendor/type";
3
- import { BuiltinFileProps } from "@powerlines/plugin-alloy/typescript/components/builtin-file";
4
- import { InterfaceDeclarationProps } from "@powerlines/plugin-alloy/typescript/components/interface-declaration";
5
-
6
- //#region src/components/env-builtin.d.ts
7
- /**
8
- * Generates the environment configuration typescript definition for the Powerlines project.
9
- */
10
- declare function EnvTypeDefinition(props: Omit<InterfaceDeclarationProps, "name">): Children;
11
- interface EnvBuiltinProps extends Omit<BuiltinFileProps, "id"> {
12
- defaultConfig?: Children;
13
- reflection: ReflectionClass<any>;
14
- }
15
- /**
16
- * Generates the environment configuration module for the Powerlines project.
17
- */
18
- declare function EnvBuiltin(props: EnvBuiltinProps): Children;
19
- //#endregion
20
- export { EnvBuiltin, EnvBuiltinProps, EnvTypeDefinition };
21
- //# sourceMappingURL=env-builtin.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"env-builtin.d.cts","names":[],"sources":["../../src/components/env-builtin.tsx"],"mappings":";;;;;;;;AAwEA;iBAAgB,iBAAA,CACd,KAAA,EAAO,IAAA,CAAK,yBAAA,YAAkC,QAAA;AAAA,UAuM/B,eAAA,SAAwB,IAAA,CAAK,gBAAA;EAC5C,aAAA,GAAgB,QAAA;EAChB,UAAA,EAAY,eAAA;AAAA;;;;iBAUE,UAAA,CAAW,KAAA,EAAO,eAAA,GAAe,QAAA"}
@@ -1,21 +0,0 @@
1
- import { ReflectionClass } from "@powerlines/deepkit/vendor/type";
2
- import { Children } from "@alloy-js/core";
3
- import { BuiltinFileProps } from "@powerlines/plugin-alloy/typescript/components/builtin-file";
4
- import { InterfaceDeclarationProps } from "@powerlines/plugin-alloy/typescript/components/interface-declaration";
5
-
6
- //#region src/components/env-builtin.d.ts
7
- /**
8
- * Generates the environment configuration typescript definition for the Powerlines project.
9
- */
10
- declare function EnvTypeDefinition(props: Omit<InterfaceDeclarationProps, "name">): Children;
11
- interface EnvBuiltinProps extends Omit<BuiltinFileProps, "id"> {
12
- defaultConfig?: Children;
13
- reflection: ReflectionClass<any>;
14
- }
15
- /**
16
- * Generates the environment configuration module for the Powerlines project.
17
- */
18
- declare function EnvBuiltin(props: EnvBuiltinProps): Children;
19
- //#endregion
20
- export { EnvBuiltin, EnvBuiltinProps, EnvTypeDefinition };
21
- //# sourceMappingURL=env-builtin.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"env-builtin.d.mts","names":[],"sources":["../../src/components/env-builtin.tsx"],"mappings":";;;;;;;;AAwEA;iBAAgB,iBAAA,CACd,KAAA,EAAO,IAAA,CAAK,yBAAA,YAAkC,QAAA;AAAA,UAuM/B,eAAA,SAAwB,IAAA,CAAK,gBAAA;EAC5C,aAAA,GAAgB,QAAA;EAChB,UAAA,EAAY,eAAA;AAAA;;;;iBAUE,UAAA,CAAW,KAAA,EAAO,eAAA,GAAe,QAAA"}
@@ -1,96 +0,0 @@
1
- import{__ΩEnvPluginContext as e}from"../types/plugin.mjs";import{loadEnvFromContext as t}from"../helpers/load.mjs";import{titleCase as n}from"@stryke/string-format/title-case";import{ReflectionClass as r,ReflectionKind as i}from"@powerlines/deepkit/vendor/type";import a from"defu";import{createComponent as o,createIntrinsic as s,memo as c,mergeProps as l}from"@alloy-js/core/jsx-runtime";import{For as u,Show as d,code as f,computed as p,splitProps as m}from"@alloy-js/core";import{Spacing as h}from"@powerlines/plugin-alloy/core/components/spacing";import{usePowerlines as g}from"@powerlines/plugin-alloy/core/contexts/context";import{ClassDeclaration as _,ClassMethod as v,ElseIfClause as y,FunctionDeclaration as b,IfStatement as x,InterfaceDeclaration as S,InterfaceMember as C,NewExpression as w,VarDeclaration as T}from"@alloy-js/typescript";import{refkey as E}from"@powerlines/plugin-alloy/helpers/refkey";import{BuiltinFile as D}from"@powerlines/plugin-alloy/typescript/components/builtin-file";import{InterfaceDeclaration as O}from"@powerlines/plugin-alloy/typescript/components/interface-declaration";import{ObjectDeclaration as k}from"@powerlines/plugin-alloy/typescript/components/object-declaration";import{TSDoc as A,TSDocExample as j,TSDocLink as M,TSDocParam as N,TSDocRemarks as P,TSDocReturns as F,TSDocThrows as I}from"@powerlines/plugin-alloy/typescript/components/tsdoc";import{TSDocReflectionProperty as L}from"@powerlines/plugin-alloy/typescript/components/tsdoc-reflection";import{getUnique as R}from"@stryke/helpers/get-unique";const z=[`T`,`K`,()=>B,()=>V,`Omit`,`b!b"e!!e!!ge!"o$#o##w%y`],B=[`T`,`K`,`Pick`,`l+e#!e"!fRb!b"Pde""N#!w#y`],V=[`T`,`U`,`Exclude`,`l6!Re$!RPe#!e$"qk#%QRb!b"Pde"!p)w#y`];function H(e,t){return e.__type=t,e}function U(t){let[{defaultValue:n,reflection:r}]=m(t,[`defaultValue`,`reflection`]),i=(g.Ω=[[()=>e,`n!`]],g());return[o(O,{name:`UnprefixedEnv`,defaultValue:n,reflection:r,export:!0}),o(h,{}),o(A,{heading:`The environment configuration object with prefixed keys.`,get children(){return o(P,{children:"The `Env` type extends the `UnprefixedEnv` interface by including additional keys that are prefixed according to the project's configuration. This allows for flexibility in accessing environment variables with different naming conventions."})}}),o(S,{name:`Env`,export:!0,extends:`UnprefixedEnv`,get children(){return o(u,{get each(){return R(i.config.env.prefix).map(H(e=>e.replace(/_$/,``),[`prefix`,``,`P"2!"/"`]))},doubleHardline:!0,get children(){return H(e=>o(u,{get each(){return r?.getProperties().filter(H(e=>!e.isIgnored(),[`property`,``,`P"2!"/"`]))??[]},doubleHardline:!0,get children(){return H(t=>[o(L,{reflection:t}),o(C,{get name(){return`${e}_${t.getNameAsString()}`},get type(){return`UnprefixedEnv["${t.getNameAsString()}"]`},get readonly(){return t.isReadonly()}})],[`property`,``,`P"2!"/"`])}}),[`prefix`,``,`P"2!"/"`])}})}}),o(h,{})]}U.__type=[()=>z,`name`,`props`,`EnvTypeDefinition`,`Generates the environment configuration typescript definition for the Powerlines project.`,`P!."o!#2#"/$?%`];const W=[()=>e,`context`,`name`,`ConfigPropertyConditionalProps`,`P!n!4"&4#Mw$y`];function G(e){let[{context:t,name:n}]=m(e,[`context`,`name`]);return f`propertyName === "${n}" || propertyName.replace(/^(${R(t.config.env.prefix.sort(H((e,t)=>e.startsWith(t)?-1:t.startsWith(e)?1:e.localeCompare(t),[`a`,`b`,``,`P"2!"2""/#`])).map(H(e=>`${e.replace(/_$/,``)}_`,[`prefix`,``,`P"2!"/"`]))).join(`|`)})/g, "").toLowerCase().replace(/[\\s\\-_]+/g, "") === "${n.toLowerCase().replace(/[\s\-_]+/g,``)}"`}G.__type=[()=>W,`props`,`ConfigPropertyConditional`,`Pn!2""/#`];const K=[`index`,()=>e,`context`,`property`,`ConfigPropertyProps`,`P!'4!n"4#!4$Mw%y`];function q(e){let[{context:t,property:n,index:r}]=m(e,[`context`,`property`,`index`]);return[o(r===0?x:y,{get condition(){return[o(G,{get name(){return n.getNameAsString()},context:t}),o(d,{get when(){return c(()=>!!n.getAlias())()&&n.getAlias().length>0},get children(){return[f` || `,o(u,{get each(){return n.getAlias()},joiner:f` || `,get children(){return H(e=>o(G,{name:e,context:t}),[`alias`,``,`P"2!"/"`])}})]}})]},get children(){return f`return target["${n.getNameAsString()}"];`}})]}q.__type=[()=>K,`props`,`ConfigPropertyGet`,`Pn!2""/#`];function J(e){let[{context:t,property:n,index:r}]=m(e,[`context`,`property`,`index`]);return[o(r===0?x:y,{get condition(){return[o(G,{get name(){return n.getNameAsString()},context:t}),o(d,{get when(){return c(()=>!!n.getAlias())()&&n.getAlias().length>0},get children(){return[f` || `,o(u,{get each(){return n.getAlias()},joiner:f` || `,get children(){return H(e=>o(G,{name:e,context:t}),[`alias`,``,`P"2!"/"`])}})]}})]},get children(){return f`
2
- target["${n.getNameAsString()}"] = newValue;
3
- return true;
4
- `}})]}J.__type=[()=>K,`props`,`ConfigPropertySet`,`Pn!2""/#`];const Y=[()=>z,`id`,`Children`,`defaultConfig`,`reflection`,`EnvBuiltinProps`,`P!."o!#"w#4$8!4%Mw&y`],X=E(`createEnv`),Z=E(`env`),Q=E(`EnvSerializer`);function $(c){let[{defaultConfig:y,reflection:x,children:S},C]=m(c,[`defaultConfig`,`reflection`,`children`]),E=(g.Ω=[[()=>e,`n!`]],g()),O=p(()=>E&&t(E,process.env)),L=p(()=>{let e=new r({kind:i.objectLiteral,description:`The initial environment configuration state for the ${n(E?.config?.name)} project.`,types:[]},x);return e.getProperties().filter(H(e=>e.isRuntime()||e.getTags().runtime===!0,[`property`,``,`P"2!"/"`])).forEach(H(t=>{e.removeProperty(t.getNameAsString())},[`property`,``,`P"2!"/"`])),e}),z=p(()=>x?.getProperties().filter(H(e=>!e.isIgnored(),[`property`,``,`P"2!"/"`])).sort(H((e,t)=>e.getNameAsString().localeCompare(t.getNameAsString()),[`a`,`b`,``,`P"2!"2""/#`]))??[]),B=p(()=>x?.getProperties().filter(H(e=>!e.isIgnored()&&!e.isReadonly(),[`property`,``,`P"2!"/"`])).sort(H((e,t)=>e.getNameAsString().localeCompare(t.getNameAsString()),[`a`,`b`,``,`P"2!"2""/#`]))??[]);return o(D,l({id:`env`,description:`The environment configuration module provides an interface to define environment configuration parameters.`},C,{get imports(){return a({"@powerlines/deepkit/vendor/type":[`serializeFunction`,`deserializeFunction`,`ReflectionKind`,`Serializer`,`NamingStrategy`,`TemplateState`,`Type`,`TypeProperty`,`TypePropertySignature`]},C.imports??{})},get children(){return[o(d,{get when(){return!!x},get children(){return[o(U,{defaultValue:O,reflection:x}),s(`hbr`,{}),s(`hbr`,{})]}}),o(k,{name:`initialEnv`,type:`Partial<Env>`,defaultValue:O,reflection:L,export:!0,const:!0,doc:`The initial environment configuration object values for the runtime.`}),o(h,{}),o(A,{heading:`The environment configuration serializer for the Powerlines application.`,get children(){return[o(M,{children:`https://deepkit.io/docs/serialization/serializers`}),o(M,{children:`https://github.com/marcj/untitled-code/blob/master/packages/type/src/serializer.ts#L1918`}),o(P,{children:`This serializer is used to serialize and deserialize the Powerlines environment configuration.`})]}}),o(_,{refkey:Q,name:`EnvSerializer`,extends:`Serializer`,export:!0,get children(){return o(v,{name:`constructor`,public:!0,doc:"Initializes a new instance of the `EnvSerializer` class.",children:f`super("env");
5
-
6
- this.deserializeRegistry.register(
7
- ReflectionKind.boolean,
8
- (type: Type, state: TemplateState) => {
9
- state.addSetter(
10
- \`typeof \${state.accessor.toString()} !== "boolean" ? \${state.accessor.toString()} === 1 || \${state.accessor.toString()} === "1" || \${state.accessor.toString()}.toLowerCase() === "t" || \${state.accessor.toString()}.toLowerCase() === "true" || \${state.accessor.toString()}.toLowerCase() === "y" || \${state.accessor.toString()}.toLowerCase() === "yes" : \${state.accessor.toString()}\`
11
- );
12
- }
13
- ); `})}}),o(h,{}),o(T,{name:`envNamingStrategy`,const:!0,doc:`The environment naming strategy for the runtime.`,get initializer(){return f`new class extends NamingStrategy {
14
- constructor() {
15
- super("env");
16
- }
17
-
18
- getPropertyName(type: TypeProperty | TypePropertySignature, forSerializer: string): string | undefined {
19
- const name = super.getPropertyName(type, forSerializer);
20
- if (!name) {
21
- return name;
22
- }
23
-
24
- return name.replace(/^(${R(E.config.env.prefix).map(H(e=>e.replace(/_$/,``),[`prefix`,``,`P"2!"/"`])).join(`|`)})_/, "");
25
- }
26
- }; `}}),o(h,{}),o(A,{heading:`A {@link EnvSerializer | environment configuration serializer} instance for the Powerlines application.`,get children(){return[o(M,{children:`https://deepkit.io/docs/serialization/serializers`}),o(M,{children:`https://github.com/marcj/untitled-code/blob/master/packages/type/src/serializer.ts#L1918`}),o(P,{children:`This serializer is used to serialize and deserialize the Powerlines environment configuration.`})]}}),o(T,{name:`envSerializer`,const:!0,get initializer(){return o(w,{args:[],target:`EnvSerializer`})}}),o(h,{}),o(T,{name:`_serializeEnv`,const:!0,initializer:`serializeFunction<Env>(envSerializer, envNamingStrategy)`}),o(h,{}),o(A,{heading:`Serialize a environment configuration object to JSON data objects (not a JSON string).`,get children(){return[o(P,{children:"The resulting JSON object can be stringified using `JSON.stringify()`."}),o(j,{children:`const json = serializeEnv(env);`}),o(h,{}),o(N,{name:`input`,children:`The environment configuration object to serialize.`}),o(F,{children:`The serialized environment configuration as JSON data objects.`}),o(I,{children:`ValidationError when serialization or validation fails.`})]}}),o(b,{name:`serializeEnv`,export:!0,parameters:[{name:`input`,type:`Env`}],children:f` return _serializeEnv(input, { loosely: true }); `}),o(h,{}),o(T,{name:`_deserializeEnv`,const:!0,initializer:`deserializeFunction<Env>(envSerializer, envNamingStrategy)`}),o(h,{}),o(A,{heading:`Deserialize a environment configuration object from JSON data objects to JavaScript objects, without running any validators.`,get children(){return[o(P,{children:`Types that are already correct will be used as-is.`}),o(j,{children:`const env = deserializeEnv(json);`}),o(I,{children:`ValidationError when deserialization fails.`})]}}),o(b,{name:`deserializeEnv`,export:!0,parameters:[{name:`input`,type:`Env`}],children:f` return _deserializeEnv(input, { loosely: true }); `}),o(h,{}),o(A,{heading:`Initializes the Powerlines environment configuration module.`,get children(){return[o(P,{children:`This function initializes the Powerlines environment configuration object.`}),o(N,{name:`environmentConfig`,children:`The dynamic/runtime configuration - this could include the current environment variables or any other environment-specific settings provided by the runtime.`}),o(F,{children:`The initialized Powerlines configuration object.`})]}}),o(d,{get when(){return!!E?.entryPath},get children(){return o(b,{refkey:X,async:!1,export:!0,name:`createEnv`,parameters:[{name:`environmentConfig`,type:`Partial<Env>`,optional:!1,default:`{}`}],returnType:`Env`,get children(){return[f`
27
- return new Proxy<Env>(
28
- deserializeEnv({
29
- ...initialEnv,
30
- ...environmentConfig
31
- } as Env),
32
- {
33
- get: (target: UnprefixedEnv, propertyName: string) => { `,s(`hbr`,{}),o(u,{each:z,get children(){return H((e,t)=>o(q,{index:t,context:E,property:e}),[`property`,`index`,``,`P!2!'2""/#`])}}),f`
34
- return undefined;
35
- }, `,o(h,{}),f` set: (target: UnprefixedEnv, propertyName: string, newValue: any) => { `,s(`hbr`,{}),o(u,{each:B,ender:f` else `,get children(){return H((e,t)=>o(J,{index:t,context:E,property:e}),[`property`,`index`,``,`P!2!'2""/#`])}}),s(`hbr`,{}),f`return false;
36
- }
37
- }
38
- );
39
- `]}})}}),o(h,{}),s(`hbr`,{}),o(A,{heading:`The environment configuration object.`,get children(){return o(P,{children:`This object provides access to the environment configuration parameters in the application runtime.`})}}),o(T,{refkey:Z,name:`env`,type:`Env`,export:!0,const:!0,get initializer(){return[f`createEnv(${y||`{}`} as Partial<Env>);`]}}),o(h,{}),o(T,{export:!0,const:!0,name:`isCI`,doc:`Detect if the application is running in a continuous integration (CI) environment.`,initializer:f`Boolean(
40
- env.CI ||
41
- env.RUN_ID ||
42
- env.AGOLA_GIT_REF ||
43
- env.AC_APPCIRCLE ||
44
- env.APPVEYOR ||
45
- env.CODEBUILD ||
46
- env.TF_BUILD ||
47
- env.bamboo_planKey ||
48
- env.BITBUCKET_COMMIT ||
49
- env.BITRISE_IO ||
50
- env.BUDDY_WORKSPACE_ID ||
51
- env.BUILDKITE ||
52
- env.CIRCLECI ||
53
- env.CIRRUS_CI ||
54
- env.CF_BUILD_ID ||
55
- env.CM_BUILD_ID ||
56
- env.CI_NAME ||
57
- env.DRONE ||
58
- env.DSARI ||
59
- env.EARTHLY_CI ||
60
- env.EAS_BUILD ||
61
- env.GERRIT_PROJECT ||
62
- env.GITEA_ACTIONS ||
63
- env.GITHUB_ACTIONS ||
64
- env.GITLAB_CI ||
65
- env.GOCD ||
66
- env.BUILDER_OUTPUT ||
67
- env.HARNESS_BUILD_ID ||
68
- env.JENKINS_URL ||
69
- env.LAYERCI ||
70
- env.MAGNUM ||
71
- env.NETLIFY ||
72
- env.NEVERCODE ||
73
- env.PROW_JOB_ID ||
74
- env.RELEASE_BUILD_ID ||
75
- env.RENDER ||
76
- env.SAILCI ||
77
- env.HUDSON ||
78
- env.SCREWDRIVER ||
79
- env.SEMAPHORE ||
80
- env.SOURCEHUT ||
81
- env.STRIDER ||
82
- env.TASK_ID ||
83
- env.RUN_ID ||
84
- env.TEAMCITY_VERSION ||
85
- env.TRAVIS ||
86
- env.VELA ||
87
- env.NOW_BUILDER ||
88
- env.APPCENTER_BUILD_ID ||
89
- env.CI_XCODE_PROJECT ||
90
- env.XCS || false
91
- ); `}),o(h,{}),o(A,{heading:"Detect the \\`mode\\` of the current runtime environment.",get children(){return o(P,{children:f`The \`mode\` is determined by the \`MODE\` environment variable, or falls back to the \`NEXT_PUBLIC_VERCEL_ENV\`, \`NODE_ENV\`, or defaults to \`production\`. While the value can potentially be any string, it is generally recommended to only allow a value in the following list:
92
- - \`production\`
93
- - \`test\`
94
- - \`development\`
95
- `})}}),o(T,{export:!0,const:!0,name:`mode`,initializer:f`String(env.MODE) || "production"; `}),o(h,{}),o(T,{export:!0,const:!0,name:`isProduction`,doc:'Detect if the application is running in `"production"` mode',initializer:f`["prd", "prod", "production"].includes(mode.toLowerCase()); `}),o(h,{}),o(T,{export:!0,const:!0,name:`isTest`,doc:'Detect if the application is running in `"test"` mode',initializer:f`["tst", "test", "testing", "stg", "stage", "staging"].includes(mode.toLowerCase()) || env.TEST; `}),o(h,{}),o(T,{export:!0,const:!0,name:`isDevelopment`,doc:'Detect if the application is running in `"development"` mode',initializer:f`["dev", "development"].includes(mode.toLowerCase()); `}),o(h,{}),o(T,{export:!0,const:!0,name:`isDebug`,doc:`Detect if the application is currently being debugged`,initializer:f`Boolean(isDevelopment && env.DEBUG); `}),o(h,{}),o(d,{get when(){return!!S},children:S})]}}))}$.__type=[()=>Y,`props`,`EnvBuiltin`,`Generates the environment configuration module for the Powerlines project.`,`Pn!2""/#?$`];export{$ as EnvBuiltin,U as EnvTypeDefinition,Y as __ΩEnvBuiltinProps};
96
- //# sourceMappingURL=env-builtin.mjs.map