Created
May 2, 2024 22:49
-
-
Save stack72/285d958588ca224f459a1959bf881580 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function main() { | |
const arnProp = new PropBuilder() | |
.setName("ARN") | |
.setKind("string") | |
.setWidget(new PropWidgetDefinitionBuilder().setKind("text") | |
.build()) | |
.build(); | |
const regionProp = new PropBuilder() | |
.setName("Region") | |
.setKind("string") | |
.setValueFrom(new ValueFromBuilder() | |
.setKind("inputSocket") | |
.setSocketName("Region") | |
.build()) | |
.build() | |
const arnOutputSocket = new SocketDefinitionBuilder() | |
.setName("ARN") | |
.setArity("many") | |
.setValueFrom(new ValueFromBuilder() | |
.setKind("prop") | |
.setPropPath(["root", "domain", "ARN"]) | |
.build()) | |
.build(); | |
const regionInputSocket = new SocketDefinitionBuilder() | |
.setName("Region") | |
.setArity("one") | |
.build(); | |
return new AssetBuilder() | |
.addProp(arnProp) | |
.addProp(regionProp) | |
.addOutputSocket(arnOutputSocket) | |
.addInputSocket(regionInputSocket) | |
.build() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment