johnlindquist.com

Build a Lens From Scratch

January 16, 2019

Build a Lens from Scratch Let's take a backwards approach to dive into lenses by starting with our final implementation. What you see below is what we want our api to look like. We want prop to be a lens which can focus on a property and we want view to use the lens to focus onto the person…

Continue reading...

Focused - Putting Proxies to Work

January 11, 2019

Focused With the power of our new proxy knowledge in hand, let’s turn to a library that leverages proxies behind the scenes. Focused is a library that uses similar techniques to get properties using proxies which allows us to do somewhat magical operations on deeply nested state. It’s worth noting…

Continue reading...

Safely Get Nested Values with Proxies

January 10, 2019

Safely Get Nested Values with Proxies We've all been in the situation where we are trying to access a very deeply nested property inside of an object but it errors out because one of those properties you're trying to access is undefined. Strings to the Rescue! Many of us turn to a tool called lodash…

Continue reading...

Use Reflect APIs with Proxy Handlers

January 08, 2019

Use Reflect apis with Proxy Handlers You'll notice something strange when you compare the Reflect API and the handler API for Proxies: Reflect API handler API Reflect.apply() handler.apply() Reflect.construct() handler.construct() Reflect.defineProperty() handler.defineProperty() Reflect…

Continue reading...

Your First JavaScript Proxy

January 06, 2019

Your First JavaScript Proxy A Proxy is a fancy word for intercepting how you interact with objects in JavaScript. Want to hi-jack what happens when you set a value? Care to log out every time you call a function? All this and much more can be done by wrapping your object in a Proxy and "handling…

Continue reading...

2017 Favorite Things

December 27, 2017

Frontend Development Vue/React/Angular I spent about 50% of my time with Vue, 50% with React, and ~0% with Angular. I still have no idea which one I like the most, but if you tell me a scenario, I have a good feeling towards which I would use. I really love Nuxt.js and Next.js and all the…

Continue reading...

2016 Stuff I Did and Didnt Do

January 02, 2017

egghead.io Created a bunch of lessons on egghead.io and helped many new instructors get started, but most of the hard work has been done by Joel Hooks . Joel leads our amazing dev and design teams and I’m really looking forward to the improvements we have planned for this year. I’ll soon be…

Continue reading...