Skip to content

Instantly share code, notes, and snippets.

@jmarnold
Created May 27, 2015 18:05
Show Gist options
  • Save jmarnold/061cff2d70687ede5214 to your computer and use it in GitHub Desktop.
Save jmarnold/061cff2d70687ede5214 to your computer and use it in GitHub Desktop.
projection example
module.exports = {
matches: function(evt) {
return evt.type === 'workspace:updated';
},
dependencies: function(evt) {
return {
workspace: evt.data.workspaceId
};
},
execute: function(evt, context) {
var workspace = context.workspace;
workspace[evt.data.property] = evt.data.value;
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment