| difficulty | 1 |
|---|---|
| training | true |
| chapter | Chapter 6: TypeScript |
| tags | vue |
In this challenge, we've created a simple AppAlert component. It takes 2 props: type and dismissable. It also emits an event dismiss.
Your task is to type these props and emits.
- The
typeprop should be one of the following strings: "success", "error", "warning", or "info" - The
typeprop should default to 'info' - The
dismissableprop should be a boolean - The
dismissableprop should default tofalse - The
dismissevent's payload should be the literal typetrue - All TS errors within the
AppAlertcomponent should be resolved
💡 HINT: Play with the usage of the
AppAlertcomponent inApp.vueto see how your IDE's autocomplete is more useful with the typed props and events.


