Skip to content

Commit

Permalink
feat(use-cases) (#20)
Browse files Browse the repository at this point in the history
* feat(wip-use-cases)

* wip use cases + typo fix

* wip

* wip use cases

* add links to TS source for type information
  • Loading branch information
HugoDF authored Apr 18, 2020
1 parent 48cd8a9 commit 48eb3be
Show file tree
Hide file tree
Showing 2 changed files with 423 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ yarn add buttondown

The following is the minimum needed code to create a new draft email. Use this example, and modify the `to` and `from` variables:

For more complex use cases, please see [USE_CASES.md](https://github.com/sendgrid/sendgrid-nodejs/blob/master/docs/use-cases/README.md#email-use-cases).
For more complex use cases, please see [USE_CASES.md](./USE_CASES.md).

```js
const buttondown = require('buttondown');
Expand All @@ -79,7 +79,7 @@ const draft = {
body: '<strong>and easy to do from Node.js</strong>',
};
//ES6
buttondow.drafts.create(draft)
buttondown.drafts.create(draft)
.then(() => {}, error => {
console.error(error);

Expand All @@ -90,7 +90,7 @@ buttondow.drafts.create(draft)
//ES8
(async () => {
try {
await buttondow.drafts.create(draft);
await buttondown.drafts.create(draft);
} catch (error) {
console.error(error);

Expand Down
Loading

0 comments on commit 48eb3be

Please sign in to comment.