@mrgrain/cdk-esbuild 3.3.0 → 3.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gitattributes +1 -1
- package/.jsii +608 -324
- package/.projenrc.ts +21 -26
- package/API.md +483 -202
- package/CHANGELOG.md +380 -0
- package/README.md +35 -23
- package/lib/asset.d.ts +6 -4
- package/lib/asset.js +17 -13
- package/lib/bundler.d.ts +29 -5
- package/lib/bundler.js +51 -13
- package/lib/code.d.ts +37 -22
- package/lib/code.js +49 -20
- package/lib/esbuild-types.d.ts +16 -1
- package/lib/esbuild-types.js +1 -1
- package/lib/index.d.ts +4 -4
- package/lib/index.js +3 -1
- package/lib/inline-code.js +4 -4
- package/lib/source.js +2 -2
- package/package.json +20 -18
- package/projenrc/TypeScriptSourceFile.ts +0 -50
- package/releasetag.txt +0 -1
- package/version.txt +0 -1
package/.projenrc.ts
CHANGED
|
@@ -2,10 +2,11 @@ import {
|
|
|
2
2
|
awscdk,
|
|
3
3
|
javascript,
|
|
4
4
|
JsonFile,
|
|
5
|
-
release,
|
|
6
5
|
vscode,
|
|
7
6
|
} from 'projen';
|
|
7
|
+
import { ReleaseTrigger } from 'projen/lib/release';
|
|
8
8
|
import { SourceFile } from 'ts-morph';
|
|
9
|
+
import { tagOnNpm } from './projenrc/release';
|
|
9
10
|
import { TypeScriptSourceFile } from './projenrc/TypeScriptSourceFile';
|
|
10
11
|
|
|
11
12
|
const project = new awscdk.AwsCdkConstructLibrary({
|
|
@@ -19,7 +20,7 @@ const project = new awscdk.AwsCdkConstructLibrary({
|
|
|
19
20
|
|
|
20
21
|
// Project info
|
|
21
22
|
name: '@mrgrain/cdk-esbuild',
|
|
22
|
-
repositoryUrl: '
|
|
23
|
+
repositoryUrl: 'https://github.com/mrgrain/cdk-esbuild',
|
|
23
24
|
description:
|
|
24
25
|
'CDK constructs for esbuild, an extremely fast JavaScript bundler',
|
|
25
26
|
homepage: 'https://github.com/mrgrain/cdk-esbuild',
|
|
@@ -55,25 +56,15 @@ const project = new awscdk.AwsCdkConstructLibrary({
|
|
|
55
56
|
coveragePathIgnorePatterns: ['/node_modules/', '/examples/'],
|
|
56
57
|
},
|
|
57
58
|
},
|
|
58
|
-
eslintOptions: {
|
|
59
|
-
lintProjenRc: false,
|
|
60
|
-
dirs: ['src', 'projenrc', '.projenrc.ts'],
|
|
61
|
-
ignorePatterns: [
|
|
62
|
-
'*.js',
|
|
63
|
-
'*.d.ts',
|
|
64
|
-
'node_modules/',
|
|
65
|
-
'*.generated.ts',
|
|
66
|
-
'coverage',
|
|
67
|
-
'examples/',
|
|
68
|
-
],
|
|
69
|
-
},
|
|
70
59
|
|
|
71
60
|
// Release
|
|
72
61
|
packageManager: javascript.NodePackageManager.NPM,
|
|
73
62
|
npmDistTag: 'latest',
|
|
74
63
|
defaultReleaseBranch: 'main',
|
|
75
64
|
majorVersion: 3,
|
|
76
|
-
releaseTrigger:
|
|
65
|
+
releaseTrigger: {
|
|
66
|
+
isContinuous: false,
|
|
67
|
+
} as ReleaseTrigger,
|
|
77
68
|
catalog: {
|
|
78
69
|
twitter: '@mrgrain',
|
|
79
70
|
},
|
|
@@ -85,14 +76,9 @@ const project = new awscdk.AwsCdkConstructLibrary({
|
|
|
85
76
|
|
|
86
77
|
// Dependencies
|
|
87
78
|
cdkVersion: '2.0.0',
|
|
88
|
-
peerDeps: [
|
|
89
|
-
'aws-cdk-lib@^2.0.0',
|
|
90
|
-
],
|
|
91
79
|
devDeps: [
|
|
92
|
-
'@aws-cdk/aws-synthetics-alpha',
|
|
80
|
+
'@aws-cdk/aws-synthetics-alpha@2.0.0-alpha.11',
|
|
93
81
|
'@types/eslint',
|
|
94
|
-
'aws-cdk-lib@2.0.0',
|
|
95
|
-
'constructs@10.0.5',
|
|
96
82
|
'esbuild@^0.14.0',
|
|
97
83
|
'jest-mock',
|
|
98
84
|
'ts-morph',
|
|
@@ -106,7 +92,6 @@ const project = new awscdk.AwsCdkConstructLibrary({
|
|
|
106
92
|
'cdk.out',
|
|
107
93
|
'.cdk.staging',
|
|
108
94
|
'examples/template',
|
|
109
|
-
'!/.github/workflows/manual-release.yml',
|
|
110
95
|
'!/examples/**',
|
|
111
96
|
],
|
|
112
97
|
npmignore: [
|
|
@@ -121,9 +106,22 @@ const project = new awscdk.AwsCdkConstructLibrary({
|
|
|
121
106
|
'/examples',
|
|
122
107
|
'PUBLISHING.md',
|
|
123
108
|
'.vscode',
|
|
109
|
+
'projenrc',
|
|
124
110
|
],
|
|
125
111
|
});
|
|
126
112
|
|
|
113
|
+
// release only via manual trigger
|
|
114
|
+
project.tryFindObjectFile('.github/workflows/release.yml')?.addToArray(
|
|
115
|
+
'jobs.release_npm.steps',
|
|
116
|
+
tagOnNpm(project.package.packageName, ['cdk-v2', 'unstable', 'next']),
|
|
117
|
+
);
|
|
118
|
+
|
|
119
|
+
// eslint
|
|
120
|
+
project.eslint?.addRules({
|
|
121
|
+
'@typescript-eslint/member-ordering': 'off',
|
|
122
|
+
});
|
|
123
|
+
project.eslint?.addIgnorePattern('examples/');
|
|
124
|
+
|
|
127
125
|
|
|
128
126
|
// VSCode config
|
|
129
127
|
new JsonFile(project, '.vscode/extensions.json', {
|
|
@@ -167,10 +165,6 @@ project.tryFindObjectFile('package.json')?.addOverride('optionalDependencies', {
|
|
|
167
165
|
esbuild: '^0.14.0',
|
|
168
166
|
});
|
|
169
167
|
|
|
170
|
-
project.eslint?.addRules({
|
|
171
|
-
'@typescript-eslint/member-ordering': 'off',
|
|
172
|
-
});
|
|
173
|
-
|
|
174
168
|
new TypeScriptSourceFile(project, 'src/esbuild-types.ts', {
|
|
175
169
|
source: 'node_modules/esbuild/lib/main.d.ts',
|
|
176
170
|
editGitignore: false,
|
|
@@ -191,6 +185,7 @@ new TypeScriptSourceFile(project, 'src/esbuild-types.ts', {
|
|
|
191
185
|
esbuildTypes.getInterface('CommonOptions')?.getProperty('mangleProps')?.setType('any');
|
|
192
186
|
esbuildTypes.getInterface('CommonOptions')?.getProperty('reserveProps')?.setType('any');
|
|
193
187
|
esbuildTypes.getInterface('TransformOptions')?.getProperty('tsconfigRaw')?.setType('string');
|
|
188
|
+
esbuildTypes.getInterface('InitializeOptions')?.getProperty('wasmModule')?.setType('any');
|
|
194
189
|
},
|
|
195
190
|
});
|
|
196
191
|
|