Skip to content

Instantly share code, notes, and snippets.

@TroySchmidt
Created October 8, 2018 13:51
Show Gist options
  • Select an option

  • Save TroySchmidt/b6abb43d3f908820621c446a10d2fc5e to your computer and use it in GitHub Desktop.

Select an option

Save TroySchmidt/b6abb43d3f908820621c446a10d2fc5e to your computer and use it in GitHub Desktop.
TypeScript file snippets for VS Code
{
"Slice Reducer Function": {
"prefix": "slicereducer",
"body": [
"const ${1:property} = (state = initialState.${1:property}, action: Actions) => {",
" switch (action.type) {",
" default: {",
" return state;",
" }",
" }",
"};"
],
"description": "Creates stub reducer function for individual state property."
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment