{
// CloudEvents metadata data goes here
"eventType": "aws.s3.object.created",
"eventID": "C1234-1234-1234",
"eventTime": "2018-05-08T14:48:09.769Z",
"eventTypeVersion": "1.0",
"source": "/cloudevents-bucket",
"extensions": {},
"contentType": "application/json",
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
{ | |
"name": "serverless-project", | |
"version": "0.0.1", | |
"profile": "serverless-0", | |
"location": "https://github.com/...", | |
"author": "", | |
"description": "", | |
"cloudFormation": { | |
"lambdaIamPolicyDocumentStatements": [{}], | |
"resources": {} |
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
// Project | |
let Project = new ServerlessProject(path); | |
Project._path // Private properties use '_' | |
Project.data.name // Public properties at root | |
Project.data.modules.slackbot.functions.functionFolder.functionName = 'newFunction'; | |
Project.get() // Returns clone of unpopulated object | |
Project.getPopulated() // Returns clone of populated object | |
Project.save() // Persists |
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
// In the new ServerlessProviderAws class ----------------------------------- | |
// A class method wraps all aws-sdk requests | |
request(service, method, params, stage, region) { | |
let awsService = new AWS[service](_this.getCredentials(stage, region)); // Easily set stage/region-specific credentials | |
let req = awsService[method](params); // Form an aws-sdk "request" so we can listen to all AWS SDK events throughout the framework | |
// Listen to any events we want (e.g., VALIDATE_CREDENTIALS) |
Info Experience
info()
is a Component method that returns an javascript object that contains a summary of information about that component that is intended to easily communicate its most important information to humans, while :
const summary = componentInstance.info()
// { name: foo }
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
# Components | |
### Component Strategy | |
* Focus on the use-cases we want to deliver. | |
* Write Components only for those, do not bother with breaking everything into a child Component. | |
* Focus on supporting those use-cases best and providing the best possible customer experience. | |
* Modularity and reusability is not a priority (at this time), only if necessary. | |
### Component & Dashboard Integration |