'WTF is JavaScript? Context for a green dev.'
###TL;DR: An attempt at providing the context for JavaScript, as opposed to teaching it directly, as there are plenty of tools for that. My intended audience is those wanting to commit to learning to code, but who so far have minimal (less than a year) of actual dev experience. Any feedback would be massively appreciated!
##Context
When people ask what JavaScript is, I usually say it’s the thing that makes websites interactive.
In a website context, there are essentially 3 ‘languages’ that make the website happen: HTML, CSS, and JavaScript. Elsewhere I cover this topic more in-depth, but the quick-and-dirty is that HTML is the website’s content (text and buttons, etc), the CSS styles it, and the JavaScript performs any action associated with it.
That means, when you click a button to submit your login information, front-end JavaScript code takes that username and password, and sends it off to a server (read: computer) somewhere to be checked against whatever you told that server your password was when you first signed up.
That server (aka computer) that’s waiting for your password? That could be running JavaScript too, or any other language. Javascript can be used as a backend language through frameworks like NodeJS.
JavaScript is special because every modern Browser runs it (along with HTML and CSS) to render websites. That adoption by Google (Chrome), Mozilla (Firefox), Apple (Safari), Microsoft (Internet Explorer), and others has created the modern web, and led to an exploding community of JavaScript developers.
The JavaScript community is anyone who writes JavaScript. Welcome! Developers use it to build businesses, personal websites, blogs, games, and of course, tools to make writing code easier.
TODO: links in here
##A brief origin story
TODO: write.
##JavaScript is a programming language
New developers often ask what language they should learn first. If pressed, I always recommend JavaScript.
Not necessarily the right choice for everyone. The right choice is really the one that you are most interested in - as much as you can energize yourselve to work hard on something, to keep pushing it all the way through: finishing a project is the best thing for you.
Reasons I recommend JavaScript:
- **Wide applicability**: JavaScript can be used to accomplish most of thethings you'll want to build, whether it's mobile apps, websites, games, robots, etc.(Side effect: many businesses run on JavaScript - you can build a career on it!)- **Low(er) barrier to entry**: JavaScript is a [dynamically typed]() and [interpreted/scripted]()language. The links are to wtf those things mean, but don't worry about themfor now: these are just facts about JavaScript, that make things a bit simplerto work with when you're getting started.- **Tons of (free!) resources** via a **HUGE community**, which allows you to learn "onyour own" AND find help online if you need it. Both of which are key to being [very dev-resourceful]()Let’s get into these a bit more and learn a little about what JavaScript is.
###JavaScript is everywhere
Every browser - it won the battle - if it can, it will Backend and NodeJS?
###Is JavaScript easier to learn?
Languages are trending strongly toward ease-of-use, which makes this argument trickier now than it used to be. Couple that with the complexity of the current state of a fully-fledged JavaScript app, and this argument can go either way.
To counter the use of the language itself - running JavaScript on your own computer requires nothing more than the browser you are reading this blog post in. In fact, you can open the Developer Tools of your browser right now and write some JavaScript right there if you want to. So that feels like a pretty low barrier to entry.
TODO: code examples for getting started, runnable in the browser!
###Resources and Community
TODO: source
##Things not to be afraid of
When you get out there in the real JavaScript world, you’re gonna see just how full of it I am, presenting JS all hunky-dory in this crappy little world, telling you it’s all fun and games.
You’re going to find out that JavaScript is a state of ridiculous fragmentation, that it’s actually more or less a complied language depending on which ‘future’ (ECMA) version you want (the latest, I promise), that tools called ‘Babel’ are trying to help but that we really don’t need them now that NodeJS has sort of gotten it’s act back together.
On top of that, once you move on to some other languages (stronger types anyone? Or how about a paradigm shift?), you’ll learn just how much JavaScript left you hanging all those times.
All of that might be gibberish to you, and don’t worry! Things are always getting better, and this stuff only starts to make sense once you start exposing yourself to it.
The JavaScript world changes so fast that you just need to hop on and ride for a
few months to suddenly find yourself several tech abstractions ahead of any projects that were running
full-steam when you console.log()ed your first Hello World?.
So when you’re out there, you’re gonna see a ton of key words. Don’t be afraid! Make note of them, google them if you’re curious, and don’t be overwhelmed. I’ll try to cover some of them here, and if you find any wtfs in your travels, ping me with them and I’ll see if we can’t wrap them into a little Tl;dr for the next traveler.
-
JSON: stands for JavaScript Object Notation, and it is a data format. I wrote a full post covering an intro to JSON, but the gist is that when you see JSON, you’re talking about raw data formatted with a subset of JavaScript’s syntax.
-
Node.JS:
-
AngularJS:
-
ReactJS:
-
Tooling!: Babel, Gulp, Grunt, etc.
-
TODO: more here.
TODO: conclude.
###TODOs
TODO: write dynamically typed, interpreted/scripted posts TODO: write Context post (as opposed to learning directly) TODO: fill plenty-of-tools link (another post?) TODO: write very-dev-resourcesful post TODO: write intro to json post TODO: links to stronger types, paradigm shifting languages TODO: write and link Dev Tools post