Skip to content

Commit

Permalink
feat: add new BackgroundHandler type (#364)
Browse files Browse the repository at this point in the history
Fixes netlify/docs#2328

`Promise<void>` is a valid return type for a function.

example:
```
const handler: Handler = async () => {
  return;
}
```

I also added `tsd` to test for the types.
  • Loading branch information
danez authored Oct 5, 2022
1 parent 9f1a7b0 commit b2d112b
Show file tree
Hide file tree
Showing 7 changed files with 552 additions and 1 deletion.
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ module.exports = {
rules: {
'no-magic-numbers': 'off',
'promise/prefer-await-to-callbacks': 'off',
'unicorn/filename-case': 'off',
},
},
],
Expand Down
Loading

0 comments on commit b2d112b

Please sign in to comment.