@nikovirtala/projen-constructs 0.5.1 → 0.5.2
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/.jsii +4 -4
- package/.kiro/steering/product.md +7 -5
- package/.kiro/steering/tech.md +7 -5
- package/README.md +94 -478
- package/docs/api/assets/highlight.css +8 -8
- package/docs/api/functions/renderBundleName.html +1 -1
- package/docs/api/index.html +96 -415
- package/docs/api/interfaces/AwsCdkConstructLibraryProjectOptions.html +3 -3
- package/docs/api/interfaces/AwsCdkTypeScriptAppProjectOptions.html +3 -3
- package/docs/api/interfaces/JsiiProjectOptions.html +3 -3
- package/docs/api/interfaces/LocalStackOptions.html +2 -2
- package/docs/api/interfaces/ProjectGeneratorOptions.html +1 -1
- package/docs/api/interfaces/TypeScriptProjectOptions.html +3 -3
- package/docs/api/interfaces/VitestConfigOptions.html +3 -3
- package/docs/api/interfaces/VitestOptions.html +2 -2
- package/docs/api/media/LICENSE +202 -0
- package/docs/api/media/components.md +191 -0
- package/docs/api/media/configuration.md +108 -0
- package/docs/api/media/development.md +93 -0
- package/docs/api/media/index.html +169 -0
- package/docs/api/media/migration.md +106 -0
- package/docs/api/modules.html +2 -2
- package/docs/components.md +191 -0
- package/docs/configuration.md +108 -0
- package/docs/development.md +93 -0
- package/docs/migration.md +106 -0
- package/lib/components/bundle-lambda-function-code.js +3 -3
- package/lib/components/colima.js +1 -1
- package/lib/components/homebrew.js +1 -1
- package/lib/components/lambda-function-construct-generator.js +1 -1
- package/lib/components/localstack.js +1 -1
- package/lib/components/mise.js +1 -1
- package/lib/components/typedoc.js +1 -1
- package/lib/components/vitest.js +1 -1
- package/lib/project-generator.js +1 -1
- package/lib/projects/awscdk-construct-library.generated.js +1 -1
- package/lib/projects/awscdk-typescript-app.generated.js +1 -1
- package/lib/projects/jsii.generated.js +1 -1
- package/lib/projects/typescript.generated.js +1 -1
- package/package.json +3 -2
package/docs/api/modules.html
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Enumerations"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>
|
|
13
13
|
<h2 class="tsd-anchor-link" id="enumerations">Enumerations<a href="#enumerations" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2></summary><dl class="tsd-member-summaries"><dt class="tsd-member-summary" id="commentstyle"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/CommentStyle.html">CommentStyle</a><a href="#commentstyle" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="coverageprovider"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/CoverageProvider.html">CoverageProvider</a><a href="#coverageprovider" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="coveragereporter"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/CoverageReporter.html">CoverageReporter</a><a href="#coveragereporter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="entrypointstrategy"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/EntryPointStrategy.html">EntryPointStrategy</a><a href="#entrypointstrategy" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="environment"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/Environment.html">Environment</a><a href="#environment" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="loglevel"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/LogLevel.html">LogLevel</a><a href="#loglevel" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="pool"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/Pool.html">Pool</a><a href="#pool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="projecttype"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/ProjectType.html">ProjectType</a><a href="#projecttype" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="visibility"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><a href="enums/Visibility.html">Visibility</a><a href="#visibility" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd></dl></details>
|
|
14
14
|
<details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Classes"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>
|
|
15
|
-
<h2 class="tsd-anchor-link" id="classes">Classes<a href="#classes" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2></summary><dl class="tsd-member-summaries"><dt class="tsd-member-summary" id="awscdkconstructlibraryproject"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/AwsCdkConstructLibraryProject.html">AwsCdkConstructLibraryProject</a><a href="#awscdkconstructlibraryproject" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="awscdktypescriptappproject"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/AwsCdkTypeScriptAppProject.html">AwsCdkTypeScriptAppProject</a><a href="#awscdktypescriptappproject" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="bundler
|
|
15
|
+
<h2 class="tsd-anchor-link" id="classes">Classes<a href="#classes" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2></summary><dl class="tsd-member-summaries"><dt class="tsd-member-summary" id="awscdkconstructlibraryproject"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/AwsCdkConstructLibraryProject.html">AwsCdkConstructLibraryProject</a><a href="#awscdkconstructlibraryproject" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="awscdktypescriptappproject"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/AwsCdkTypeScriptAppProject.html">AwsCdkTypeScriptAppProject</a><a href="#awscdktypescriptappproject" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="bundler"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/Bundler.html">Bundler</a><a href="#bundler" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="colima"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/Colima.html">Colima</a><a href="#colima" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="homebrew"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/Homebrew.html">Homebrew</a><a href="#homebrew" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="jsiiproject"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/JsiiProject.html">JsiiProject</a><a href="#jsiiproject" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="lambdafunctioncodebundle"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/LambdaFunctionCodeBundle.html">LambdaFunctionCodeBundle</a><a href="#lambdafunctioncodebundle" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="lambdafunctioncodebundler"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/LambdaFunctionCodeBundler.html">LambdaFunctionCodeBundler</a><a href="#lambdafunctioncodebundler" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="lambdafunctionconstructgenerator"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/LambdaFunctionConstructGenerator.html">LambdaFunctionConstructGenerator</a><a href="#lambdafunctionconstructgenerator" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="localstack"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/LocalStack.html">LocalStack</a><a href="#localstack" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="mise"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/Mise.html">Mise</a><a href="#mise" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="projectgenerator"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/ProjectGenerator.html">ProjectGenerator</a><a href="#projectgenerator" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="typedoc"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/TypeDoc.html">TypeDoc</a><a href="#typedoc" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="typescriptproject"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/TypeScriptProject.html">TypeScriptProject</a><a href="#typescriptproject" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="vitest"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><a href="classes/Vitest.html">Vitest</a><a href="#vitest" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd></dl></details>
|
|
16
16
|
<details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Interfaces"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>
|
|
17
17
|
<h2 class="tsd-anchor-link" id="interfaces">Interfaces<a href="#interfaces" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2></summary><dl class="tsd-member-summaries"><dt class="tsd-member-summary" id="awscdkconstructlibraryprojectoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/AwsCdkConstructLibraryProjectOptions.html">AwsCdkConstructLibraryProjectOptions</a><a href="#awscdkconstructlibraryprojectoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="awscdktypescriptappprojectoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/AwsCdkTypeScriptAppProjectOptions.html">AwsCdkTypeScriptAppProjectOptions</a><a href="#awscdktypescriptappprojectoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="bundle"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/Bundle.html">Bundle</a><a href="#bundle" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="bundleroptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/BundlerOptions.html">BundlerOptions</a><a href="#bundleroptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="bundlingoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/BundlingOptions.html">BundlingOptions</a><a href="#bundlingoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="component"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/Component.html">Component</a><a href="#component" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="componentoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/ComponentOptions.html">ComponentOptions</a><a href="#componentoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="homebrewoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/HomebrewOptions.html">HomebrewOptions</a><a href="#homebrewoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="jsiiprojectoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/JsiiProjectOptions.html">JsiiProjectOptions</a><a href="#jsiiprojectoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="lambdafunctioncodebundleoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/LambdaFunctionCodeBundleOptions.html">LambdaFunctionCodeBundleOptions</a><a href="#lambdafunctioncodebundleoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="lambdafunctioncodebundleroptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/LambdaFunctionCodeBundlerOptions.html">LambdaFunctionCodeBundlerOptions</a><a href="#lambdafunctioncodebundleroptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="lambdafunctionconstructgeneratoroptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/LambdaFunctionConstructGeneratorOptions.html">LambdaFunctionConstructGeneratorOptions</a><a href="#lambdafunctionconstructgeneratoroptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="localstackoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/LocalStackOptions.html">LocalStackOptions</a><a href="#localstackoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="miseoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/MiseOptions.html">MiseOptions</a><a href="#miseoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="projectgeneratoroptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/ProjectGeneratorOptions.html">ProjectGeneratorOptions</a><a href="#projectgeneratoroptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="typedocconfiguration"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/TypeDocConfiguration.html">TypeDocConfiguration</a><a href="#typedocconfiguration" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="typedocoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/TypeDocOptions.html">TypeDocOptions</a><a href="#typedocoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="typescriptprojectoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/TypeScriptProjectOptions.html">TypeScriptProjectOptions</a><a href="#typescriptprojectoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="validationoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/ValidationOptions.html">ValidationOptions</a><a href="#validationoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="vitestconfigoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/VitestConfigOptions.html">VitestConfigOptions</a><a href="#vitestconfigoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd><dt class="tsd-member-summary" id="vitestoptions"><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><a href="interfaces/VitestOptions.html">VitestOptions</a><a href="#vitestoptions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd></dl></details>
|
|
18
18
|
<details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Variables"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
<details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Enumerations"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Enumerations</summary>
|
|
38
38
|
<div><a href="#commentstyle"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Comment<wbr/>Style</span></a><a href="#coverageprovider"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Coverage<wbr/>Provider</span></a><a href="#coveragereporter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Coverage<wbr/>Reporter</span></a><a href="#entrypointstrategy"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Entry<wbr/>Point<wbr/>Strategy</span></a><a href="#environment"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Environment</span></a><a href="#loglevel"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Log<wbr/>Level</span></a><a href="#pool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Pool</span></a><a href="#projecttype"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Project<wbr/>Type</span></a><a href="#visibility"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Enumeration"><use href="assets/icons.svg#icon-8"></use></svg><span>Visibility</span></a></div></details>
|
|
39
39
|
<details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Classes"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Classes</summary>
|
|
40
|
-
<div><a href="#awscdkconstructlibraryproject"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Aws<wbr/>Cdk<wbr/>Construct<wbr/>Library<wbr/>Project</span></a><a href="#awscdktypescriptappproject"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Aws<wbr/>Cdk<wbr/>Type<wbr/>Script<wbr/>App<wbr/>Project</span></a><a href="#bundler
|
|
40
|
+
<div><a href="#awscdkconstructlibraryproject"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Aws<wbr/>Cdk<wbr/>Construct<wbr/>Library<wbr/>Project</span></a><a href="#awscdktypescriptappproject"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Aws<wbr/>Cdk<wbr/>Type<wbr/>Script<wbr/>App<wbr/>Project</span></a><a href="#bundler"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Bundler</span></a><a href="#colima"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Colima</span></a><a href="#homebrew"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Homebrew</span></a><a href="#jsiiproject"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Jsii<wbr/>Project</span></a><a href="#lambdafunctioncodebundle"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Lambda<wbr/>Function<wbr/>Code<wbr/>Bundle</span></a><a href="#lambdafunctioncodebundler"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Lambda<wbr/>Function<wbr/>Code<wbr/>Bundler</span></a><a href="#lambdafunctionconstructgenerator"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Lambda<wbr/>Function<wbr/>Construct<wbr/>Generator</span></a><a href="#localstack"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Local<wbr/>Stack</span></a><a href="#mise"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Mise</span></a><a href="#projectgenerator"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Project<wbr/>Generator</span></a><a href="#typedoc"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Type<wbr/>Doc</span></a><a href="#typescriptproject"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Type<wbr/>Script<wbr/>Project</span></a><a href="#vitest"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Class"><use href="assets/icons.svg#icon-128"></use></svg><span>Vitest</span></a></div></details>
|
|
41
41
|
<details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Interfaces"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Interfaces</summary>
|
|
42
42
|
<div><a href="#awscdkconstructlibraryprojectoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Aws<wbr/>Cdk<wbr/>Construct<wbr/>Library<wbr/>Project<wbr/>Options</span></a><a href="#awscdktypescriptappprojectoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Aws<wbr/>Cdk<wbr/>Type<wbr/>Script<wbr/>App<wbr/>Project<wbr/>Options</span></a><a href="#bundle"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Bundle</span></a><a href="#bundleroptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Bundler<wbr/>Options</span></a><a href="#bundlingoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Bundling<wbr/>Options</span></a><a href="#component"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Component</span></a><a href="#componentoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Component<wbr/>Options</span></a><a href="#homebrewoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Homebrew<wbr/>Options</span></a><a href="#jsiiprojectoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Jsii<wbr/>Project<wbr/>Options</span></a><a href="#lambdafunctioncodebundleoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Lambda<wbr/>Function<wbr/>Code<wbr/>Bundle<wbr/>Options</span></a><a href="#lambdafunctioncodebundleroptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Lambda<wbr/>Function<wbr/>Code<wbr/>Bundler<wbr/>Options</span></a><a href="#lambdafunctionconstructgeneratoroptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Lambda<wbr/>Function<wbr/>Construct<wbr/>Generator<wbr/>Options</span></a><a href="#localstackoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Local<wbr/>Stack<wbr/>Options</span></a><a href="#miseoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Mise<wbr/>Options</span></a><a href="#projectgeneratoroptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Project<wbr/>Generator<wbr/>Options</span></a><a href="#typedocconfiguration"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Type<wbr/>Doc<wbr/>Configuration</span></a><a href="#typedocoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Type<wbr/>Doc<wbr/>Options</span></a><a href="#typescriptprojectoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Type<wbr/>Script<wbr/>Project<wbr/>Options</span></a><a href="#validationoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Validation<wbr/>Options</span></a><a href="#vitestconfigoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Vitest<wbr/>Config<wbr/>Options</span></a><a href="#vitestoptions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Interface"><use href="assets/icons.svg#icon-256"></use></svg><span>Vitest<wbr/>Options</span></a></div></details>
|
|
43
43
|
<details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Variables"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Variables</summary>
|
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
# Components
|
|
2
|
+
|
|
3
|
+
`@nikovirtala/projen-constructs` ships reusable projen components for common development tasks. Add
|
|
4
|
+
a component to any project by constructing it with the project as its first argument. Every
|
|
5
|
+
TypeScript snippet below imports each identifier it uses, so you can paste it as-is.
|
|
6
|
+
|
|
7
|
+
## Vitest
|
|
8
|
+
|
|
9
|
+
[Vitest](https://vitest.dev) testing framework component.
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
import {
|
|
13
|
+
CoverageProvider,
|
|
14
|
+
CoverageReporter,
|
|
15
|
+
Vitest,
|
|
16
|
+
} from "@nikovirtala/projen-constructs";
|
|
17
|
+
|
|
18
|
+
new Vitest(project, {
|
|
19
|
+
vitestVersion: "^5",
|
|
20
|
+
config: {
|
|
21
|
+
coverageProvider: CoverageProvider.V8,
|
|
22
|
+
coverageReporters: [CoverageReporter.TEXT, CoverageReporter.LCOV],
|
|
23
|
+
},
|
|
24
|
+
});
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Type checking runs against the project's development tsconfig (`test/tsconfig.json`) unless
|
|
28
|
+
`config.typecheckTsconfig` says otherwise.
|
|
29
|
+
|
|
30
|
+
For Vitest settings that `config` does not cover, use `extraTestConfig` (merged into `test`) and
|
|
31
|
+
`extraConfig` (top-level options next to `test`):
|
|
32
|
+
|
|
33
|
+
```typescript
|
|
34
|
+
import { Vitest } from "@nikovirtala/projen-constructs";
|
|
35
|
+
|
|
36
|
+
new Vitest(project, {
|
|
37
|
+
extraTestConfig: {
|
|
38
|
+
setupFiles: ["test/setup.ts"],
|
|
39
|
+
},
|
|
40
|
+
extraConfig: {
|
|
41
|
+
resolve: { alias: { "@": "/src" } },
|
|
42
|
+
},
|
|
43
|
+
});
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
`extraTestConfig` is deep-merged over the generated `test` options: objects merge, and other values
|
|
47
|
+
(including arrays) replace the generated value. Both options are rendered as JSON, so their values
|
|
48
|
+
cannot contain functions or regular expressions, which rules out plugins.
|
|
49
|
+
|
|
50
|
+
## TypeDoc
|
|
51
|
+
|
|
52
|
+
[TypeDoc](https://typedoc.org) documentation generation component.
|
|
53
|
+
|
|
54
|
+
```typescript
|
|
55
|
+
import { EntryPointStrategy, TypeDoc } from "@nikovirtala/projen-constructs";
|
|
56
|
+
|
|
57
|
+
new TypeDoc(project, {
|
|
58
|
+
version: "^0.28",
|
|
59
|
+
typeDocConfig: {
|
|
60
|
+
entryPointStrategy: EntryPointStrategy.EXPAND,
|
|
61
|
+
out: "docs/api",
|
|
62
|
+
exclude: ["**/*.test.ts"],
|
|
63
|
+
},
|
|
64
|
+
});
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
## Mise
|
|
68
|
+
|
|
69
|
+
[Mise](https://mise.jdx.dev) dev tools and runtimes management component.
|
|
70
|
+
|
|
71
|
+
```typescript
|
|
72
|
+
import { Mise } from "@nikovirtala/projen-constructs";
|
|
73
|
+
|
|
74
|
+
new Mise(project, {
|
|
75
|
+
nodeVersion: "26.13.0",
|
|
76
|
+
});
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
## Homebrew
|
|
80
|
+
|
|
81
|
+
[Homebrew](https://brew.sh) package management component. Writes a `Brewfile` and adds an
|
|
82
|
+
`install:homebrew` task that bootstraps Homebrew and runs `brew bundle`.
|
|
83
|
+
|
|
84
|
+
```typescript
|
|
85
|
+
import { Homebrew } from "@nikovirtala/projen-constructs";
|
|
86
|
+
|
|
87
|
+
const homebrew = new Homebrew(project, {
|
|
88
|
+
packages: ["jq", "yq"],
|
|
89
|
+
});
|
|
90
|
+
|
|
91
|
+
homebrew.addPackage("gh");
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
A fully qualified formula (`user/repository/formula`) also adds a `tap` entry. Since Homebrew 6,
|
|
95
|
+
formulae from non-official taps only load when trusted, so they are written with `trusted: true`.
|
|
96
|
+
That trusts only the formula, not the rest of its tap.
|
|
97
|
+
|
|
98
|
+
## Colima
|
|
99
|
+
|
|
100
|
+
[Colima](https://github.com/abiosoft/colima) container runtime component. An alternative to Docker.
|
|
101
|
+
|
|
102
|
+
```typescript
|
|
103
|
+
import { Colima } from "@nikovirtala/projen-constructs";
|
|
104
|
+
|
|
105
|
+
new Colima(project);
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
## LocalStack
|
|
109
|
+
|
|
110
|
+
[LocalStack](https://www.localstack.cloud) AWS emulation component.
|
|
111
|
+
|
|
112
|
+
```typescript
|
|
113
|
+
import { LocalStack } from "@nikovirtala/projen-constructs";
|
|
114
|
+
|
|
115
|
+
new LocalStack(project, {
|
|
116
|
+
services: ["s3", "lambda", "dynamodb"],
|
|
117
|
+
port: 4566,
|
|
118
|
+
debug: true,
|
|
119
|
+
});
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
## LambdaFunctionConstructGenerator
|
|
123
|
+
|
|
124
|
+
Generates AWS CDK Lambda Function constructs and bundles their code.
|
|
125
|
+
|
|
126
|
+
```typescript
|
|
127
|
+
import { LambdaFunctionConstructGenerator } from "@nikovirtala/projen-constructs";
|
|
128
|
+
|
|
129
|
+
new LambdaFunctionConstructGenerator(project, {
|
|
130
|
+
sourceDir: "src/handlers",
|
|
131
|
+
outputDir: "src/constructs/lambda",
|
|
132
|
+
filePattern: "*.lambda.ts",
|
|
133
|
+
esbuildOptions: {
|
|
134
|
+
minify: true,
|
|
135
|
+
sourcemap: true,
|
|
136
|
+
},
|
|
137
|
+
});
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
## Bundler
|
|
141
|
+
|
|
142
|
+
Low-level bundling utilities for Lambda functions.
|
|
143
|
+
|
|
144
|
+
```typescript
|
|
145
|
+
import {
|
|
146
|
+
Bundler,
|
|
147
|
+
LambdaFunctionCodeBundle,
|
|
148
|
+
} from "@nikovirtala/projen-constructs";
|
|
149
|
+
|
|
150
|
+
const bundler = new Bundler(project, {
|
|
151
|
+
assetsDir: "assets",
|
|
152
|
+
esbuildVersion: "^0.25",
|
|
153
|
+
});
|
|
154
|
+
|
|
155
|
+
new LambdaFunctionCodeBundle(project, {
|
|
156
|
+
entrypoint: "src/my-function.lambda.ts",
|
|
157
|
+
extension: ".lambda.ts",
|
|
158
|
+
});
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
## ProjectGenerator
|
|
162
|
+
|
|
163
|
+
Generates TypeScript project classes with standard configuration.
|
|
164
|
+
|
|
165
|
+
```typescript
|
|
166
|
+
import {
|
|
167
|
+
Mise,
|
|
168
|
+
ProjectGenerator,
|
|
169
|
+
ProjectType,
|
|
170
|
+
Vitest,
|
|
171
|
+
} from "@nikovirtala/projen-constructs";
|
|
172
|
+
|
|
173
|
+
new ProjectGenerator(project, {
|
|
174
|
+
name: "TypeScriptProject",
|
|
175
|
+
projectType: ProjectType.TYPE_SCRIPT_PROJECT,
|
|
176
|
+
filePath: "./src/projects/typescript.generated.ts",
|
|
177
|
+
components: [
|
|
178
|
+
{ componentClass: Mise },
|
|
179
|
+
{ componentClass: Vitest }, // auto-detects VitestOptions from the JSII manifest
|
|
180
|
+
],
|
|
181
|
+
});
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
Features:
|
|
185
|
+
|
|
186
|
+
- Automatically generates the `ProjectType` enum from projen's JSII manifest
|
|
187
|
+
- Auto-detects component options types from JSII manifests
|
|
188
|
+
- Strips projen's `@pjnew` annotation from `packageManager`, which `projen new` would otherwise
|
|
189
|
+
render into a generated `.projenrc.ts` as the package manager that ran the command
|
|
190
|
+
- Validates paths to prevent directory traversal attacks
|
|
191
|
+
- Structured error handling with custom error classes
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# Configuration
|
|
2
|
+
|
|
3
|
+
This page covers the configuration that `@nikovirtala/projen-constructs` applies to generated
|
|
4
|
+
projects: package manager settings, the TypeScript configs, native TypeScript execution, and how
|
|
5
|
+
you override any of it.
|
|
6
|
+
|
|
7
|
+
## Standard configuration
|
|
8
|
+
|
|
9
|
+
Every project type ships with the same opinionated defaults:
|
|
10
|
+
|
|
11
|
+
<!-- generated:version-table-start -->
|
|
12
|
+
- **Author**: Niko Virtala (niko.virtala@hey.com)
|
|
13
|
+
- **Default release branch**: main
|
|
14
|
+
- **Package manager**: pnpm 12.16.1
|
|
15
|
+
- **Node version**: 26.13.0
|
|
16
|
+
- **TypeScript**: 6.0.3
|
|
17
|
+
- **CDK version**: 2.275.0 (for CDK projects)
|
|
18
|
+
- **JSII version**: ~6.0.3 (for JSII projects)
|
|
19
|
+
<!-- generated:version-table-end -->
|
|
20
|
+
|
|
21
|
+
The AWS CDK, Node.js and TypeScript versions live in `src/versions.json` and are refreshed by the
|
|
22
|
+
`update-versions` task, which the dependency upgrade workflow runs.
|
|
23
|
+
|
|
24
|
+
## pnpm
|
|
25
|
+
|
|
26
|
+
pnpm reads its settings from `pnpm-workspace.yaml`, not `.npmrc`, since pnpm 11. Generated projects
|
|
27
|
+
get:
|
|
28
|
+
|
|
29
|
+
| Setting | Value | Reason |
|
|
30
|
+
| ---------------------- | ----------------- | ------------------------------------------------------------------------------------------------------------ |
|
|
31
|
+
| `nodeLinker` | `hoisted` | jsii tooling resolves dependencies from a flat `node_modules` |
|
|
32
|
+
| `allowBuilds` | `esbuild: true` | esbuild links its platform binary in a postinstall script, and pnpm 11 fails an install with ignored builds |
|
|
33
|
+
| `verifyDepsBeforeRun` | `false` | projen resolves the task `PATH` with `$(pnpm -c exec ...)`, which otherwise re-enters `pnpm install` and deadlocks |
|
|
34
|
+
| `minimumReleaseAge` | `0` | the pnpm 11 default of 1440 minutes makes pnpm write `minimumReleaseAgeExclude` entries into this generated file |
|
|
35
|
+
|
|
36
|
+
## TypeScript configuration
|
|
37
|
+
|
|
38
|
+
Projen renders three configs, and you should not edit any of them directly:
|
|
39
|
+
|
|
40
|
+
- `tsconfig.json` compiles `src` to `lib`. For JSII projects, jsii validates it against its `strict`
|
|
41
|
+
rule set, so it only carries compiler options jsii accepts.
|
|
42
|
+
- `test/tsconfig.json` extends it and is type-check only. This is the config Vitest type checking and
|
|
43
|
+
the editor use, and the one `tsconfigDev` points at.
|
|
44
|
+
- `projenrc/tsconfig.json` covers `.projenrc.ts`.
|
|
45
|
+
|
|
46
|
+
## Native TypeScript
|
|
47
|
+
|
|
48
|
+
TypeScript and AWS CDK app projects run TypeScript with Node.js's built-in
|
|
49
|
+
[type stripping](https://nodejs.org/api/typescript.html#type-stripping) instead of `tsx` or
|
|
50
|
+
`ts-node`: the default task is `node .projenrc.ts`, and the cdk.json `app` is `node src/main.ts`.
|
|
51
|
+
Their `tsconfig.json` sets `erasableSyntaxOnly` and `verbatimModuleSyntax`, so `tsc` reports code
|
|
52
|
+
that Node.js cannot run before Node.js does.
|
|
53
|
+
|
|
54
|
+
Code in these projects must therefore:
|
|
55
|
+
|
|
56
|
+
- only use syntax that can be stripped: no `enum`s (use an `as const` object), no namespaces with
|
|
57
|
+
values, and no constructor parameter properties
|
|
58
|
+
- mark type-only imports with `type` (Biome's `useImportType` fixes these)
|
|
59
|
+
- import relative files with their `.ts` extension, and never import a directory
|
|
60
|
+
- use Node.js [subpath imports](https://nodejs.org/api/packages.html#subpath-imports)
|
|
61
|
+
(`#stacks` in `package.json` `imports`) instead of tsconfig `paths`, which Node.js does not read
|
|
62
|
+
- import packages without an `exports` map either from the package root or with an explicit file,
|
|
63
|
+
e.g. `projen/lib/component.js` rather than `projen/lib/component`
|
|
64
|
+
|
|
65
|
+
Lambda handlers bundled by esbuild and tests run by Vitest are not run by Node.js directly, but the
|
|
66
|
+
same compiler options apply to them.
|
|
67
|
+
|
|
68
|
+
JSII and AWS CDK construct library projects keep using `tsx`, because jsii compiles to CommonJS, and
|
|
69
|
+
their `.projenrc.ts` often imports their own `src`.
|
|
70
|
+
|
|
71
|
+
When you start a new project by hand, make sure `package.json` has `"type": "module"` before the
|
|
72
|
+
first `node .projenrc.ts`: `npm init` writes `"type": "commonjs"`, which makes Node.js reject the
|
|
73
|
+
`import` statements in `.projenrc.ts`.
|
|
74
|
+
|
|
75
|
+
## Customization
|
|
76
|
+
|
|
77
|
+
Override any option by passing it to the constructor:
|
|
78
|
+
|
|
79
|
+
```typescript
|
|
80
|
+
import { JsiiProject } from "@nikovirtala/projen-constructs";
|
|
81
|
+
|
|
82
|
+
const project = new JsiiProject({
|
|
83
|
+
name: "my-project",
|
|
84
|
+
author: "Custom Author",
|
|
85
|
+
authorAddress: "custom@example.com",
|
|
86
|
+
repositoryUrl: "https://github.com/nikovirtala/my-project.git",
|
|
87
|
+
minNodeVersion: "26.0.0",
|
|
88
|
+
mise: false,
|
|
89
|
+
vitest: false,
|
|
90
|
+
tsconfig: {
|
|
91
|
+
compilerOptions: {
|
|
92
|
+
noUnusedLocals: false,
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
biomeOptions: {
|
|
96
|
+
biomeConfig: {
|
|
97
|
+
formatter: {
|
|
98
|
+
lineWidth: 100,
|
|
99
|
+
},
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
project.synth();
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Every component is exposed as an enable flag (`mise`, `vitest`, ...) plus an options property
|
|
108
|
+
(`miseOptions`, `vitestOptions`, ...).
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# Development
|
|
2
|
+
|
|
3
|
+
This project is managed by projen and generates itself: `.projenrc.ts` defines the project using the
|
|
4
|
+
`JsiiProject` type from `src/`. Configuration changes belong in `.projenrc.ts`, never in the
|
|
5
|
+
generated files.
|
|
6
|
+
|
|
7
|
+
## Commands
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
pnpm projen # synthesize project files
|
|
11
|
+
pnpm build # synthesize, compile, test and package
|
|
12
|
+
pnpm test # biome, vitest, typedoc
|
|
13
|
+
pnpm test:watch # vitest in watch mode
|
|
14
|
+
pnpm test:update # update snapshots
|
|
15
|
+
pnpm biome # format and lint
|
|
16
|
+
pnpm docgen # regenerate API.md from the .jsii manifest
|
|
17
|
+
pnpm update-versions # refresh src/versions.json
|
|
18
|
+
pnpm upgrade # upgrade dependencies
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Build process
|
|
22
|
+
|
|
23
|
+
The diagram below shows how synthesis, compile, test and package connect. Each node names a task or
|
|
24
|
+
artifact, and the arrows show the order they run in.
|
|
25
|
+
|
|
26
|
+
```mermaid
|
|
27
|
+
flowchart TD
|
|
28
|
+
projenrc[".projenrc.ts"]
|
|
29
|
+
|
|
30
|
+
subgraph synthesize["default (synthesize)"]
|
|
31
|
+
direction TB
|
|
32
|
+
synth["tsx .projenrc.ts"]
|
|
33
|
+
generator["ProjectGenerator"]
|
|
34
|
+
generated["src/project-type.ts<br/>src/projects/*.generated.ts<br/>src/projects/*-options.generated.ts"]
|
|
35
|
+
projenfiles["package.json, tsconfig.json,<br/>pnpm-workspace.yaml, workflows, ..."]
|
|
36
|
+
brew["install:homebrew<br/>brew bundle"]
|
|
37
|
+
definecfg["bundle-vitest-define-config<br/>esbuild → lib/vitest-define-config.js"]
|
|
38
|
+
|
|
39
|
+
synth --> generator --> generated
|
|
40
|
+
synth --> projenfiles
|
|
41
|
+
synth --> brew
|
|
42
|
+
synth --> definecfg
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
subgraph compile["compile"]
|
|
46
|
+
direction TB
|
|
47
|
+
jsii["jsii<br/>validates tsconfig.json against the strict rule set"]
|
|
48
|
+
lib["lib/**"]
|
|
49
|
+
manifest[".jsii manifest"]
|
|
50
|
+
|
|
51
|
+
jsii --> lib
|
|
52
|
+
jsii --> manifest
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
subgraph test["test"]
|
|
56
|
+
direction TB
|
|
57
|
+
biome["biome check --write"]
|
|
58
|
+
vitest["vitest run<br/>+ type checking"]
|
|
59
|
+
typedoc["typedoc → docs/api"]
|
|
60
|
+
|
|
61
|
+
biome --> vitest --> typedoc
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
subgraph package["package"]
|
|
65
|
+
direction TB
|
|
66
|
+
pacmak["jsii-pacmak<br/>--pack-command 'pnpm pack'"]
|
|
67
|
+
dist["dist/js/*.tgz"]
|
|
68
|
+
|
|
69
|
+
pacmak --> dist
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
projenrc --> synthesize
|
|
73
|
+
synthesize --> compile
|
|
74
|
+
compile --> test
|
|
75
|
+
test --> package
|
|
76
|
+
|
|
77
|
+
manifest -. "component options FQNs<br/>read on the next synthesis" .-> generator
|
|
78
|
+
docgen["docgen<br/>jsii-docgen → API.md"]
|
|
79
|
+
manifest --> docgen
|
|
80
|
+
|
|
81
|
+
classDef artifact fill:#eef,stroke:#88a
|
|
82
|
+
class generated,projenfiles,lib,manifest,dist artifact
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
The dashed edge is the part worth knowing about: `ProjectGenerator` reads the committed `.jsii`
|
|
86
|
+
manifest to resolve component options types, so the manifest produced by `compile` feeds the *next*
|
|
87
|
+
synthesis. This is why `.jsii` is committed rather than ignored. A component options type that is
|
|
88
|
+
missing from the manifest is reported as a warning and its options property is left out of the
|
|
89
|
+
generated interface, which is expected only while a new component is being introduced: compile once,
|
|
90
|
+
then synthesize again.
|
|
91
|
+
|
|
92
|
+
`package` runs `package:js` on CI and `package-all` locally; both end up in `jsii-pacmak`.
|
|
93
|
+
`docgen` is not part of `build` and has to be run explicitly after the manifest changes.
|