Electron: how to configure NodeJS and runtime Chrome flags

Here is how to specify Node and Chrome flags as you would do when working in Chrome or NodeJS.

Read more

Migrating a JavaScript project to TypeScript using webpack

While porting a little project from JavaScript to TypeScript I scratched my head on a lot of small problems. I wrote this article so that you don’t scratch yours 😉

Read more

webaudio: from scriptProcessorNode to the new AudioWorklet API

When it comes to manipulating sound, the webaudio API is really nice and allows any web developer to do almost any audio work.

Read more

Dealing with process signals with Node.js

JavaScript is asynchronous but we sometimes forget that it’s single threaded. This can be a problem when dealing with signals.

Read more

Internet Explorer 5 still lives

There was a time where Chrome didn’t exist and IE was ruling the web world.

Back in this day, it was common for browsers to take liberty and implement some shortcuts.

For example, IE5 automatically defined a global event property that contained the event that was triggered so that when executing event callbacks, the user didn’t have to do anything and so the following code would work.

What you may not know is that this code still works in Chrome 63, some 18 years later!

Internet Explorer is still alive :)

Let’s wish Chrome won’t take that much liberties…

Read more

How to set Content-Type header for specific URIs using Apache RewriteRule

I was working on an HTML 5 application that loads & plays MP4 files and noticed that some older version of Firefox simply refuse to load media files, although their codec is supposed to be supported.

Read more

Webpack: here are a few tricks that can boost your build performance

Webpack is a nice tool but the default configuration can be very slow at generating builds, even for small projects. Fortunately it takes only a few modifications to drastically reduce build times.

Read more

Migrating from Jasmine 1.3 to Jasmine 2.0

If you just started a new JavaScript project with Jasmine, you likely started using Jasmine 2. But if you’re working on an existing project, it’s highly possible you’re using Jasmine 1.3 and maybe want, like me, migrate to Jasmine 2. Here are a few tips how to do it.

Read more

Finding a process using a specific network port with the lsof command

Today I could not launch a node server: the port my app was targeted was already in use. Fortunately Unix comes with very handy command line tools when it comes to finding which processes are using a specific port/address.

Read more

Ping a server from a grunt task

I was working on a small project that sets up a proxy using grunt, and then starts a node server. Problem is that if the proxy wasn’t up and running, grunt would still start the server and any call to the proxy would make the grunt server crash with some unrelated error.

I decided to add a simple task that would ping the proxy server, and simply fail with an explicit error if it wasn’t responding.

Read more