typed-serverless
Version:
Helps you write a consistent Serverless Framework configuration in TypeScript
58 lines (57 loc) • 1.97 kB
TypeScript
import { ResourceBuilder, ResourceProps, ResourceType } from './types';
export declare class ServerlessResourcePlaceholder<TResourceId, TResourceParams, TResourceProps extends ResourceProps> {
readonly id: TResourceId;
readonly type: ResourceType;
readonly builder: ResourceBuilder<TResourceParams, TResourceProps>;
constructor(id: TResourceId, type: ResourceType, builder: ResourceBuilder<TResourceParams, TResourceProps>);
}
export declare class CfRef<TResourceId> {
readonly id: TResourceId;
constructor(id: TResourceId);
}
export declare class CfRefAtt<TResourceId> extends CfRef<TResourceId> {
readonly id: TResourceId;
readonly attribute: string;
constructor(id: TResourceId, attribute: string);
}
export declare class GetResourceName<TResourceId> {
readonly id: TResourceId;
constructor(id: TResourceId);
}
export declare class GetResourceLogicalId<TResourceId> {
readonly id: TResourceId;
constructor(id: TResourceId);
}
export declare class CfStringify {
readonly content: unknown;
constructor(content: unknown);
}
/**
* @link https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
* Valid formats:
* - 'arn:partition:service:region:account-id:resource-id'
* - 'arn:partition:service:region:account-id:resource-type/resource-id'
* - 'arn:partition:service:region:account-id:resource-type:resource-id'
*/
export declare class BuildArn<TResourceId> {
readonly params: {
partition?: string;
service?: string;
region?: string;
namespace?: string;
type?: string;
resourceId: TResourceId;
path?: string;
typeToResourceSeparator?: ':' | '/';
};
constructor(params: {
partition?: string;
service?: string;
region?: string;
namespace?: string;
type?: string;
resourceId: TResourceId;
path?: string;
typeToResourceSeparator?: ':' | '/';
});
}