Picture of Iris Schaffer

Iris Schaffer

Thoughts of a software engineer / web enthusiast / Austrian abroad

Webpack + Express = Compressed Static Assets

25/10/2017 18:48
JavaScript Webpack Express Gzip Brotli
Using algorithms like gzip or brotli drastically reduces the size of your assets and can improve the load time of your app – in the case of this blog, by 25%. In this post I am going to explain how to add gzip and brotli compression to an existing webpack setup and serve the compressed files using express.

Reducing bundle size of Highlight.js with Webpack 2

12/10/2017 13:50
JavaScript
You are using highlight.js? You noticed that it takes up a huge portion of all your bundle? In this blog post I am going to write about how I brought down the size of this chunk from 750kb and almost 25% of my total bundle size to under 40kb and only about 1.7% by defining which languages should be available to the highlighter.

Optional Chaining in JavaScript

17/09/2017 11:19
JavaScript React
Have you ever found yourself writing a helper function to get properties nested in an object if the object or following properties exist? Something that does something along the lines of const nameError = errors && errors.address && errors.address.name? If so, you will *love* the TC39 proposal for optional chaining in JS. Here is a quick introduction into the operator.

Created by Iris Schaffer with ♥︎ – View Project on GitHub