@mrgrain/cdk-esbuild 3.11.1 → 3.11.3

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 CHANGED
@@ -2777,7 +2777,7 @@
2777
2777
  "stability": "stable"
2778
2778
  },
2779
2779
  "homepage": "https://github.com/mrgrain/cdk-esbuild",
2780
- "jsiiVersion": "1.65.0 (build 7a02b7f)",
2780
+ "jsiiVersion": "1.70.0 (build 03c2f6f)",
2781
2781
  "keywords": [
2782
2782
  "aws-cdk",
2783
2783
  "bundler",
@@ -2800,7 +2800,7 @@
2800
2800
  },
2801
2801
  "name": "@mrgrain/cdk-esbuild",
2802
2802
  "readme": {
2803
- "markdown": "<picture>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/mrgrain/cdk-esbuild/main/images/wordmark-dark.svg\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/mrgrain/cdk-esbuild/main/images/wordmark-light.svg\">\n <img src=\"https://raw.githubusercontent.com/mrgrain/cdk-esbuild/main/images/wordmark-dynamic.svg\" alt=\"cdk-esbuild\">\n</picture>\n\n_CDK constructs for [esbuild](https://github.com/evanw/esbuild), an extremely fast JavaScript bundler_\n\n[Getting started](#getting-started) |\n[Documentation](#documentation) | [API Reference](#api-reference) | [Upgrading from AWS CDK v1](#upgrading-from-aws-cdk-v1)\n\n[![View on Construct Hub](https://constructs.dev/badge?package=%40mrgrain%2Fcdk-esbuild)](https://constructs.dev/packages/@mrgrain/cdk-esbuild)\n\n## Why?\n\n_esbuild_ is an extremely fast bundler and minifier for Typescript and JavaScript.\nThis package makes _esbuild_ available to deploy lambda functions, static websites or to publish build artefacts (assets) for further use.\n\nAWS CDK [supports _esbuild_ with Lambda Functions](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-lambda-nodejs-readme.html). However the implementation cannot be used with any other Constructs and doesn't expose all of _esbuild_'s build interface.\n\nThis package is running _esbuild_ directly in Node.js and bypasses Docker which the AWS CDK implementation uses. The approach is quicker and easier to use for Node.js users, but incompatible with other languages.\n\n**Production readiness**\n\nThis package is stable and ready to be used in production, as many do. However _esbuild_ has not yet released a version 1.0.0 and its API is still in active development. Please read the guide on [esbuild's production readiness](https://esbuild.github.io/faq/#production-readiness).\n\nNotably upgrades of the _esbuild_ minimum version requirement will be introduced in **minor versions** of this package and will inherit breaking changes from _esbuild_.\n\n## Getting started\n\nInstall `cdk-esbuild`:\n\n```\nnpm install @mrgrain/cdk-esbuild@3\n```\n\nIf _peer_ or _optional dependencies_ are not installed automatically (e.g. when using npm v4-6), please use this command to install all of them:\n\n```\nnpm install @mrgrain/cdk-esbuild@3 esbuild\n```\n\n### AWS Lambda: Serverless function\n\n> 💡 See [Lambda Function](examples/typescript/lambda) for a complete working example of a how to deploy a lambda function.\n\nUse `TypeScriptCode` as the `code` of a [lambda function](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_lambda.Function.html#code):\n\n```ts\nimport * as lambda from \"aws-cdk-lib/aws-lambda\";\nimport { TypeScriptCode } from \"@mrgrain/cdk-esbuild\";\n\nconst bundledCode = new TypeScriptCode(\"src/index.ts\");\n\nconst fn = new lambda.Function(stack, \"MyFunction\", {\n runtime: lambda.Runtime.NODEJS_16_X,\n handler: \"index.handler\",\n code: bundledCode,\n});\n```\n\n### AWS S3: Static Website\n\n> 💡 See [Static Website with React](examples/typescript/website) for a complete working example of a how to deploy a React app to S3.\n\nUse `TypeScriptSource` as one of the `sources` of a [static website deployment](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-s3-deployment-readme.html#roadmap):\n\n```ts\nimport * as s3 from \"aws-cdk-lib/aws-s3\";\nimport * as s3deploy from \"aws-cdk-lib/aws-s3-deployment\";\nimport { TypeScriptSource } from \"@mrgrain/cdk-esbuild\";\n\nconst websiteBundle = new TypeScriptSource(\"src/index.tsx\");\n\nconst websiteBucket = new s3.Bucket(stack, \"WebsiteBucket\", {\n autoDeleteObjects: true,\n publicReadAccess: true,\n removalPolicy: RemovalPolicy.DESTROY,\n websiteIndexDocument: \"index.html\",\n});\n\nnew s3deploy.BucketDeployment(stack, \"DeployWebsite\", {\n destinationBucket: websiteBucket,\n sources: [websiteBundle],\n});\n```\n\n### Amazon CloudWatch Synthetics: Canary monitoring\n\n> 💡 See [Monitored Website](examples/typescript/website) for a complete working example of a deployed and monitored website.\n\nSynthetics runs a canary to produce traffic to an application for monitoring purposes. Use `TypeScriptCode` as the `code` of a Canary test:\n\n> ℹ️ This feature depends on the `@aws-cdk/aws-synthetics-alpha` package which is a developer preview. You may need to update your source code when upgrading to a newer version of this package.\n>\n> ```\n> npm i @aws-cdk/aws-synthetics-alpha\n> ```\n\n```ts\nimport * as synthetics from \"@aws-cdk/aws-synthetics-alpha\";\nimport { TypeScriptCode } from \"@mrgrain/cdk-esbuild\";\n\nconst bundledCode = new TypeScriptCode(\"src/index.ts\", {\n buildOptions: {\n outdir: \"nodejs/node_modules\", // This is required by Synthetics\n },\n});\n\nconst canary = new synthetics.Canary(stack, \"MyCanary\", {\n runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_2,\n test: synthetics.Test.custom({\n code: bundledCode,\n handler: \"index.handler\",\n });\n});\n```\n\n## Documentation\n\nThe package exports various different constructs for use with existing CDK features. A major guiding design principal for this package is to _extend, don't replace_. Expect constructs that you can provide as props, not complete replacements.\n\nFor use in **Lambda Functions** and **Synthetic Canaries**, the following classes implement `lambda.Code` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_lambda.Code.html)) and `synthetics.Code` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/@aws-cdk_aws-synthetics-alpha.Code.html)):\n\n- `TypeScriptCode` & `JavaScriptCode`\n\nInline code is only supported by **Lambda**:\n\n- `InlineTypeScriptCode` & `InlineJavaScriptCode`\n- `InlineTsxCode` & `InlineJsxCode`\n\nFor use with **S3 bucket deployments**, classes implementing `s3deploy.ISource` ([reference](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-s3-deployment-readme.html)):\n\n- `TypeScriptSource` & `JavaScriptSource`\n\n> _Code and Source constructs seamlessly plug-in to other high-level CDK constructs. They share the same set of parameters, props and build options._\n\nThe following classes power the other features. You normally won't have to use them, but they are there if you need them:\n\n- `TypeScriptAsset` & `JavaScriptAsset` implements `s3.Asset` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_s3_assets.Asset.html)) \\\n creates an asset uploaded to S3 which can be referenced by other constructs\n\n- `EsbuildBundler` implements `core.BundlingOptions` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.BundlingOptions.html)) \\\n provides an interface for a _esbuild_ bundler wherever needed\n\n### [API Reference](API.md)\n\nAuto-generated reference for classes and structs. This information is also available as part of your IDE's code completion.\n\n### Escape hatches\n\nIt's possible that you want to use an implementation of esbuild that's different to the default one. Common reasons are:\n\n- The current version constraints for esbuild are not suitable\n- To use a version of esbuild that is installed by any other means than `npm`, including Docker\n- Plugin support is needed for building\n\nFor these situations, this package offers an escape hatch to bypass regular the implementation and provide a custom build and transform function.\n\n#### Esbuild binary path\n\nIt is possible to override the binary used by esbuild. The usual way to do this is to set the `ESBUILD_BINARY_PATH` environment variable. For convenience this package allows to set the binary path as a prop:\n\n```ts\nnew TypeScriptCode(\"fixtures/handlers/ts-handler.ts\", {\n esbuildBinaryPath: \"path/to/esbuild/binary\"\n});\n```\n\n#### Custom build function\n\n> 💡 See [Using esbuild with plugins](examples/typescript/esbuild-with-plugins) for a complete working example of a custom build function using this escape hatch.\n\nConstructs that result in starting a build, take a `buildFn` as optional prop. While the defined type for this function is `any`, it must implement the same signature as esbuild's `buildSync` function.\n\n```ts\nnew TypeScriptCode(\"fixtures/handlers/ts-handler.ts\", {\n buildFn: (options: BuildOptions): BuildResult => {\n try {\n // custom implementation returning BuildResult\n } catch (error) {\n // throw BuildFailure exception here\n }\n },\n});\n```\n\nInstead of esbuild, the provided function will be invoked with the calculated build options. The custom build function can amend, change or discard any of these. However integration with CDK relies heavily on the values `outdir`/`outfile` are set to and it's usually required to use them unchanged.\n\nFailures have to cause a `BuildFailure` exception in order to be fully handled.\n\n#### Custom transform function\n\nConstructs that result in starting a transformation, take a `transformFn` as optional prop. While the defined type for this function is `any`, it must implement the same signature as esbuild's `transformSync` function.\n\n```ts\nnew InlineTypeScriptCode(\"let x: number = 1\", {\n transformFn: (options: TransformOptions): TransformResult => {\n try {\n // custom implementation returning TransformResult\n } catch (error) {\n // throw TransformFailure exception here\n }\n },,\n});\n```\n\nInstead of esbuild, the provided function will be invoked with the calculated transform options. The custom transform function can amend, change or discard any of these.\n\nFailures have to cause a `TransformFailure` exception in order to be fully handled.\n\n### Upgrading from AWS CDK v1\n\nThis version is compatible with AWS CDK v2. For the previous, AWS CDK v1 compatible release, see [cdk-esbuild@v2](https://github.com/mrgrain/cdk-esbuild/tree/v2).\n\nTo upgrade from AWS CDK v1 and cdk-esbuild@v2, please follow these steps:\n\n- This version requires AWS CDK v2. Follow the [official migration guide](https://docs.aws.amazon.com/cdk/latest/guide/work-with-cdk-v2.html) to upgrade.\n- Update the package dependency to v3: `npm install --save @mrgrain/cdk-esbuild@^3.0.0`\n- `esbuild` is installed as an optional dependency. If your setup does not automatically install optional dependencies, make sure to add it as an explicit dependency.\n- Any use of `InlineCode` variations has to be updated. Previously the second parameter was either of type `TransformerProps` or `TransformOptions`. Now it must be `TransformerProps`.\\\n If the passed value is of type `TransformOptions`, turn it into the correct type like this:\n\n ```ts\n const oldOptions: TransformOptions = {...}\n\n new InlineTypeScriptCode('// inline code', {\n transformOptions: oldOptions\n });\n ```\n\n## Versioning\n\nThis package follows [Semantic Versioning](https://semver.org/), with the exception of upgrades to `esbuild`. These will be released as **minor versions** and often include breaking changes from `esbuild`.\n\n### Npm Tags\n\nSome users prefer to use tags over version ranges. The following stable tags are available for use:\n\n- `cdk-v1`, `cdk-v2` are provided for the latest release compatible with each version of the AWS CDK.\n\n- `latest` is the most recent stable release.\n\nThese tags also exist, but usage is strongly not recommended:\n\n- `unstable`, `next` are used for pre-release of the current and next major version respectively.\n\n- ~~`cdk-1.x.x`~~ tags have been deprecated in favour of `cdk-v1`. Use that one instead.\n\n## Roadmap & Contributions\n\n[The project's roadmap is available on GitHub.](https://github.com/mrgrain/cdk-esbuild/projects/1) Please submit any feature requests as issues to the repository.\n\nAll contributions are welcome, no matter if they are for already planned or completely new features.\n\n## Library authors\n\nBuilding a library consumed by other packages that relies on `cdk-esbuild` might require you to set `buildOptions.absWorkingDir`. The easiest way to do this, is to resolve based on the directory name of the calling file, and traverse the tree upwards to the root of your library package (that's where `package.json` and `tsconfig.json` are):\n\n```ts\n// file: project/src/index.ts\nconst props = {\n buildOptions: {\n absWorkingDir: path.resolve(__dirname, \"..\"), // now: /user/project\n },\n};\n```\n\nThis will dynamically resolve to the correct path, wherever the package is installed.\n\nPlease open an issue if you encounter any difficulties.\n"
2803
+ "markdown": "<img src=\"https://raw.githubusercontent.com/mrgrain/cdk-esbuild/main/images/wordmark-light.svg\" alt=\"cdk-esbuild\">\n\n_CDK constructs for [esbuild](https://github.com/evanw/esbuild), an extremely fast JavaScript bundler_\n\n[Getting started](#getting-started) |\n[Documentation](#documentation) | [API Reference](#api-reference) | [Upgrading from AWS CDK v1](#upgrading-from-aws-cdk-v1)\n\n[![View on Construct Hub](https://constructs.dev/badge?package=%40mrgrain%2Fcdk-esbuild)](https://constructs.dev/packages/@mrgrain/cdk-esbuild)\n\n## Why?\n\n_esbuild_ is an extremely fast bundler and minifier for Typescript and JavaScript.\nThis package makes _esbuild_ available to deploy lambda functions, static websites or to publish build artefacts (assets) for further use.\n\nAWS CDK [supports _esbuild_ with Lambda Functions](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-lambda-nodejs-readme.html). However the implementation cannot be used with any other Constructs and doesn't expose all of _esbuild_'s build interface.\n\nThis package is running _esbuild_ directly in Node.js and bypasses Docker which the AWS CDK implementation uses. The approach is quicker and easier to use for Node.js users, but incompatible with other languages.\n\n**Production readiness**\n\nThis package is stable and ready to be used in production, as many do. However _esbuild_ has not yet released a version 1.0.0 and its API is still in active development. Please read the guide on [esbuild's production readiness](https://esbuild.github.io/faq/#production-readiness).\n\nNotably upgrades of the _esbuild_ minimum version requirement will be introduced in **minor versions** of this package and will inherit breaking changes from _esbuild_.\n\n## Getting started\n\nInstall `cdk-esbuild`:\n\n```\nnpm install @mrgrain/cdk-esbuild@3\n```\n\nIf _peer_ or _optional dependencies_ are not installed automatically (e.g. when using npm v4-6), please use this command to install all of them:\n\n```\nnpm install @mrgrain/cdk-esbuild@3 esbuild\n```\n\n### AWS Lambda: Serverless function\n\n> 💡 See [Lambda Function](examples/typescript/lambda) for a complete working example of a how to deploy a lambda function.\n\nUse `TypeScriptCode` as the `code` of a [lambda function](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_lambda.Function.html#code):\n\n```ts\nimport * as lambda from \"aws-cdk-lib/aws-lambda\";\nimport { TypeScriptCode } from \"@mrgrain/cdk-esbuild\";\n\nconst bundledCode = new TypeScriptCode(\"src/index.ts\");\n\nconst fn = new lambda.Function(stack, \"MyFunction\", {\n runtime: lambda.Runtime.NODEJS_16_X,\n handler: \"index.handler\",\n code: bundledCode,\n});\n```\n\n### AWS S3: Static Website\n\n> 💡 See [Static Website with React](examples/typescript/website) for a complete working example of a how to deploy a React app to S3.\n\nUse `TypeScriptSource` as one of the `sources` of a [static website deployment](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-s3-deployment-readme.html#roadmap):\n\n```ts\nimport * as s3 from \"aws-cdk-lib/aws-s3\";\nimport * as s3deploy from \"aws-cdk-lib/aws-s3-deployment\";\nimport { TypeScriptSource } from \"@mrgrain/cdk-esbuild\";\n\nconst websiteBundle = new TypeScriptSource(\"src/index.tsx\");\n\nconst websiteBucket = new s3.Bucket(stack, \"WebsiteBucket\", {\n autoDeleteObjects: true,\n publicReadAccess: true,\n removalPolicy: RemovalPolicy.DESTROY,\n websiteIndexDocument: \"index.html\",\n});\n\nnew s3deploy.BucketDeployment(stack, \"DeployWebsite\", {\n destinationBucket: websiteBucket,\n sources: [websiteBundle],\n});\n```\n\n### Amazon CloudWatch Synthetics: Canary monitoring\n\n> 💡 See [Monitored Website](examples/typescript/website) for a complete working example of a deployed and monitored website.\n\nSynthetics runs a canary to produce traffic to an application for monitoring purposes. Use `TypeScriptCode` as the `code` of a Canary test:\n\n> ℹ️ This feature depends on the `@aws-cdk/aws-synthetics-alpha` package which is a developer preview. You may need to update your source code when upgrading to a newer version of this package.\n>\n> ```\n> npm i @aws-cdk/aws-synthetics-alpha\n> ```\n\n```ts\nimport * as synthetics from \"@aws-cdk/aws-synthetics-alpha\";\nimport { TypeScriptCode } from \"@mrgrain/cdk-esbuild\";\n\nconst bundledCode = new TypeScriptCode(\"src/index.ts\", {\n buildOptions: {\n outdir: \"nodejs/node_modules\", // This is required by Synthetics\n },\n});\n\nconst canary = new synthetics.Canary(stack, \"MyCanary\", {\n runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_2,\n test: synthetics.Test.custom({\n code: bundledCode,\n handler: \"index.handler\",\n });\n});\n```\n\n## Documentation\n\nThe package exports various different constructs for use with existing CDK features. A major guiding design principal for this package is to _extend, don't replace_. Expect constructs that you can provide as props, not complete replacements.\n\nFor use in **Lambda Functions** and **Synthetic Canaries**, the following classes implement `lambda.Code` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_lambda.Code.html)) and `synthetics.Code` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/@aws-cdk_aws-synthetics-alpha.Code.html)):\n\n- `TypeScriptCode` & `JavaScriptCode`\n\nInline code is only supported by **Lambda**:\n\n- `InlineTypeScriptCode` & `InlineJavaScriptCode`\n- `InlineTsxCode` & `InlineJsxCode`\n\nFor use with **S3 bucket deployments**, classes implementing `s3deploy.ISource` ([reference](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-s3-deployment-readme.html)):\n\n- `TypeScriptSource` & `JavaScriptSource`\n\n> _Code and Source constructs seamlessly plug-in to other high-level CDK constructs. They share the same set of parameters, props and build options._\n\nThe following classes power the other features. You normally won't have to use them, but they are there if you need them:\n\n- `TypeScriptAsset` & `JavaScriptAsset` implements `s3.Asset` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_s3_assets.Asset.html)) \\\n creates an asset uploaded to S3 which can be referenced by other constructs\n\n- `EsbuildBundler` implements `core.BundlingOptions` ([reference](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.BundlingOptions.html)) \\\n provides an interface for a _esbuild_ bundler wherever needed\n\n### [API Reference](API.md)\n\nAuto-generated reference for classes and structs. This information is also available as part of your IDE's code completion.\n\n### Escape hatches\n\nIt's possible that you want to use an implementation of esbuild that's different to the default one. Common reasons are:\n\n- The current version constraints for esbuild are not suitable\n- To use a version of esbuild that is installed by any other means than `npm`, including Docker\n- Plugin support is needed for building\n\nFor these situations, this package offers an escape hatch to bypass regular the implementation and provide a custom build and transform function.\n\n#### Esbuild binary path\n\nIt is possible to override the binary used by esbuild. The usual way to do this is to set the `ESBUILD_BINARY_PATH` environment variable. For convenience this package allows to set the binary path as a prop:\n\n```ts\nnew TypeScriptCode(\"fixtures/handlers/ts-handler.ts\", {\n esbuildBinaryPath: \"path/to/esbuild/binary\"\n});\n```\n\n#### Custom build function\n\n> 💡 See [Using esbuild with plugins](examples/typescript/esbuild-with-plugins) for a complete working example of a custom build function using this escape hatch.\n\nConstructs that result in starting a build, take a `buildFn` as optional prop. While the defined type for this function is `any`, it must implement the same signature as esbuild's `buildSync` function.\n\n```ts\nnew TypeScriptCode(\"fixtures/handlers/ts-handler.ts\", {\n buildFn: (options: BuildOptions): BuildResult => {\n try {\n // custom implementation returning BuildResult\n } catch (error) {\n // throw BuildFailure exception here\n }\n },\n});\n```\n\nInstead of esbuild, the provided function will be invoked with the calculated build options. The custom build function can amend, change or discard any of these. However integration with CDK relies heavily on the values `outdir`/`outfile` are set to and it's usually required to use them unchanged.\n\nFailures have to cause a `BuildFailure` exception in order to be fully handled.\n\n#### Custom transform function\n\nConstructs that result in starting a transformation, take a `transformFn` as optional prop. While the defined type for this function is `any`, it must implement the same signature as esbuild's `transformSync` function.\n\n```ts\nnew InlineTypeScriptCode(\"let x: number = 1\", {\n transformFn: (options: TransformOptions): TransformResult => {\n try {\n // custom implementation returning TransformResult\n } catch (error) {\n // throw TransformFailure exception here\n }\n },,\n});\n```\n\nInstead of esbuild, the provided function will be invoked with the calculated transform options. The custom transform function can amend, change or discard any of these.\n\nFailures have to cause a `TransformFailure` exception in order to be fully handled.\n\n### Upgrading from AWS CDK v1\n\nThis version is compatible with AWS CDK v2. For the previous, AWS CDK v1 compatible release, see [cdk-esbuild@v2](https://github.com/mrgrain/cdk-esbuild/tree/v2).\n\nTo upgrade from AWS CDK v1 and cdk-esbuild@v2, please follow these steps:\n\n- This version requires AWS CDK v2. Follow the [official migration guide](https://docs.aws.amazon.com/cdk/latest/guide/work-with-cdk-v2.html) to upgrade.\n- Update the package dependency to v3: `npm install --save @mrgrain/cdk-esbuild@^3.0.0`\n- `esbuild` is installed as an optional dependency. If your setup does not automatically install optional dependencies, make sure to add it as an explicit dependency.\n- Any use of `InlineCode` variations has to be updated. Previously the second parameter was either of type `TransformerProps` or `TransformOptions`. Now it must be `TransformerProps`.\\\n If the passed value is of type `TransformOptions`, turn it into the correct type like this:\n\n ```ts\n const oldOptions: TransformOptions = {...}\n\n new InlineTypeScriptCode('// inline code', {\n transformOptions: oldOptions\n });\n ```\n\n## Versioning\n\nThis package follows [Semantic Versioning](https://semver.org/), with the exception of upgrades to `esbuild`. These will be released as **minor versions** and often include breaking changes from `esbuild`.\n\n### Npm Tags\n\nSome users prefer to use tags over version ranges. The following stable tags are available for use:\n\n- `cdk-v1`, `cdk-v2` are provided for the latest release compatible with each version of the AWS CDK.\n\n- `latest` is the most recent stable release.\n\nThese tags also exist, but usage is strongly not recommended:\n\n- `unstable`, `next` are used for pre-release of the current and next major version respectively.\n\n- ~~`cdk-1.x.x`~~ tags have been deprecated in favour of `cdk-v1`. Use that one instead.\n\n## Roadmap & Contributions\n\n[The project's roadmap is available on GitHub.](https://github.com/mrgrain/cdk-esbuild/projects/1) Please submit any feature requests as issues to the repository.\n\nAll contributions are welcome, no matter if they are for already planned or completely new features.\n\n## Library authors\n\nBuilding a library consumed by other packages that relies on `cdk-esbuild` might require you to set `buildOptions.absWorkingDir`. The easiest way to do this, is to resolve based on the directory name of the calling file, and traverse the tree upwards to the root of your library package (that's where `package.json` and `tsconfig.json` are):\n\n```ts\n// file: project/src/index.ts\nconst props = {\n buildOptions: {\n absWorkingDir: path.resolve(__dirname, \"..\"), // now: /user/project\n },\n};\n```\n\nThis will dynamically resolve to the correct path, wherever the package is installed.\n\nPlease open an issue if you encounter any difficulties.\n"
2804
2804
  },
2805
2805
  "repository": {
2806
2806
  "type": "git",
@@ -2909,7 +2909,7 @@
2909
2909
  "kind": "interface",
2910
2910
  "locationInModule": {
2911
2911
  "filename": "src/esbuild-types.ts",
2912
- "line": 84
2912
+ "line": 86
2913
2913
  },
2914
2914
  "name": "BuildOptions",
2915
2915
  "properties": [
@@ -2922,7 +2922,7 @@
2922
2922
  "immutable": true,
2923
2923
  "locationInModule": {
2924
2924
  "filename": "src/esbuild-types.ts",
2925
- "line": 134
2925
+ "line": 136
2926
2926
  },
2927
2927
  "name": "absWorkingDir",
2928
2928
  "optional": true,
@@ -2939,7 +2939,7 @@
2939
2939
  "immutable": true,
2940
2940
  "locationInModule": {
2941
2941
  "filename": "src/esbuild-types.ts",
2942
- "line": 112
2942
+ "line": 114
2943
2943
  },
2944
2944
  "name": "allowOverwrite",
2945
2945
  "optional": true,
@@ -2956,7 +2956,7 @@
2956
2956
  "immutable": true,
2957
2957
  "locationInModule": {
2958
2958
  "filename": "src/esbuild-types.ts",
2959
- "line": 124
2959
+ "line": 126
2960
2960
  },
2961
2961
  "name": "assetNames",
2962
2962
  "optional": true,
@@ -2973,7 +2973,7 @@
2973
2973
  "immutable": true,
2974
2974
  "locationInModule": {
2975
2975
  "filename": "src/esbuild-types.ts",
2976
- "line": 128
2976
+ "line": 130
2977
2977
  },
2978
2978
  "name": "banner",
2979
2979
  "optional": true,
@@ -2995,7 +2995,7 @@
2995
2995
  "immutable": true,
2996
2996
  "locationInModule": {
2997
2997
  "filename": "src/esbuild-types.ts",
2998
- "line": 86
2998
+ "line": 88
2999
2999
  },
3000
3000
  "name": "bundle",
3001
3001
  "optional": true,
@@ -3029,7 +3029,7 @@
3029
3029
  "immutable": true,
3030
3030
  "locationInModule": {
3031
3031
  "filename": "src/esbuild-types.ts",
3032
- "line": 122
3032
+ "line": 124
3033
3033
  },
3034
3034
  "name": "chunkNames",
3035
3035
  "optional": true,
@@ -3046,7 +3046,7 @@
3046
3046
  "immutable": true,
3047
3047
  "locationInModule": {
3048
3048
  "filename": "src/esbuild-types.ts",
3049
- "line": 75
3049
+ "line": 77
3050
3050
  },
3051
3051
  "name": "color",
3052
3052
  "optional": true,
@@ -3063,7 +3063,7 @@
3063
3063
  "immutable": true,
3064
3064
  "locationInModule": {
3065
3065
  "filename": "src/esbuild-types.ts",
3066
- "line": 108
3066
+ "line": 110
3067
3067
  },
3068
3068
  "name": "conditions",
3069
3069
  "optional": true,
@@ -3085,7 +3085,7 @@
3085
3085
  "immutable": true,
3086
3086
  "locationInModule": {
3087
3087
  "filename": "src/esbuild-types.ts",
3088
- "line": 68
3088
+ "line": 70
3089
3089
  },
3090
3090
  "name": "define",
3091
3091
  "optional": true,
@@ -3129,7 +3129,7 @@
3129
3129
  "immutable": true,
3130
3130
  "locationInModule": {
3131
3131
  "filename": "src/esbuild-types.ts",
3132
- "line": 120
3132
+ "line": 122
3133
3133
  },
3134
3134
  "name": "entryNames",
3135
3135
  "optional": true,
@@ -3146,7 +3146,7 @@
3146
3146
  "immutable": true,
3147
3147
  "locationInModule": {
3148
3148
  "filename": "src/esbuild-types.ts",
3149
- "line": 100
3149
+ "line": 102
3150
3150
  },
3151
3151
  "name": "external",
3152
3152
  "optional": true,
@@ -3168,7 +3168,7 @@
3168
3168
  "immutable": true,
3169
3169
  "locationInModule": {
3170
3170
  "filename": "src/esbuild-types.ts",
3171
- "line": 130
3171
+ "line": 132
3172
3172
  },
3173
3173
  "name": "footer",
3174
3174
  "optional": true,
@@ -3241,7 +3241,7 @@
3241
3241
  "immutable": true,
3242
3242
  "locationInModule": {
3243
3243
  "filename": "src/esbuild-types.ts",
3244
- "line": 132
3244
+ "line": 134
3245
3245
  },
3246
3246
  "name": "incremental",
3247
3247
  "optional": true,
@@ -3258,7 +3258,7 @@
3258
3258
  "immutable": true,
3259
3259
  "locationInModule": {
3260
3260
  "filename": "src/esbuild-types.ts",
3261
- "line": 126
3261
+ "line": 128
3262
3262
  },
3263
3263
  "name": "inject",
3264
3264
  "optional": true,
@@ -3356,6 +3356,23 @@
3356
3356
  "primitive": "string"
3357
3357
  }
3358
3358
  },
3359
+ {
3360
+ "abstract": true,
3361
+ "docs": {
3362
+ "stability": "stable",
3363
+ "summary": "Documentation: https://esbuild.github.io/api/#jsx-side-effects."
3364
+ },
3365
+ "immutable": true,
3366
+ "locationInModule": {
3367
+ "filename": "src/esbuild-types.ts",
3368
+ "line": 67
3369
+ },
3370
+ "name": "jsxSideEffects",
3371
+ "optional": true,
3372
+ "type": {
3373
+ "primitive": "boolean"
3374
+ }
3375
+ },
3359
3376
  {
3360
3377
  "abstract": true,
3361
3378
  "docs": {
@@ -3365,7 +3382,7 @@
3365
3382
  "immutable": true,
3366
3383
  "locationInModule": {
3367
3384
  "filename": "src/esbuild-types.ts",
3368
- "line": 72
3385
+ "line": 74
3369
3386
  },
3370
3387
  "name": "keepNames",
3371
3388
  "optional": true,
@@ -3399,7 +3416,7 @@
3399
3416
  "immutable": true,
3400
3417
  "locationInModule": {
3401
3418
  "filename": "src/esbuild-types.ts",
3402
- "line": 102
3419
+ "line": 104
3403
3420
  },
3404
3421
  "name": "loader",
3405
3422
  "optional": true,
@@ -3421,7 +3438,7 @@
3421
3438
  "immutable": true,
3422
3439
  "locationInModule": {
3423
3440
  "filename": "src/esbuild-types.ts",
3424
- "line": 77
3441
+ "line": 79
3425
3442
  },
3426
3443
  "name": "logLevel",
3427
3444
  "optional": true,
@@ -3438,7 +3455,7 @@
3438
3455
  "immutable": true,
3439
3456
  "locationInModule": {
3440
3457
  "filename": "src/esbuild-types.ts",
3441
- "line": 79
3458
+ "line": 81
3442
3459
  },
3443
3460
  "name": "logLimit",
3444
3461
  "optional": true,
@@ -3455,7 +3472,7 @@
3455
3472
  "immutable": true,
3456
3473
  "locationInModule": {
3457
3474
  "filename": "src/esbuild-types.ts",
3458
- "line": 81
3475
+ "line": 83
3459
3476
  },
3460
3477
  "name": "logOverride",
3461
3478
  "optional": true,
@@ -3477,7 +3494,7 @@
3477
3494
  "immutable": true,
3478
3495
  "locationInModule": {
3479
3496
  "filename": "src/esbuild-types.ts",
3480
- "line": 106
3497
+ "line": 108
3481
3498
  },
3482
3499
  "name": "mainFields",
3483
3500
  "optional": true,
@@ -3564,7 +3581,7 @@
3564
3581
  "immutable": true,
3565
3582
  "locationInModule": {
3566
3583
  "filename": "src/esbuild-types.ts",
3567
- "line": 94
3584
+ "line": 96
3568
3585
  },
3569
3586
  "name": "metafile",
3570
3587
  "optional": true,
@@ -3649,7 +3666,7 @@
3649
3666
  "immutable": true,
3650
3667
  "locationInModule": {
3651
3668
  "filename": "src/esbuild-types.ts",
3652
- "line": 136
3669
+ "line": 138
3653
3670
  },
3654
3671
  "name": "nodePaths",
3655
3672
  "optional": true,
@@ -3671,7 +3688,7 @@
3671
3688
  "immutable": true,
3672
3689
  "locationInModule": {
3673
3690
  "filename": "src/esbuild-types.ts",
3674
- "line": 98
3691
+ "line": 100
3675
3692
  },
3676
3693
  "name": "outbase",
3677
3694
  "optional": true,
@@ -3688,7 +3705,7 @@
3688
3705
  "immutable": true,
3689
3706
  "locationInModule": {
3690
3707
  "filename": "src/esbuild-types.ts",
3691
- "line": 96
3708
+ "line": 98
3692
3709
  },
3693
3710
  "name": "outdir",
3694
3711
  "optional": true,
@@ -3705,7 +3722,7 @@
3705
3722
  "immutable": true,
3706
3723
  "locationInModule": {
3707
3724
  "filename": "src/esbuild-types.ts",
3708
- "line": 116
3725
+ "line": 118
3709
3726
  },
3710
3727
  "name": "outExtension",
3711
3728
  "optional": true,
@@ -3727,7 +3744,7 @@
3727
3744
  "immutable": true,
3728
3745
  "locationInModule": {
3729
3746
  "filename": "src/esbuild-types.ts",
3730
- "line": 92
3747
+ "line": 94
3731
3748
  },
3732
3749
  "name": "outfile",
3733
3750
  "optional": true,
@@ -3761,7 +3778,7 @@
3761
3778
  "immutable": true,
3762
3779
  "locationInModule": {
3763
3780
  "filename": "src/esbuild-types.ts",
3764
- "line": 90
3781
+ "line": 92
3765
3782
  },
3766
3783
  "name": "preserveSymlinks",
3767
3784
  "optional": true,
@@ -3778,7 +3795,7 @@
3778
3795
  "immutable": true,
3779
3796
  "locationInModule": {
3780
3797
  "filename": "src/esbuild-types.ts",
3781
- "line": 118
3798
+ "line": 120
3782
3799
  },
3783
3800
  "name": "publicPath",
3784
3801
  "optional": true,
@@ -3795,7 +3812,7 @@
3795
3812
  "immutable": true,
3796
3813
  "locationInModule": {
3797
3814
  "filename": "src/esbuild-types.ts",
3798
- "line": 70
3815
+ "line": 72
3799
3816
  },
3800
3817
  "name": "pure",
3801
3818
  "optional": true,
@@ -3834,7 +3851,7 @@
3834
3851
  "immutable": true,
3835
3852
  "locationInModule": {
3836
3853
  "filename": "src/esbuild-types.ts",
3837
- "line": 104
3854
+ "line": 106
3838
3855
  },
3839
3856
  "name": "resolveExtensions",
3840
3857
  "optional": true,
@@ -3916,7 +3933,7 @@
3916
3933
  "immutable": true,
3917
3934
  "locationInModule": {
3918
3935
  "filename": "src/esbuild-types.ts",
3919
- "line": 88
3936
+ "line": 90
3920
3937
  },
3921
3938
  "name": "splitting",
3922
3939
  "optional": true,
@@ -4003,7 +4020,7 @@
4003
4020
  "immutable": true,
4004
4021
  "locationInModule": {
4005
4022
  "filename": "src/esbuild-types.ts",
4006
- "line": 114
4023
+ "line": 116
4007
4024
  },
4008
4025
  "name": "tsconfig",
4009
4026
  "optional": true,
@@ -4020,7 +4037,7 @@
4020
4037
  "immutable": true,
4021
4038
  "locationInModule": {
4022
4039
  "filename": "src/esbuild-types.ts",
4023
- "line": 110
4040
+ "line": 112
4024
4041
  },
4025
4042
  "name": "write",
4026
4043
  "optional": true,
@@ -4264,7 +4281,7 @@
4264
4281
  "kind": "interface",
4265
4282
  "locationInModule": {
4266
4283
  "filename": "src/esbuild-types.ts",
4267
- "line": 590
4284
+ "line": 593
4268
4285
  },
4269
4286
  "name": "CompilerOptions",
4270
4287
  "properties": [
@@ -4276,7 +4293,7 @@
4276
4293
  "immutable": true,
4277
4294
  "locationInModule": {
4278
4295
  "filename": "src/esbuild-types.ts",
4279
- "line": 594
4296
+ "line": 597
4280
4297
  },
4281
4298
  "name": "importsNotUsedAsValues",
4282
4299
  "optional": true,
@@ -4292,7 +4309,7 @@
4292
4309
  "immutable": true,
4293
4310
  "locationInModule": {
4294
4311
  "filename": "src/esbuild-types.ts",
4295
- "line": 591
4312
+ "line": 594
4296
4313
  },
4297
4314
  "name": "jsxFactory",
4298
4315
  "optional": true,
@@ -4308,7 +4325,7 @@
4308
4325
  "immutable": true,
4309
4326
  "locationInModule": {
4310
4327
  "filename": "src/esbuild-types.ts",
4311
- "line": 592
4328
+ "line": 595
4312
4329
  },
4313
4330
  "name": "jsxFragmentFactory",
4314
4331
  "optional": true,
@@ -4324,7 +4341,7 @@
4324
4341
  "immutable": true,
4325
4342
  "locationInModule": {
4326
4343
  "filename": "src/esbuild-types.ts",
4327
- "line": 595
4344
+ "line": 598
4328
4345
  },
4329
4346
  "name": "preserveValueImports",
4330
4347
  "optional": true,
@@ -4340,7 +4357,7 @@
4340
4357
  "immutable": true,
4341
4358
  "locationInModule": {
4342
4359
  "filename": "src/esbuild-types.ts",
4343
- "line": 593
4360
+ "line": 596
4344
4361
  },
4345
4362
  "name": "useDefineForClassFields",
4346
4363
  "optional": true,
@@ -5736,7 +5753,7 @@
5736
5753
  "kind": "interface",
5737
5754
  "locationInModule": {
5738
5755
  "filename": "src/esbuild-types.ts",
5739
- "line": 244
5756
+ "line": 246
5740
5757
  },
5741
5758
  "name": "TransformOptions",
5742
5759
  "properties": [
@@ -5748,7 +5765,7 @@
5748
5765
  "immutable": true,
5749
5766
  "locationInModule": {
5750
5767
  "filename": "src/esbuild-types.ts",
5751
- "line": 249
5768
+ "line": 251
5752
5769
  },
5753
5770
  "name": "banner",
5754
5771
  "optional": true,
@@ -5782,7 +5799,7 @@
5782
5799
  "immutable": true,
5783
5800
  "locationInModule": {
5784
5801
  "filename": "src/esbuild-types.ts",
5785
- "line": 75
5802
+ "line": 77
5786
5803
  },
5787
5804
  "name": "color",
5788
5805
  "optional": true,
@@ -5799,7 +5816,7 @@
5799
5816
  "immutable": true,
5800
5817
  "locationInModule": {
5801
5818
  "filename": "src/esbuild-types.ts",
5802
- "line": 68
5819
+ "line": 70
5803
5820
  },
5804
5821
  "name": "define",
5805
5822
  "optional": true,
@@ -5842,7 +5859,7 @@
5842
5859
  "immutable": true,
5843
5860
  "locationInModule": {
5844
5861
  "filename": "src/esbuild-types.ts",
5845
- "line": 250
5862
+ "line": 252
5846
5863
  },
5847
5864
  "name": "footer",
5848
5865
  "optional": true,
@@ -5986,6 +6003,23 @@
5986
6003
  "primitive": "string"
5987
6004
  }
5988
6005
  },
6006
+ {
6007
+ "abstract": true,
6008
+ "docs": {
6009
+ "stability": "stable",
6010
+ "summary": "Documentation: https://esbuild.github.io/api/#jsx-side-effects."
6011
+ },
6012
+ "immutable": true,
6013
+ "locationInModule": {
6014
+ "filename": "src/esbuild-types.ts",
6015
+ "line": 67
6016
+ },
6017
+ "name": "jsxSideEffects",
6018
+ "optional": true,
6019
+ "type": {
6020
+ "primitive": "boolean"
6021
+ }
6022
+ },
5989
6023
  {
5990
6024
  "abstract": true,
5991
6025
  "docs": {
@@ -5995,7 +6029,7 @@
5995
6029
  "immutable": true,
5996
6030
  "locationInModule": {
5997
6031
  "filename": "src/esbuild-types.ts",
5998
- "line": 72
6032
+ "line": 74
5999
6033
  },
6000
6034
  "name": "keepNames",
6001
6035
  "optional": true,
@@ -6028,7 +6062,7 @@
6028
6062
  "immutable": true,
6029
6063
  "locationInModule": {
6030
6064
  "filename": "src/esbuild-types.ts",
6031
- "line": 248
6065
+ "line": 250
6032
6066
  },
6033
6067
  "name": "loader",
6034
6068
  "optional": true,
@@ -6045,7 +6079,7 @@
6045
6079
  "immutable": true,
6046
6080
  "locationInModule": {
6047
6081
  "filename": "src/esbuild-types.ts",
6048
- "line": 77
6082
+ "line": 79
6049
6083
  },
6050
6084
  "name": "logLevel",
6051
6085
  "optional": true,
@@ -6062,7 +6096,7 @@
6062
6096
  "immutable": true,
6063
6097
  "locationInModule": {
6064
6098
  "filename": "src/esbuild-types.ts",
6065
- "line": 79
6099
+ "line": 81
6066
6100
  },
6067
6101
  "name": "logLimit",
6068
6102
  "optional": true,
@@ -6079,7 +6113,7 @@
6079
6113
  "immutable": true,
6080
6114
  "locationInModule": {
6081
6115
  "filename": "src/esbuild-types.ts",
6082
- "line": 81
6116
+ "line": 83
6083
6117
  },
6084
6118
  "name": "logOverride",
6085
6119
  "optional": true,
@@ -6251,7 +6285,7 @@
6251
6285
  "immutable": true,
6252
6286
  "locationInModule": {
6253
6287
  "filename": "src/esbuild-types.ts",
6254
- "line": 70
6288
+ "line": 72
6255
6289
  },
6256
6290
  "name": "pure",
6257
6291
  "optional": true,
@@ -6289,7 +6323,7 @@
6289
6323
  "immutable": true,
6290
6324
  "locationInModule": {
6291
6325
  "filename": "src/esbuild-types.ts",
6292
- "line": 247
6326
+ "line": 249
6293
6327
  },
6294
6328
  "name": "sourcefile",
6295
6329
  "optional": true,
@@ -6435,7 +6469,7 @@
6435
6469
  "immutable": true,
6436
6470
  "locationInModule": {
6437
6471
  "filename": "src/esbuild-types.ts",
6438
- "line": 245
6472
+ "line": 247
6439
6473
  },
6440
6474
  "name": "tsconfigRaw",
6441
6475
  "optional": true,
@@ -6562,7 +6596,7 @@
6562
6596
  "kind": "interface",
6563
6597
  "locationInModule": {
6564
6598
  "filename": "src/esbuild-types.ts",
6565
- "line": 598
6599
+ "line": 601
6566
6600
  },
6567
6601
  "name": "TsconfigOptions",
6568
6602
  "properties": [
@@ -6574,7 +6608,7 @@
6574
6608
  "immutable": true,
6575
6609
  "locationInModule": {
6576
6610
  "filename": "src/esbuild-types.ts",
6577
- "line": 599
6611
+ "line": 602
6578
6612
  },
6579
6613
  "name": "compilerOptions",
6580
6614
  "optional": true,
@@ -6966,6 +7000,6 @@
6966
7000
  "symbolId": "src/source:TypeScriptSourceProps"
6967
7001
  }
6968
7002
  },
6969
- "version": "3.11.1",
6970
- "fingerprint": "oJIeTM/sMlbD0OLm8lmgp4pmaRkuVDN76R6mb2VTXkg="
7003
+ "version": "3.11.3",
7004
+ "fingerprint": "3fjQo5UB/UNKkyhQleDc3IVS9g1onERbwATkwddxtxk="
6971
7005
  }
package/CHANGELOG.md CHANGED
@@ -1,4 +1,18 @@
1
1
 
2
+ ### [3.11.2](https://github.com/mrgrain/cdk-esbuild/compare/v3.11.1...v3.11.2) (2022-08-24)
3
+
4
+
5
+ ### Bug Fixes
6
+
7
+ * esbuild discovery can't find module installed in project ([#234](https://github.com/mrgrain/cdk-esbuild/issues/234)) ([58d7604](https://github.com/mrgrain/cdk-esbuild/commit/58d7604096fb4f7f638a873a90a714565a078d69)), closes [#233](https://github.com/mrgrain/cdk-esbuild/issues/233)
8
+
9
+ ### [3.11.1](https://github.com/mrgrain/cdk-esbuild/compare/v3.11.0...v3.11.1) (2022-08-22)
10
+
11
+
12
+ ### Bug Fixes
13
+
14
+ * `TransformOptions.tsconfigRaw` cannot receive an object ([#230](https://github.com/mrgrain/cdk-esbuild/issues/230)) ([1584ece](https://github.com/mrgrain/cdk-esbuild/commit/1584ecedaff5251f183f08aa512151010a54df16))
15
+
2
16
  ## [3.11.0](https://github.com/mrgrain/cdk-esbuild/compare/v3.10.0...v3.11.0) (2022-08-20)
3
17
 
4
18
 
package/lib/asset.js CHANGED
@@ -56,7 +56,7 @@ class EsbuildAsset extends aws_s3_assets_1.Asset {
56
56
  }
57
57
  exports.EsbuildAsset = EsbuildAsset;
58
58
  _a = JSII_RTTI_SYMBOL_1;
59
- EsbuildAsset[_a] = { fqn: "@mrgrain/cdk-esbuild.EsbuildAsset", version: "3.11.1" };
59
+ EsbuildAsset[_a] = { fqn: "@mrgrain/cdk-esbuild.EsbuildAsset", version: "3.11.3" };
60
60
  /**
61
61
  * Bundles the entry points and creates a CDK asset which is uploaded to the bootstrapped CDK S3 bucket during deployment.
62
62
  *
@@ -68,7 +68,7 @@ class JavaScriptAsset extends EsbuildAsset {
68
68
  }
69
69
  exports.JavaScriptAsset = JavaScriptAsset;
70
70
  _b = JSII_RTTI_SYMBOL_1;
71
- JavaScriptAsset[_b] = { fqn: "@mrgrain/cdk-esbuild.JavaScriptAsset", version: "3.11.1" };
71
+ JavaScriptAsset[_b] = { fqn: "@mrgrain/cdk-esbuild.JavaScriptAsset", version: "3.11.3" };
72
72
  /**
73
73
  * Bundles the entry points and creates a CDK asset which is uploaded to the bootstrapped CDK S3 bucket during deployment.
74
74
  *
@@ -80,5 +80,5 @@ class TypeScriptAsset extends EsbuildAsset {
80
80
  }
81
81
  exports.TypeScriptAsset = TypeScriptAsset;
82
82
  _c = JSII_RTTI_SYMBOL_1;
83
- TypeScriptAsset[_c] = { fqn: "@mrgrain/cdk-esbuild.TypeScriptAsset", version: "3.11.1" };
83
+ TypeScriptAsset[_c] = { fqn: "@mrgrain/cdk-esbuild.TypeScriptAsset", version: "3.11.3" };
84
84
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXNzZXQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6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