RxJS Contributor Days

This week I had the privilege of attending RxJS contributor days. It was a day long event attended by core contributors as well as companies using RxJS like Slack, Google, Facebook and Netflix. While there is going to be an awesome video detailing all the cool stuff...

Debugging JavaScript with the debugger statement

One of the most useful statements in JavaScript is debugger. It invokes any available debugging functionality from your application and has no effect if there is no functionality available. So, for example if you have some JavaScript running and you want to pause...

Testing forms with React and Enzyme

Lately at Brave I’ve been adding unit tests for our React code. For our project we use: Mocha – our test framework Sinon – for spies Assert – for assertions Mockery – for mocks We also use React and ImmutableJS (not related to testing!)...

Sharing Styles with React and Aphrodite

Lately I’ve been using Khan Academy’s Aphrodite in a lot of my projects. React and Aphrodite work very well together! (although React is not a requirement) and makes managing CSS a lot easier! Using React and Aphrodite together makes each component look...

image-set – CSS for retina displays

There are a few different ways to serve higher quality images to screens with retina displays. A new one I just found out about is the CSS image-set function. At the time of this writing, it only works on Chrome and Safari. Image-set Example The CSS looks a little...

How to create React components

There are now three ways to create React components in JavaScript. Let’s take a quick look at each of them and discuss the pros and cons! Create React Components with React.createClass The first way, and the way Facebook still uses is the createClass method. It...

substr vs. substring in JavaScript

The difference between substr vs. substring in JavaScript bites me more often than any other API confusion in the language. The only difference is in the second parameter. Do you know what each of these will return? var word = "The quick brown fox";...

Website speed test tools you should be using

Performance matters. There are a lot of great ways to make sure your website speed is good enough to not have a negative affect on your user base. These are my favorite tools for performing a website speed test. 1. Google Pagespeed Insights I think it’s a pretty...

What’s new in Chrome DevTools 2016

I just finished watching this awesome video from Google I/O in which Paul Irish and Sam Saccone profiled a few websites and talked about some great new Chrome DevTools features that are available now on Chrome Canary. If you want to watch the whole video, check it out...

Techniques to Avoid Live Coding, Part 1

You’re on stage. You’re about to demo your Cool New Thing. Just gotta add a few… lines… of code… and *drumroll* ERROR. Oops, heh… here’s what we did wrong. Just fix this and… *drumroll* … *drumroll* hmm. *drumroll* Looks like the wifi isn’t working… Well trust me, it...