@awboost/cfntypes 0.69.0 → 0.100.5
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/README.md +4 -14
- package/lib/resources.generated.d.ts +142038 -0
- package/lib/resources.generated.js +3566 -0
- package/package.json +12 -40
package/README.md
CHANGED
@@ -2,22 +2,12 @@
|
|
2
2
|
|
3
3
|
Typescript types for AWS CloudFormation types.
|
4
4
|
|
5
|
-
## Specification Version
|
6
|
-
|
7
|
-
The specification version is available via the `ResourceSpecificationVersion` export and via `awsResourceSpecificationVersion` in `package.json`.
|
8
|
-
|
9
|
-
```typescript
|
10
|
-
import { ResourceSpecificationVersion } from '@awboost/cfntypes';
|
11
|
-
|
12
|
-
console.log(`using version ${ResourceSpecificationVersion}`);
|
13
|
-
```
|
14
|
-
|
15
5
|
## Resource Types
|
16
6
|
|
17
7
|
The resource types are all defined individually as interfaces with predictable names, and also as properties of the `ResourceTypes` interface keyed by the CloudFormation resource type.
|
18
8
|
|
19
9
|
```typescript
|
20
|
-
import { ResourceTypes, ResourceType } from
|
10
|
+
import { ResourceTypes, ResourceType } from "@cfnboost/cfntypes";
|
21
11
|
|
22
12
|
type ApiGatewayProps = ResourceTypes[ResourceType.ApiGatewayRestApi];
|
23
13
|
// also exported as ApiGatewayRestApi
|
@@ -28,12 +18,12 @@ type ApiGatewayProps = ResourceTypes[ResourceType.ApiGatewayRestApi];
|
|
28
18
|
The attribute types are all defined individually as interfaces with predictable names, and also as properties of the `AttributeTypes` interface keyed by the CloudFormation resource type. Note that not all resource types have attributes.
|
29
19
|
|
30
20
|
```typescript
|
31
|
-
import { AttributeTypes, AttributeTypeFor } from
|
21
|
+
import { AttributeTypes, AttributeTypeFor } from "@cfnboost/cfntypes";
|
32
22
|
|
33
|
-
type
|
23
|
+
type ApiGatewayRestApiAttribs = AttributeTypes["AWS::ApiGateway::RestApi"];
|
34
24
|
// also exported as ApiGatewayRestApiAttributes
|
35
25
|
|
36
26
|
// the AttributeTypeFor helper returns `never` for resources
|
37
27
|
// with no attributes defined
|
38
|
-
type NeverAttribs = AttributeTypeFor<
|
28
|
+
type NeverAttribs = AttributeTypeFor<"AWS::ApiGateway::Account">;
|
39
29
|
```
|