Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Richard Nash
Richard Nash
24,862 Points

ECMAScript 6?

Hi Treehouse,

I'm curious to know you fine folks are planning to handle ECMAScript 6 now and into the future. I've come to understand that it is going to address many current javascript issues and I'm reluctant to spend too much time learning the current javascript standard when some of the elements are going to be deprecated in a few years. I suppose it does not matter that much, but I'm simply curious if you are going to address this subject now or in the future and how that will impact us learning the language.

Thank you :-)

Richard Nash XD

4 Answers

Dave McFarland
STAFF
Dave McFarland
Treehouse Teacher

Hi Richard Nash

I don't think we have any immediate plans to add JavaScript pre-processors, or what are also called "transpilers" in that they take one "language" and convert it into JavaScript.

Popular languages include CoffeScript and LiveScript. They are intended to let programmers write more efficiently and include features common to other languages but not JavaScript (at least not yet). CoffeeScript is very popular in the Ruby community.

Traceur is a different beast -- it's intended to let you write Ecmascript 6 NOW. It then translates (or compiles) that ES6 code to ES5. I think they've added it to CodePen so that people can start experimenting with ES6 today.

Some people really love CoffeeScript and some don't. I'm personally not a fan -- it does have many conveniences but I also think it has a different way of thinking about JavaScript than I'm comfortable with. In addition, you basically need to learn yet another syntax for coding. I feel learning JavaScript syntax thoroughly is enough for me, and don't want to spend my time learning another syntax to get the same things done.

What's more -- most JavaScript libraries are written in JavaScript, so working with those libraries and CoffeeScript just involves a lot of mental overhead.

This is certainly MY OPINION, and I'm sure you can find lots of people with different opinions and experience with JS Pre-processors than me.

Richard Nash
Richard Nash
24,862 Points

I appreciate your candor about this subject, as it helps me no end in attempting to wrap my head around all of this programming stuffs... I just stumbled on to Douglas Rockford as well, which has suddenly got me thinking all sorts of other things in all different sorts of directions, which is certainly interesting, to say the least. Anyway, I do appreciate the work that you and the treehouse team are doing, which is helping somebody like myself and many others come to grips with such a vital part of our collective future.

Cheers,

R

Dave McFarland
STAFF
Dave McFarland
Treehouse Teacher

Hi Richard Nash

In my opinion, it's a little early to be diving into ECMAScript 6. There's still a lot of people using browsers that don't even fully support ECMAScript 5 -- Internet Explorer 8, for example.

Support in browsers for ES6 is very limited at this point -- http://kangax.github.io/compat-table/es6/ -- and it'll be a few years before we can freely use ES6 without worrying about compatibility issues.

It's important to note that ES6 is not a brand new language, or a complete re-writing of JavaScript. The basic features of JavaScript remain the same. You still need to know how to create variables, arrays, objects and functions, use conditional statements, and create loops. And the methods for doing this will be the same in ES6.

There are some additional ways to create and use functions -- support for classes and arrow functions, for example -- but even these are controversial in the JavaScript community. For example classes are helpful mostly for those coming from more traditional OOP backgrounds like Java -- if you understand JavaScript's basic prototypical inheritance pattern (which has been around from the beginning) you might not ever use classes.

In addition, many of the new features are for more advanced JavaScript programming. The basics will remain the same and you'll spend your time more wisely making sure you master the basics (and even the not so basics) before jumping into ES6.

We'll be continuing to build out our JavaScript curriculum at Treehouse and adding more advanced JavaScript courses -- however, I think it will be a while before we start teaching the new features in ES6.

Hope that helps.

Richard Nash
Richard Nash
24,862 Points

This totally helps, thank you Dave McFarland :-) Since I'm in learning mode my mind keeps racing at a mile a minute with questions and wild ideas :-)

On another note, I just run across an article this morning as well, which has me thinking even more about the topic of preprocessors, but for javascript:

(http://blog.codepen.io/2014/10/20/write-javascript-ecmascript-edition-6-es6-right-now-codepen-traceur/)

This got me thinking about the whole idea of pre-processing even more. I've really fallen in love with Sass/SCSS recently as I've learned how to use it well and the idea of doing the same thing with javascript seems attractive, but my js knowledge is extremely limited right now, including treehouse (of course, and thank you!), codecademy.com, code.org (learning with blocks), code avengers, MIT open courseware, etc...

Just curious if treehouse ever plans on supporting js pre-processors in workspaces and on a more fundamental level, are they nearly as useful as CSS pre-processors. My thinking is that if Chris Coyier is doing it, then it must be good, but I just don't know that much about it, yet.

So i'm curious to hear your guys opinions on the subject.

And thank you again for taking the time to indulge my curiosities :-)

Richard Nash XD

As you mentioned that your JS knowledge is limited, I'm just going to sneak in a link to some really good JavaScript learning material. It covers both ES5 and ES6 and it's quite possibly the single most thorough overview of the language and how it works (apart from reading the language spec):

You Don't Know JS by Kyle Simpson

The books are available for free on GitHub, but you can also buy them from O'Reilly.

Dave McFarland
Dave McFarland
Treehouse Teacher

I second Dino Paškvan's recommendation of the You Don't Know JS series by Kyle Simpson. They provide an in-depth discussion of how JavaScript works and how you can use it to its best advantage. They aren't beginners books, however -- they're more for the experienced JavaScript programmer (in my opinion).

geoffrey
geoffrey
28,736 Points

I don't know if something is planned but It's indeed interesting, maybe Andrew Chalkley or Jim Hoskins could enlight us on this point.

Richard Nash
Richard Nash
24,862 Points

Adding Dave McFarland as he's doing some of the treehouse course development as well :-)

Eric Bishard
Eric Bishard
3,365 Points

For what it's worth, I am teaching a program that teaches JavaScript from a beginners programming course, where we use JavaScript to teach students programming as a first language (only after learning HTML and CSS first) We then move into JavaScript 101, Intermediate JavaScript and we spend about a month on JavaScript, we then spend a month on jQuery ad then an additional 2 months on Angular and NodeJS. Not once do we bring up ECMA Script 6 unless it is a side discussion after class.

My point here is that while learning JavaScript, there is no reason to learn ECMA Script 6 features as they are a bit more for the advanced programmer that may be thinking of how they are going to eventually support the new features. This is not a disservice to my students because 93.7% of everything we are learning will be transferable to the JavaScript we will be writing as programmers in 5 years from now.

There is a time and place for programmers to start learning ES6 and in my opinion it's well after they have mastered the javaSCript we use today in browsers and even then it will be learning to enhance what you already know.

I do want to give a huge shout out to my favorite learning site on the NET (Treehouse) I learned a lot of my JavaScript here too.