Dialog Component — Angular (5) | Message Model
So up to now, we have the Dialog Component ready to be consumed. As per our previous articles, you might noticed that I like to organise the code to make it as cleared as possible, so for the Message Service we are going to do the same. Let's start to create the Models, which will support the message component and the service.
The MessageTypeEnum is an enumerator that will define the type of the message:
The MessageModel is the one responsible for the Dialog Content. On this example we will only send to the component the property message, but you can extend it to send Title, Buttons and so on…
So let's move to the Message Component on the next article.