Not sure which repo this is relevant to, so opening here.
For a lot of novice users, the complexities of Cloud Code can be hard to comprehend, often leading to confusion or inefficient cloud code.
It would be good to have a sample cloud code builder, where users can “drop in” what they would like the code to do.
For example:
- Select Type: Cloud Function, Cloud Trigger (explain the differences)
- Select Class / Function Name
- Select options for the cloud trigger (i.e Cloud Validator)
- Drag and drop some simple Parse features, such as ‘Query first Object’, ‘set x to x’ save object with the master key
Output should be something like:
Parse.Cloud.define('myFunction', async ({params: {name}}) => {
const userQuery = new Parse.Query(Parse.User);
userQuery.equalTo('name', name);
const users = await userQuery.find({useMasterKey:true});
// add your code here
}, {
requireUser: true,
fields: ['name']
});