As digital product designers (UX to some, UI to others) our role is to create software experiences that delight and engage users while attempting to solve real-world problems. The manifestation of this exciting work is a few thousand (or million) lines of code. That tight coupling of our design efforts to product development has given rise to the question, "should designers code?".
The simple answer is: YES, but not for the reasons you think.
Arguments against designers writing code often point to design's specific role in the product pipeline (usually the discovery and planning phases). Others say designers need to be free of constraints to foster greater product innovations. And lastly, one of the biggest reasons against designers coding is simply the different skill sets. To be proficient with both design and code in a production setting is completely unrealistic.
Interestingly enough, these are all true statements. They're actually my statements and I stand by them. But I'm not asking "Should the job of a designer include writing code?". I'm asking, should designers who work on software know how to code? The answer is still YES, and here are a few reasons why.
Build smarter interfaces
Atomic Design has been a radical movement in the design community, but the core principles aren't anything new. Developers have been thinking in abstracted, small, reusable components for decades. It's the fuel for the entire micro service architecture movement (which is part of why Brad Frost's principles make so much freaking sense! ). The legwork that comes with writing code inherently inspires you to adopt these concepts (small, robust, reusable parts) which in turn will influence how you go about designing better user interfaces.
Design products, not slide shows
Another win in knowing how to code is the ability to make real things, not slideshows. There is an abundance of tools and magic wands available today that promise to translate your static design to a real product with the push of a button. But the reality is that these are just better slideshows. Knowing how to code means you can actually make something that's real. It can use real data. It can store real information. It can generate real value to someone's life - not just exist as an idea until someone else decides to make it.
It's easy to open Sketch and whip up a few variations of an art board to showcase how a design responds to different screens. But small, medium, large, and XL dimensions overlook the weird midpoints when the resolution isn't quite one or the other. Writing some code in a playground that lets you resize a viewport will show you how silly, or brilliant, that new layout you wanted to try actually is. It can also reveal weak points in your design that developers would be stuck tackling later on (or worse, would get ignored and shipped to the user).
Get better with type
Along the line of skill refinement, coding an app or website will improve your typesetting skills. Firstly, you can play with type in real-time and experience how it renders on different screen sizes, and where your type will break. You can also get a feel for the pain of having to style 15-20 different text-styles with multiple font queries. There are performance hits to every additional resource loaded and understanding this constraint can help you take a more considered approach to type.
Build empathy for developers
One of the best reasons to be a designer who codes is the empathy it builds with development teams. Building your first website or app is no easy feat, and doing so will help you be immeasurably grateful for the work that goes in to developing outstanding digital products. Also, understanding concepts like APIs, service requests, and parsing JSON (for example) empowers better collaboration between design and development - which then fosters better products.
There are tons of other benefits to learning to code beyond what I put here. The real point I'm getting at is software designers should do software, in some capacity. If you look at every other design field you'll see craftsmen (and women) who have a passion for what they do, and a deep understanding of all aspects of the field. Does that mean a fashion designer spins their own fabrics? Does an architect pick up a shovel and dig the foundations? Maybe - maybe not - but I guarantee knowing how to do aspects of the rest of the process absolutely makes them a better designer - so why should software be any different?