Front to Back
Like most of the other folks at Tivix, I strive for a full-stack attack. My goal for the last several years has been familiarity with, if not expertise in, every component of the technology stack we use, from back end to front end. It’s a difficult goal to reach, especially because the landscape never stops shifting, and there’s always something new to learn. Fortunately for us (and for our clients), everyone at Tivix has at least one area of expertise they can really own.
Most projects require at least a couple developers working together, each in his or her own sphere of proficiency. I’ve been lucky to work on the front end of projects with some great back end developers. People often ask how that actually works. The answer, as usual, is that it really depends on the needs of the project and the preferences of the client. Even the meaning of “front end” and “back end” changes from project to project, and we’re always looking to improve the ways we collaborate.
This can be a great solution when teams or budgets are stretched thin, because only one person works at a time. This is also a flexible method, as it can go in either direction. On a typical Django project, a back-to-front handoff would look like this:
- Developer A writes models, views, and minimal templates. These templates are often just a place to spit out variables and verify that the views are returning the proper context.
- Developer B writes markup for templates incorporating the views, styles everything, and adds interactions.
A front-to-back handoff would look like this:
- Developer A (in this case, the front-end specialist) writes urls and views that mostly return empty contexts. Developer A writes clean, pretty markup, and styles everything, making sure to include a lot of good comments in the code, pointing out where dynamic content needs to be plugged in, and how conditionals and loops in the template should work.
- Developer B writes views and models, and plugs variables into the templates, following the roadmap left by Developer A.
AngularJS apps call for a different approach. Because so much happens in the html files, the division of labor can’t be as clean as it is in a pure Django app. We’ve had success with this approach:
- Developer A, the Angular specialist, writes the views and html using basic out-of-the-box Bootstrap markup and components, and includes inline styles (don’t worry, it’s temporary!) to make the pages function the way they’re supposed to.
- Developer B, the designer type, moves the inline styles into css or LESS files (phew!) and applies the styleguide for the project by overriding and customizing the Bootstrap styles.
Meet in the Middle
Developers A and B can work simultaneously, to improve speed and efficiency, but this requires excellent project management to make sure things don’t crash when front and back meet up. Lucky for us, we have some really great project managers. The team should kick off each sprint together by laying out a plan for who will accomplish what tasks. With good coordination and communication, the front end knows exactly what to expect from the back end, and the integration is as simple as plugging in variables and flipping a switch. And if problems arise, just head to the pair programming station!
Image from amazon.com