Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@gammarers/aws-resource-naming

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gammarers/aws-resource-naming - npm Package Compare versions

Comparing version 0.9.0 to 0.10.0

57

API.md
# API Reference <a name="API Reference" id="api-reference"></a>
## Structs <a name="Structs" id="Structs"></a>
### ResourceAutoNaming <a name="ResourceAutoNaming" id="@gammarers/aws-resource-naming.ResourceAutoNaming"></a>
#### Initializer <a name="Initializer" id="@gammarers/aws-resource-naming.ResourceAutoNaming.Initializer"></a>
```typescript
import { ResourceAutoNaming } from '@gammarers/aws-resource-naming'
const resourceAutoNaming: ResourceAutoNaming = { ... }
```
#### Properties <a name="Properties" id="Properties"></a>
| **Name** | **Type** | **Description** |
| --- | --- | --- |
| <code><a href="#@gammarers/aws-resource-naming.ResourceAutoNaming.property.type">type</a></code> | <code><a href="#@gammarers/aws-resource-naming.ResourceNamingType">ResourceNamingType</a></code> | *No description.* |
---
##### `type`<sup>Required</sup> <a name="type" id="@gammarers/aws-resource-naming.ResourceAutoNaming.property.type"></a>
```typescript
public readonly type: ResourceNamingType;
```
- *Type:* <a href="#@gammarers/aws-resource-naming.ResourceNamingType">ResourceNamingType</a>
---
### ResourceDefaultNaming <a name="ResourceDefaultNaming" id="@gammarers/aws-resource-naming.ResourceDefaultNaming"></a>
#### Initializer <a name="Initializer" id="@gammarers/aws-resource-naming.ResourceDefaultNaming.Initializer"></a>
```typescript
import { ResourceDefaultNaming } from '@gammarers/aws-resource-naming'
const resourceDefaultNaming: ResourceDefaultNaming = { ... }
```
#### Properties <a name="Properties" id="Properties"></a>
| **Name** | **Type** | **Description** |
| --- | --- | --- |
| <code><a href="#@gammarers/aws-resource-naming.ResourceDefaultNaming.property.type">type</a></code> | <code><a href="#@gammarers/aws-resource-naming.ResourceNamingType">ResourceNamingType</a></code> | *No description.* |
---
##### `type`<sup>Required</sup> <a name="type" id="@gammarers/aws-resource-naming.ResourceDefaultNaming.property.type"></a>
```typescript
public readonly type: ResourceNamingType;
```
- *Type:* <a href="#@gammarers/aws-resource-naming.ResourceNamingType">ResourceNamingType</a>
---
## Enums <a name="Enums" id="Enums"></a>

@@ -8,0 +65,0 @@

20

lib/index.d.ts

@@ -7,18 +7,20 @@ import * as crypto from 'crypto';

}
export type ResourceAutoNaming = {
export interface ResourceAutoNaming {
readonly type: ResourceNamingType.AUTO;
};
export type ResourceDefaultNaming = {
}
export interface ResourceDefaultNaming {
readonly type: ResourceNamingType.DEFAULT;
};
}
export declare namespace ResourceNaming {
function createRandomString(value: crypto.BinaryLike, length?: number): string;
function naming(autoNaming: {
[p: string]: string;
}, resourceNaming?: ResourceAutoNaming | ResourceDefaultNaming | {
export function createRandomString(value: crypto.BinaryLike, length?: number): string;
type ResourceNamingOption = ResourceAutoNaming | ResourceDefaultNaming | {
type: ResourceNamingType.CUSTOM;
[key: string]: string;
}): {
};
export function naming(autoNaming: {
[p: string]: string;
}, resourceNaming?: ResourceNamingOption): {
[k: string]: string | undefined;
};
export {};
}

@@ -50,6 +50,2 @@ "use strict";

ResourceNaming.createRandomString = createRandomString;
// const value = getValueByKey(originalObject, key as keyof MyObject);
// function getValueByKey<K extends keyof MyObject>(obj: MyObject, key: K): MyObject[K] {
// return obj[key];
// }
// export type NamingOptions = {

@@ -98,2 +94,2 @@ // naming: ResourceNaming.AutoNaming | ResourceNaming.DefaultNaming | {type: ResourceNaming.NamingType.CUSTOM; names: {[key: string]: string}};

})(ResourceNaming || (exports.ResourceNaming = ResourceNaming = {}));
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsaUNBQWlDO0FBRWpDLFVBQ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XG4gICAgICAgICAgICBjYXNlIFJlc291cmNlTmFtaW5nVHlwZS5DVVNUT006XG4gICAgICAgICAgICAgIC8vIHJldHVybiByZXNvdXJjZU5hbWluZy5bbmFtZSBhcyBrZXlvZiB7W2tleTogc3RyaW5nXTogc3RyaW5nfV07XG4gICAgICAgICAgICAgIC8vIHJldHVybiByZXNvdXJjZU5hbWluZy5uYW1lc1tuYW1lIGFzIGtleW9mIHtba2V5OiBzdHJpbmddOiBzdHJpbmd9XTtcbiAgICAgICAgICAgICAgcmV0dXJuIHJlc291cmNlTmFtaW5nW25hbWUgYXMga2V5b2YgeyBba2V5OiBzdHJpbmddOiBzdHJpbmcgfV07XG4gICAgICAgICAgICBjYXNlIFJlc291cmNlTmFtaW5nVHlwZS5BVVRPOlxuICAgICAgICAgICAgICByZXR1cm4gdmFsdWU7XG4gICAgICAgICAgICBkZWZhdWx0OlxuICAgICAgICAgICAgY2FzZSBSZXNvdXJjZU5hbWluZ1R5cGUuREVGQVVMVDpcbiAgICAgICAgICAgICAgcmV0dXJuIHVuZGVmaW5lZDtcbiAgICAgICAgICB9XG4gICAgICAgICAgLy8gICAgICAgICAgaWYgKFJlc291cmNlTmFtaW5nLmlzTmFtaW5nVHlwZShyZXNvdXJjZU5hbWluZy5uYW1pbmcudHlwZSkpIHtcbiAgICAgICAgICAvLyAgICAgICAgICAgIGlmIChyZXNvdXJjZU5hbWluZy5uYW1pbmcudHlwZSA9PT0gUmVzb3VyY2VOYW1pbmcuTmFtaW5nVHlwZS5ERUZBVUxUKSB7XG4gICAgICAgICAgLy8gICAgICAgICAgICAgIHJldHVybiB2YWx1ZTtcbiAgICAgICAgICAvLyAgICAgICAgICAgIH1cbiAgICAgICAgICAvLyAgICAgICAgICAgIGlmIChyZXNvdXJjZU5hbWluZy5uYW1pbmcudHlwZSA9PT0gUmVzb3VyY2VOYW1pbmcuTmFtaW5nVHlwZS5OTykge1xuICAgICAgICAgIC8vICAgICAgICAgICAgICByZXR1cm4gdW5kZWZp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O1xuICAgICAgICAgICAgY2FzZSBSZXNvdXJjZU5hbWluZ1R5cGUuQVVUTzpcbiAgICAgICAgICAgICAgcmV0dXJuIHZhbHVlO1xuICAgICAgICAgICAgZGVmYXVsdDpcbiAgICAgICAgICAgIGNhc2UgUmVzb3VyY2VOYW1pbmdUeXBlLkRFRkFVTFQ6XG4gICAgICAgICAgICAgIHJldHVybiB1bmRlZmluZWQ7XG4gICAgICAgICAgfVxuICAgICAgICAgIC8vICAgICAgICAgIGlmIChSZXNvdXJjZU5hbWluZy5pc05hbWluZ1R5cGUocmVzb3VyY2VOYW1pbmcubmFtaW5nLnR5cGUpKSB7XG4gICAgICAgICAgLy8gICAgICAgICAgICBpZiAocmVzb3VyY2VOYW1pbmcubmFtaW5nLnR5cGUgPT09IFJlc291cmNlTmFtaW5nLk5hbWluZ1R5cGUuREVGQVVMVCkge1xuICAgICAgICAgIC8vICAgICAgICAgICAgICByZXR1cm4gdmFsdWU7XG4gICAgICAgICAgLy8gICAgICAgICAgICB9XG4gICAgICAgICAgLy8gICAgICAgICAgICBpZiAocmVzb3VyY2VOYW1pbmcubmFtaW5nLnR5cGUgPT09IFJlc291cmNlTmFtaW5nLk5hbWluZ1R5cGUuTk8pIHtcbiAgICAgICAgICAvLyAgICAgICAgICAgICAgcmV0dXJuIHVuZGVmaW5lZDtcbiAgICAgICAgICAvLyAgICAgICAgICAgIH1cbiAgICAgICAgICAvLyAgICAgICAgICAgIHJldHVybiByZXNvdXJjZU5hbWluZy5uYW1pbmcubmFtZXNbbmFtZSBhcyBrZXlvZiB7W2tleTogc3RyaW5nXTogc3RyaW5nfV07XG4gICAgICAgICAgLy8gICAgICAgICAgfVxuICAgICAgICAgIC8vIHJldHVybiByZXNvdXJjZU5hbWluZy5uYW1pbmdbbmFtZSBhcyBrZXlvZiB7W0sgaW4gVF06IHN0cmluZ31dO1xuICAgICAgICAgIC8vIHJldHVybiByZXNvdXJjZU5hbWluZy5uYW1pbmcubmFtZXNbbmFtZSBhcyBrZXlvZiB7W2tleTogc3RyaW5nXTogc3RyaW5nfV07XG5cbiAgICAgICAgICAvLyByZXR1cm4gdW5kZWZpbmVkO1xuICAgICAgICB9KSgpXTtcbiAgICAgIH0pLFxuICAgICk7XG4gIH1cbn1cbiJdfQ==

@@ -69,3 +69,3 @@ {

},
"version": "0.9.0",
"version": "0.10.0",
"jest": {

@@ -72,0 +72,0 @@ "coverageProvider": "v8",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc