@fy-stack/app-construct 0.0.142 → 0.0.144
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/dist/index.d.ts +8 -9
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -15
- package/dist/lib/ecs/apps/image-app-construct.d.ts +17 -0
- package/dist/lib/ecs/apps/image-app-construct.d.ts.map +1 -0
- package/dist/lib/ecs/apps/image-app-construct.js +55 -0
- package/dist/lib/ecs/apps/next-app-router-construct.d.ts +22 -0
- package/dist/lib/ecs/apps/next-app-router-construct.d.ts.map +1 -0
- package/dist/lib/ecs/apps/next-app-router-construct.js +52 -0
- package/dist/lib/ecs/apps/task-construct.d.ts +16 -0
- package/dist/lib/ecs/apps/task-construct.d.ts.map +1 -0
- package/dist/lib/ecs/apps/task-construct.js +101 -0
- package/dist/lib/ecs/ecs-construct.d.ts +10 -0
- package/dist/lib/ecs/ecs-construct.d.ts.map +1 -0
- package/dist/lib/ecs/ecs-construct.js +42 -0
- package/dist/lib/ecs/ecs-server-construct.d.ts +31 -0
- package/dist/lib/ecs/ecs-server-construct.d.ts.map +1 -0
- package/dist/lib/ecs/ecs-server-construct.js +161 -0
- package/dist/lib/ecs/shared/taskDefinitionImage.d.ts +13 -0
- package/dist/lib/ecs/shared/taskDefinitionImage.d.ts.map +1 -0
- package/dist/lib/ecs/shared/taskDefinitionImage.js +27 -0
- package/dist/lib/ecs/shared/util/ecs-api-gateway.d.ts +2 -0
- package/dist/lib/ecs/shared/util/ecs-api-gateway.d.ts.map +1 -0
- package/dist/lib/ecs/shared/util/ecs-api-gateway.js +5 -0
- package/dist/lib/ecs/types.d.ts +89 -0
- package/dist/lib/ecs/types.d.ts.map +1 -0
- package/dist/lib/ecs/types.js +2 -0
- package/dist/lib/lambda/apps/image-app-construct.d.ts +68 -0
- package/dist/lib/lambda/apps/image-app-construct.d.ts.map +1 -0
- package/dist/lib/lambda/apps/image-app-construct.js +92 -0
- package/dist/lib/lambda/apps/next-app-router-construct.d.ts +33 -0
- package/dist/lib/lambda/apps/next-app-router-construct.d.ts.map +1 -0
- package/dist/lib/lambda/apps/next-app-router-construct.js +77 -0
- package/dist/lib/lambda/apps/node-api-construct.d.ts +43 -0
- package/dist/lib/lambda/apps/node-api-construct.d.ts.map +1 -0
- package/dist/lib/lambda/apps/node-api-construct.js +91 -0
- package/dist/lib/lambda/apps/node-app-construct.d.ts +32 -0
- package/dist/lib/lambda/apps/node-app-construct.d.ts.map +1 -0
- package/dist/lib/lambda/apps/node-app-construct.js +73 -0
- package/dist/lib/lambda/lambda-construct.d.ts +7 -0
- package/dist/lib/lambda/lambda-construct.d.ts.map +1 -0
- package/dist/lib/lambda/lambda-construct.js +34 -0
- package/dist/lib/lambda/types.d.ts +32 -0
- package/dist/lib/lambda/types.d.ts.map +1 -0
- package/dist/lib/lambda/types.js +2 -0
- package/dist/lib/lambda/utils/getDefaultLambda.d.ts +8 -0
- package/dist/lib/lambda/utils/getDefaultLambda.d.ts.map +1 -0
- package/dist/lib/lambda/utils/getDefaultLambda.js +11 -0
- package/dist/lib/lambda/utils/lambda-api.d.ts +6 -0
- package/dist/lib/lambda/utils/lambda-api.d.ts.map +1 -0
- package/dist/lib/lambda/utils/lambda-api.js +17 -0
- package/dist/lib/lambda/utils/lambda-attach.d.ts +4 -0
- package/dist/lib/lambda/utils/lambda-attach.d.ts.map +1 -0
- package/dist/lib/lambda/utils/lambda-attach.js +11 -0
- package/dist/lib/lambda/utils/lambda-grant.d.ts +4 -0
- package/dist/lib/lambda/utils/lambda-grant.d.ts.map +1 -0
- package/dist/lib/lambda/utils/lambda-grant.js +8 -0
- package/dist/lib/shared/next-app-router.d.ts +12 -0
- package/dist/lib/shared/next-app-router.d.ts.map +1 -0
- package/dist/lib/shared/next-app-router.js +87 -0
- package/dist/lib/shared/util/params-from-attachable.d.ts +5 -0
- package/dist/lib/shared/util/params-from-attachable.d.ts.map +1 -0
- package/dist/lib/shared/util/params-from-attachable.js +11 -0
- package/dist/lib/shared/util/types.d.ts +25 -0
- package/dist/lib/shared/util/types.d.ts.map +1 -0
- package/dist/lib/shared/util/types.js +20 -0
- package/dist/lib/static/apps/next-pages-export-construct.d.ts +16 -0
- package/dist/lib/static/apps/next-pages-export-construct.d.ts.map +1 -0
- package/dist/lib/static/apps/next-pages-export-construct.js +69 -0
- package/dist/lib/static/apps/static-website-construct.d.ts +16 -0
- package/dist/lib/static/apps/static-website-construct.d.ts.map +1 -0
- package/dist/lib/static/apps/static-website-construct.js +62 -0
- package/dist/lib/static/next-pages-export-construct.d.ts +21 -0
- package/dist/lib/static/next-pages-export-construct.d.ts.map +1 -0
- package/dist/lib/static/next-pages-export-construct.js +78 -0
- package/dist/lib/static/static-construct.d.ts +7 -0
- package/dist/lib/static/static-construct.d.ts.map +1 -0
- package/dist/lib/static/static-construct.js +28 -0
- package/dist/lib/static/static-website-construct.d.ts +21 -0
- package/dist/lib/static/static-website-construct.d.ts.map +1 -0
- package/dist/lib/static/static-website-construct.js +71 -0
- package/dist/lib/static/types.d.ts +16 -0
- package/dist/lib/static/types.d.ts.map +1 -0
- package/dist/lib/static/types.js +2 -0
- package/dist/lib/types.d.ts +9 -0
- package/dist/lib/types.d.ts.map +1 -1
- package/dist/lib/util/params-from-attachable.d.ts +5 -0
- package/dist/lib/util/params-from-attachable.d.ts.map +1 -0
- package/dist/lib/util/params-from-attachable.js +11 -0
- package/dist/lib/util/strip-trailing-slash.d.ts +2 -0
- package/dist/lib/util/strip-trailing-slash.d.ts.map +1 -0
- package/dist/lib/util/strip-trailing-slash.js +6 -0
- package/package.json +3 -3
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Construct } from 'constructs';
|
|
2
|
+
import { AppConstruct, StaticConstructProps } from './types';
|
|
3
|
+
export declare class StaticConstruct extends Construct {
|
|
4
|
+
apps: Record<string, AppConstruct>;
|
|
5
|
+
constructor(scope: Construct, id: string, props: StaticConstructProps);
|
|
6
|
+
}
|
|
7
|
+
//# sourceMappingURL=static-construct.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"static-construct.d.ts","sourceRoot":"","sources":["../../../src/lib/static/static-construct.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAIvC,OAAO,EAAE,YAAY,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAO7D,qBAAa,eAAgB,SAAQ,SAAS;IAC5C,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,CAAM;gBAE5B,KAAK,EAAE,SAAS,EAAE,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,oBAAoB;CAoBtE"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StaticConstruct = void 0;
|
|
4
|
+
const types_1 = require("@fy-stack/types");
|
|
5
|
+
const constructs_1 = require("constructs");
|
|
6
|
+
const next_pages_export_construct_1 = require("./apps/next-pages-export-construct");
|
|
7
|
+
const static_website_construct_1 = require("./apps/static-website-construct");
|
|
8
|
+
const AppBuilds = {
|
|
9
|
+
[types_1.AppType.NEXT_PAGE_EXPORT]: next_pages_export_construct_1.NextPagesExportConstruct,
|
|
10
|
+
[types_1.AppType.STATIC_WEBSITE]: static_website_construct_1.StaticWebsiteConstruct,
|
|
11
|
+
};
|
|
12
|
+
class StaticConstruct extends constructs_1.Construct {
|
|
13
|
+
apps = {};
|
|
14
|
+
constructor(scope, id, props) {
|
|
15
|
+
super(scope, id);
|
|
16
|
+
Object.assign(this.apps, Object.fromEntries(Object.entries(props.apps).map(([key, app]) => {
|
|
17
|
+
const AppTypeConstruct = AppBuilds[app.type];
|
|
18
|
+
return [
|
|
19
|
+
key,
|
|
20
|
+
new AppTypeConstruct(this, `${key}App`, {
|
|
21
|
+
buildParams: AppTypeConstruct.parse(app.buildParams ?? {}),
|
|
22
|
+
...app,
|
|
23
|
+
}),
|
|
24
|
+
];
|
|
25
|
+
})));
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
exports.StaticConstruct = StaticConstruct;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Attachable, Grantable } from '@fy-stack/types';
|
|
2
|
+
import { HttpRouteIntegration } from 'aws-cdk-lib/aws-apigatewayv2';
|
|
3
|
+
import * as cloudfront from 'aws-cdk-lib/aws-cloudfront';
|
|
4
|
+
import { ITopicSubscription } from 'aws-cdk-lib/aws-sns';
|
|
5
|
+
import { Construct } from 'constructs';
|
|
6
|
+
import { z } from 'zod';
|
|
7
|
+
import { AppConstruct, AppProperties } from '../types';
|
|
8
|
+
declare const BuildParamsSchema: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>>;
|
|
9
|
+
export declare class StaticWebsiteConstruct extends Construct implements AppConstruct {
|
|
10
|
+
private readonly static;
|
|
11
|
+
constructor(scope: Construct, id: string, props: AppProperties<z.infer<typeof BuildParamsSchema>>);
|
|
12
|
+
cloudfront(path: string): Record<string, cloudfront.BehaviorOptions>;
|
|
13
|
+
cloudfrontPolicy(distributionId: string): void;
|
|
14
|
+
api(): Record<string, HttpRouteIntegration>;
|
|
15
|
+
attach(attachable: Record<string, Attachable>): void;
|
|
16
|
+
grant(...grants: Grantable[]): void;
|
|
17
|
+
subscription(): ITopicSubscription;
|
|
18
|
+
static parse(params: unknown): {} | undefined;
|
|
19
|
+
}
|
|
20
|
+
export {};
|
|
21
|
+
//# sourceMappingURL=static-website-construct.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"static-website-construct.d.ts","sourceRoot":"","sources":["../../../src/lib/static/static-website-construct.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAExD,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,KAAK,UAAU,MAAM,4BAA4B,CAAC;AAIzD,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AACzD,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEvD,QAAA,MAAM,iBAAiB,+DAA0B,CAAC;AAElD,qBAAa,sBAAuB,SAAQ,SAAU,YAAW,YAAY;IAC3E,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAY;gBAEvB,KAAK,EAAE,SAAS,EAAE,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;IA0BjG,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,eAAe,CAAC;IAmBpE,gBAAgB,CAAC,cAAc,EAAE,MAAM;IAIvC,GAAG,IAAI,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC;IAI3C,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC;IAI7C,KAAK,CAAC,GAAG,MAAM,EAAE,SAAS,EAAE;IAI5B,YAAY,IAAI,kBAAkB;IAIlC,MAAM,CAAC,KAAK,CAAC,MAAM,EAAE,OAAO;CAG7B"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StaticWebsiteConstruct = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const cdk = tslib_1.__importStar(require("aws-cdk-lib"));
|
|
6
|
+
const cloudfront = tslib_1.__importStar(require("aws-cdk-lib/aws-cloudfront"));
|
|
7
|
+
const cloudfrontOrigin = tslib_1.__importStar(require("aws-cdk-lib/aws-cloudfront-origins"));
|
|
8
|
+
const s3 = tslib_1.__importStar(require("aws-cdk-lib/aws-s3"));
|
|
9
|
+
const s3Deploy = tslib_1.__importStar(require("aws-cdk-lib/aws-s3-deployment"));
|
|
10
|
+
const constructs_1 = require("constructs");
|
|
11
|
+
const zod_1 = require("zod");
|
|
12
|
+
const BuildParamsSchema = zod_1.z.object({}).optional();
|
|
13
|
+
class StaticWebsiteConstruct extends constructs_1.Construct {
|
|
14
|
+
static;
|
|
15
|
+
constructor(scope, id, props) {
|
|
16
|
+
super(scope, id);
|
|
17
|
+
this.static = new s3.Bucket(this, `StaticBucket`, {
|
|
18
|
+
removalPolicy: cdk.RemovalPolicy.DESTROY,
|
|
19
|
+
autoDeleteObjects: true,
|
|
20
|
+
blockPublicAccess: s3.BlockPublicAccess.BLOCK_ACLS,
|
|
21
|
+
publicReadAccess: true,
|
|
22
|
+
websiteIndexDocument: 'index.html',
|
|
23
|
+
websiteErrorDocument: 'index.html',
|
|
24
|
+
cors: [
|
|
25
|
+
{
|
|
26
|
+
allowedHeaders: ['*'],
|
|
27
|
+
allowedOrigins: ['*'],
|
|
28
|
+
allowedMethods: [s3.HttpMethods.GET, s3.HttpMethods.HEAD],
|
|
29
|
+
},
|
|
30
|
+
],
|
|
31
|
+
});
|
|
32
|
+
new s3Deploy.BucketDeployment(this, `StaticDeployment`, {
|
|
33
|
+
destinationBucket: this.static,
|
|
34
|
+
sources: [s3Deploy.Source.asset(props.output),],
|
|
35
|
+
retainOnDelete: false,
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
cloudfront(path) {
|
|
39
|
+
const staticOrigin = new cloudfrontOrigin.S3StaticWebsiteOrigin(this.static);
|
|
40
|
+
const staticBehavior = {
|
|
41
|
+
origin: staticOrigin,
|
|
42
|
+
cachePolicy: cloudfront.CachePolicy.CACHING_OPTIMIZED,
|
|
43
|
+
allowedMethods: cloudfront.AllowedMethods.ALLOW_GET_HEAD,
|
|
44
|
+
cachedMethods: cloudfront.CachedMethods.CACHE_GET_HEAD,
|
|
45
|
+
compress: true,
|
|
46
|
+
viewerProtocolPolicy: cloudfront.ViewerProtocolPolicy.REDIRECT_TO_HTTPS,
|
|
47
|
+
};
|
|
48
|
+
return {
|
|
49
|
+
[`${path}/*`]: staticBehavior,
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
cloudfrontPolicy(distributionId) {
|
|
53
|
+
throw new Error(`cloudfrontPolicy not supported for ${this}`);
|
|
54
|
+
}
|
|
55
|
+
api() {
|
|
56
|
+
throw new Error('api not supported for this construct');
|
|
57
|
+
}
|
|
58
|
+
attach(attachable) {
|
|
59
|
+
throw new Error('attach not supported for this construct');
|
|
60
|
+
}
|
|
61
|
+
grant(...grants) {
|
|
62
|
+
throw new Error('grant not supported for this construct');
|
|
63
|
+
}
|
|
64
|
+
subscription() {
|
|
65
|
+
throw new Error(`subscription not supported for ${this}`);
|
|
66
|
+
}
|
|
67
|
+
static parse(params) {
|
|
68
|
+
return BuildParamsSchema.parse(params);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
exports.StaticWebsiteConstruct = StaticWebsiteConstruct;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type ApiResource, AppType, type CDNResource } from '@fy-stack/types';
|
|
2
|
+
export type StaticConstructProps = {
|
|
3
|
+
apps: Record<string, App>;
|
|
4
|
+
};
|
|
5
|
+
export interface AppConstruct extends CDNResource, ApiResource {
|
|
6
|
+
}
|
|
7
|
+
export type App = {
|
|
8
|
+
type: typeof AppType.NEXT_PAGE_EXPORT | typeof AppType.STATIC_WEBSITE;
|
|
9
|
+
output: string;
|
|
10
|
+
buildParams?: Record<string, unknown>;
|
|
11
|
+
};
|
|
12
|
+
export type AppProperties<BuildParams = Record<string, unknown>> = {
|
|
13
|
+
buildParams: BuildParams;
|
|
14
|
+
output: string;
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/static/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,WAAW,EAAE,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAE9E,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAC3B,CAAC;AAEF,MAAM,WAAW,YAAa,SAAQ,WAAW,EAAE,WAAW;CAAG;AAEjE,MAAM,MAAM,GAAG,GAAG;IAChB,IAAI,EAAE,OAAO,OAAO,CAAC,gBAAgB,GAAG,OAAO,OAAO,CAAC,cAAc,CAAC;IACtE,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACvC,CAAC;AAEF,MAAM,MAAM,aAAa,CAAC,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;IACjE,WAAW,EAAE,WAAW,CAAC;IACzB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC"}
|
package/dist/lib/types.d.ts
CHANGED
|
@@ -2,6 +2,15 @@ import type { ApiResource, Attach, CDNResource, EventResource, Grant } from '@fy
|
|
|
2
2
|
import type { IVpc } from 'aws-cdk-lib/aws-ec2';
|
|
3
3
|
import type { Function } from 'aws-cdk-lib/aws-lambda';
|
|
4
4
|
import { Queue } from 'aws-cdk-lib/aws-sqs';
|
|
5
|
+
export type AppAttachment = {
|
|
6
|
+
auth?: boolean;
|
|
7
|
+
storage?: boolean;
|
|
8
|
+
database?: boolean;
|
|
9
|
+
secrets?: boolean;
|
|
10
|
+
queue?: {
|
|
11
|
+
batchSize?: number;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
5
14
|
export type AppProperties<BuildParams = Record<string, unknown>> = {
|
|
6
15
|
queue?: {
|
|
7
16
|
batchSize?: number;
|
package/dist/lib/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/lib/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,WAAW,EAAE,aAAa,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAC9F,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAE5C,MAAM,MAAM,aAAa,CAAC,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;IACjE,KAAK,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/B,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,WAAW,CAAC;IACzB,MAAM,EAAE,MAAM,CAAC;IACf,GAAG,CAAC,EAAE,IAAI,CAAA;CACX,CAAC;AAEF,MAAM,WAAW,YAAa,SAAQ,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,WAAW;IAC1F,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,KAAK,CAAC,EAAE,KAAK,CAAA;CACd"}
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/lib/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,WAAW,EAAE,aAAa,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAC9F,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAE5C,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CAChC,CAAC;AAEF,MAAM,MAAM,aAAa,CAAC,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;IACjE,KAAK,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/B,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,WAAW,CAAC;IACzB,MAAM,EAAE,MAAM,CAAC;IACf,GAAG,CAAC,EAAE,IAAI,CAAA;CACX,CAAC;AAEF,MAAM,WAAW,YAAa,SAAQ,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,WAAW;IAC1F,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,KAAK,CAAC,EAAE,KAAK,CAAA;CACd"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"params-from-attachable.d.ts","sourceRoot":"","sources":["../../../src/lib/util/params-from-attachable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE7C,wBAAgB,oBAAoB,CAAC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC;;IAS1E"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.paramsFromAttachable = paramsFromAttachable;
|
|
4
|
+
function paramsFromAttachable(attachable) {
|
|
5
|
+
return Object.entries(attachable).map(([key, val]) => {
|
|
6
|
+
return Object.fromEntries(Object.entries(val?.attachable() ?? {}).map(([subKey, subVal]) => [
|
|
7
|
+
`${key}_${subKey}`.toUpperCase(),
|
|
8
|
+
subVal,
|
|
9
|
+
]));
|
|
10
|
+
});
|
|
11
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"strip-trailing-slash.d.ts","sourceRoot":"","sources":["../../../src/lib/util/strip-trailing-slash.ts"],"names":[],"mappings":"AAAA,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,UAE9C"}
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fy-stack/app-construct",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.144",
|
|
4
4
|
"repository": "https://github.com/festusyuma/fy-stack",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@fy-stack/types": "0.0.
|
|
6
|
+
"@fy-stack/types": "0.0.144",
|
|
7
7
|
"tslib": "^2.3.0",
|
|
8
8
|
"zod": "^3.24.1"
|
|
9
9
|
},
|
|
10
10
|
"peerDependencies": {
|
|
11
|
-
"aws-cdk-lib": "^2.
|
|
11
|
+
"aws-cdk-lib": "^2.198.0",
|
|
12
12
|
"constructs": "^10.4.2"
|
|
13
13
|
},
|
|
14
14
|
"main": "./dist/index.js",
|