April 19, 2017
Simon over at simonsmith.io answers a common question on how best to organize Webpack config files, especially when it comes to different environments. In his post, Simon shares a pattern that works well and allows scaling to as many environments as needed.
Now that Pouchdb-find has been merged in, Will Holley updated replication and changes so that it is now possible to create a filtered replication using the PouchDB-find selectors and use it in the changes feed. (PouchDB Blog, April 20, 2017)
After a few years of seeing generators in the wild and using them in my code, Derek Bailey answers the big question. Do you need to learn generators?
Streaming fetches are supported in Chrome, Edge, and Safari. Take a quick sprint through the API with Jake Archibald.
When unit testing real-world code, there are many situations that make tests hard to write. How do you check if a function was called? How do you test an Ajax call? Or code using setTimeout? Jani Hartikainen explains that’s when you use test doubles — replacement code that makes hard to test things easy to test.
Donald Pipowitch talks about frontend tooling. Some History, The Maybe Future, Linters, Compiler Plugins and Macros, Loaders. Can we bring the different worlds of loaders, type systems, syntax extensions and pretty printers more closely to each other by finding the right low level APIs in the future?
Techshard demonstrates Object.seal() and Object.freeze(). Object.seal() prevents new properties while existing properties can still be changed if they are writable. Object.freeze() can be useful for representing a logically immutable data structure, especially if changing the properties of the object could lead to bad behavior elsewhere in your application.
Pony Foo's Nicolás Bevacqua looks at regular expressions in and after ES6. There’s a couple of regular expressions flags which were introduced in ES6: the /y or sticky flag, and the /u or Unicode flag. Nicolás discuss five proposals which are making their way through the ECMAScript specification development process at TC39.