HardeepAsrani / my-awesome-plugin

This is an example plugin to create options page in WordPress using components from Gutenberg.
26 stars 13 forks source link

What's the usage of async here for? #3

Closed dingo-d closed 4 years ago

dingo-d commented 4 years ago

Love the tutorial, helped me a lot with building my options pages 😄

I have a question about this:

https://github.com/HardeepAsrani/my-awesome-plugin/blob/5ca04170a9e2cbaf63cc8a846a4f3f2dc181a5b1/src/index.js#L43

I'm not seeing await being used anywhere, and without it I don't think that using async has any effect.

HardeepAsrani commented 4 years ago

Hey @dingo-d! I was using an async call but later changed the code and forgot to remove it. Thanks for pointing it out! Feel free to fix it and send a PR. :)

dingo-d commented 4 years ago

Cool. Great work on the tutorial 🙂