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 JavaScript Unit Testing Behavior Driven Development with Mocha & Chai Writing Our First Test Suite

Anthony c
Anthony c
20,907 Points

What about on the client-side where export/require aren't available?

Do you use a separate test suite for the client-side?

3 Answers

I hear you. Trying to catch up with all the latest frameworks and tools can make one crazy.

I heard that there are dozens of frameworks releasing everyday. Imagine trying to learn all of them...

Here is my advise to you... learn JavaScript. Learn it well enough to be comfortable using it without jQuery. You don't have to be a guru, but get really good at it. For now ignore all the frameworks and just focus on the language. Frameworks come and go and it will be easier to understand a framework if you know JS well enough.

For instance, I was struggling to learn Angular because I didn't understand objects and modular patterns of JS. I decided to focus on learning JS instead. Go to Mozilla Developer Network(MDN) for reference on JS if you get stuck: https://developer.mozilla.org/en-US/docs/Web/JavaScript

But don't pick latest frameworks, pick ones that are well-tested, popular, and often mentioned in job postings (ie AngularJS, EmberJS)

Good luck and happy coding!

Browserify enables you to use 'require' and 'export' in the browser environment by bundling dependencies.

Here is more info on Browserify: http://browserify.org/

Anthony c
Anthony c
20,907 Points

ahh.... I'm hearing that webpack is the future and where one should invest their time (vs. grunt/gulp/browserify)

I'm hardly a javascript developer and I've already got JS fatigue from trying to keep up with the hipster devs.

Tom Geraghty
Tom Geraghty
24,174 Points

We're using NPM packages in this course so we have the Node ecosystem available for running these tests (with require, module.exports, etc. all working because of node).

The battleship JS application we are testing is front end code and will be run in the browser of the client/person accessing our website application.

The client doesn't need our tests for the application to work in their browser. We won't ship those tests with the application at all; they are only for our development process.