Data-First development is an idea that I’ve had for a while and it’s the way I approach most development projects these days. I’m sure that you will have done it too, but just never quite thought about it.

The way I see development is to start with the data. At the very beginning of a project it’s important to get the specification right, and as part of that – design the data store and models. That makes sense, but once they are designed they are inherently forgotten about until they need to be changed.

Instead, I propose a simple workflow that at the start of the project admin interfaces to manage the data is the first thing that is built. There are a few reasons.

  1. Any issues with the model definitions can be found and changed incredibly easily early on
  2. Admin interfaces are usually fairly simply in comparison to the main application
  3. After launch there will be no need to manually edit data in the database

And with that, behold stage two!

Now that the model interfaces are pretty close, it’s important to design the application with a close server – client model. Specifically, a data driven one.

What usually happens in most development scenarios is that the server sends back HTML and a bunch of data attributes. Some fancy JavaScript picks up the data attributes and handles the functionality. But when the data changes significantly and the JS code would be ridiculously complex to handle it. A master refresh is performed to reload the entire section which needs updating.

And here’s where the problems start. The fact that we’ve changed just a single element means that the tree-view it’s in needs to be rebuilt. The information slides need to be refreshed and generally these can take a while.

With data-first development this is almost nullified. The idea being that the client side has a basic understanding of how the view is composed and the server sends enough information to be able to manipulate it. So instead of refreshing a section, the JS can manipulate its internal data-store and then update the UI directly.

It’s not easy to implement, and will struggle if it’s an after thought. But generally, I believe, that getting it right first time will save a whole headache of problems.

There are currently no comments.