A gamer, designer and builder. I enjoy thinking about how and why we code.
Paid technical writing opportunities, trying out open source libraries/useful dev tools
Heya Jorge! Thanks for the question. Types is a concept in Typescript . In the article, I have shown you different types of Bill data model, so those are types. It doesn't matter what db you are using, but if you're working in a Typescript project, you would be typing all the data models that you have, component props you receive, endpoint requests & responses etc. For the case you mention about MongoDB not having a specific schema, in a Typescript project, it is even more important that you create a type for the document object that you store. There should be a base type, and at most there are other documents that have some extra fields, so for those fields you can mark them as optional in the type. That way you can get autocomplete intellisense & also type checking when you work with these data models, which is not present in plain JavaScript.