Taro Logo

Data Model

You can find the full system design doc here - Feel free to use it as a template for when you're designing systems at your job!

The concrete details are covered in the doc linked above, so this summary will focus on the "meta" context behind this part and additional commentary:

  • Always define the data model if applicable. It is the "core operating unit" of your system - Everything revolves around it. That's pretty much what CRUD is: You have some data model and the entire ecosystem revolves around manipulating it properly.
  • Define the table/collection(s):
    • What is its name?
    • What does it represent? If you can include a visual aide on how it's actually rendered for the user, that makes things a lot clearer.
  • Define the fields on your model:
    • What is its name/key?
    • What is its type?
    • Is it required?
    • What does it represent? This should include information on what kind of key it is (e.g. primary key) if applicable.
  • Illustrate the model to make it really clear. JSON is really good at doing this as it's very readable. There are many free incredible JSON formatters online (Alex used them all the time to make project specs).