Pascal’s Triangle in Javascript 6 (ES6)

So I was reading a post on reddit where it was mentioned that on a interview for javascript developer they asked to write a function that returns n lines of Pascal’s Triangle.

My first reaction was of course: What is a Pascal Triangle? After reading wikipedia I said, ok let’s give it a try. At the end I didn’t make a function, but a whole ES6 class that renders it nicely to the browser.

Check out the codepen:

See the Pen A Pascal Triangle in ES6 by Jean-Pierre Sierens (@jpsierens) on CodePen.

If you want to start using ES6 in your projects, check out this tutorial I wrote.

5 Tools every Javascript Developer should Use

Lately I have been thinking about the tools I use to write Javascript. I think about how much it would suck to develop without them. So I am going to list them in order of importance for me, 1st being the most important. I will try to convince you in the process to at least give them a try.

Continue reading “5 Tools every Javascript Developer should Use”

Free Course: Build Web Apps with React JS and Flux

The guys at udemy were nice enough to hand me 50 coupons for the course: Build Web Apps with React JS and Flux.

With the coupon, the course becomes free of charge!

So naturally I’m giving these to you! If you want to learn how to build web apps with React and Flux there is no better chance than this. This course will get you up and running quickly, and teach you the core knowledge you need to deeply understand and build React components.

Note: All coupons have been used!

You can head over to this post to learn how to set up a project with react.

How to get started with React js in ES6

Note: This post is outdated, here is an updated post

In this post I will give you a simple set up or boilerplate for starting a React project in ES6. This boilerplate is not meant to be used for professional stuff. Use it to get started and then you can structure it in a better way.

If you are just looking to get started up with ES6, you can take a look at my previous post.

Continue reading “How to get started with React js in ES6”

How to Use Javascript 6 (ES6) Right Now Including ‘Import’

Note: This post is outdated because Babel changed the way it works. Please read this updated tutorial to start writing ES6 apps.

So you want to use the new Javascript, most popularily denoted as ES6 (ECMAScript version 6)? Why wouldn’t you, it has all these neat features like actual classes with constructors, arrow functions, blockscoping, etc…

If you’re writing Javascript on the back-end with io.js (Nodejs cooler and younger brother) this is already possible out of the bat. If you want ES6 on the front end though, you will need to use some magic which I will show in this post.

Continue reading “How to Use Javascript 6 (ES6) Right Now Including ‘Import’”