I have been thinking about web components a lot lately, and I wanted to see how we could start using them at The Container Store. The idea was to pick a simple component and recreate it as a web component, and the first candidate that came to mind is our frequently-used quantity stepper. The stepper appears in several places throughout the website, and it’s dependent on an embarrassing amount of jQuery.
In case you didn’t notice, I just pushed up the biggest adjustment to the site design since the last redesign in late 2020. I wanted to go through it briefly and talk about what’s next.
Update at the end
The gap property was first introduced to add inner grid spacing but was extended in the spec to work with flexbox. With one line of code, you can replace something like this:
Read more
of The curious case of flexbox gap and Safari
→
You don’t need to install a validation library to create rich client-side form validation experiences. HTML5’s native client-side form validation is widely-supported and easy to implement, and while its default functionality is limited, the native Constraint Validation API allows for custom behavior with JavaScript.
Read more
of Native form validation with JavaScript
→
As a developer, I love optimizing performance. Learning efficient algorithms makes me feel like a software engineer. But performance is not the only developer concern, nor should it be the first or second. David K. Piano recently pointed this out on Twitter, offering up a suggested framework:
Read more
of Hold off on optimizing JavaScript performance
→
I recently challenged myself to write a blog post every day for a month. Up to that point, I had only written eight blog posts for two years. A month later, not only do I have 28 new blog posts, I’ve learned some valuable lessons about my blogging process and my website. I wanted to share things about the experience that worked for me and issues I discovered that need attention.
Read more
of What I learned blogging daily for a month
→
Whether you need site breakpoints for matchMedia or access to theme colors, sharing values between your JavaScript and CSS is sometimes unavoidable. The easiest solution is to copy and paste values, but how can you ensure values stay synchronized when that brand blue color changes to indigo?
Read more
of Share variables between JavaScript and CSS
→
I’ve been posting a new article every day this month, and it’s been interesting. I’ll write about that soon, but today I want to share how I put these posts together. Hopefully, you’ll learn something new from my process, or see how terrible my process is and give me some advice.
If a problem is too difficult to solve on our own, sometimes the only course of action is to search, copy, and paste. It’s something all developers have done regardless of their experience level.
Read more
of Understand the context of code you copy
→