Hacker News new | past | comments | ask | show | jobs | submit login
Learn ECMAScript6 by doing it (es6katas.org)
109 points by shawndumas on June 20, 2015 | hide | past | favorite | 17 comments



This is pretty neat, actually. After doing the findIndex one, I understand how to use it. Cool.

Edit: The Unicode in strings one teaches you both the \uXXXX and \u{xxxxxx} syntaxes, yet the former isn't new.


As someone who has a basic understanding of Java(purely on the client side, haven't done anything with NodeJS), should I continue with refining my knowledge in ES5, or just jump straight into ES6? This site looks really neat, I should add.


Java != JavaScript. While offering some cool new things, ES6 is overall a fairly incremental change. I would concern myself with learning the fundamentals of the language first.


Just wait until Java starts compiling to WebAssembly and skip learning JavaScript altogether.



Sorry, I meant to write Javascript. Now I can't edit my comment...


This is also a decent path to take before fully migrating to Typescript and get type checking :)

Does anyone know if you can use ES6 code side by side with ES5 without any issues?


You will need to use Babel or another processor for the newer syntax and features, which will compile you ES5ish JavaScript that browsers will mostly understand.

Compiling JavaScript is one solution to the problem that you have no control over the client interpreter and the 'version' of your code that it supports. It isn't an ideal solution, but it means we can move the language forward without worrying about breaking everything.


Thanks, I actually found a decent way to work with Webpack and Typescript, still figuring out how to import files/modules and use JS code from TS.


This is great, it reminds me of codingbat for practicing basic python and Java syntax.


Looks like a good idea; pity the fonts and colouring of the page make it unreadable.


Unreadable? It's a high contrast, large letter, semi-geometric slab serif. Not my style per se, but definitely readable.


On my iPad the font looks like I'm seeing double - there are two distinct versions of the text with a gap between the two.


If you are fine with bright text on dark backgrounds, sure.

I'm not. Looking at this for a few minutes will impact my vision and it will most likely also cause severe headaches. Migraine is fun like that.

Anyhow, the tddbin site uses a black on white color scheme. There is no reason for the index site to be inverted.


You should try [this](https://chrome.google.com/webstore/detail/high-contrast/djcf...) if you use Chrome.


I prefer bright text on dark backgrounds, so I set my OS accessibility settings to invert my screen.

Presuming your OS has such features, you might find it helpful to invert the screen when looking at pages with light text/dark background.

(I change my screen to normal for such sites.)

HTH


Only a tiny percentage of websites uses a dark color scheme.

I have a small bookmarklet for nuking colors, which I can run via some shortcut (ShortcutKey2URL).

javascript:for(var e of document.querySelectorAll('*')){e.style.color=window.getDefaultComputedStyle(e).color;e.style.backgroundColor='#fff'}void(0)

Kinda crude but it works well enough.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: