JavaScript is a ubiquitous programming language on the web. It powers animations, audio/video, geolocation, data visualization, peer-to-peer communication, web storage, and, most recently, servers. Facebook, Twitter, Gmail, and Dropbox, to name a few popular websites, all use JavaScript heavily. In fact, Dropbox explicitly requires "Mastery of javascript" for one of their software engineer positions.
It's clear that JavaScript has real-world applications, and that's exactly what this course focuses on. Each of the projects and in-class activities is based on some existing product. After finishing this course, students will have implemented their own versions of Instagram, Piazza, and Yelp, among other sites. Indeed, this course is focused on pragmatic, applicable knowledge.
Application | The course is limited to 40 students, who will be selected by application. The application is available at https://goo.gl/forms/0pXFAgQDjngOn1Wv1 . The deadline for submission is 1/13/2018 (Saturday) at 11:59PM. Class will still be held during the first week (1/8/18 - 1/12/18). If your enrollment deadline is earlier than January 15th, the anticipated admission release date, please contact Vivek at the specified email below. |
Date/Time | Tuesday and Thursday between 9:30 AM and 10:20 AM (50 minutes) |
Location | 380-380W |
Units | 2 Pass/Fail |
Instructors | Vivek Nair (vnair611@gmail.com) |
Staff email | cs42-win1718-staff@lists.stanford.edu |
Office hours | Vivek: 7 PM on Thursdays in Tressider near Subway |
Grading criteria | See lecture 1. |
Late day policy | You have 3 late days, exactly 24 hours each. Additional extensions are only offered in case of documented medical illness and family emergencies. If you exceed your allotted late days, you will receive no credit for that assignment and for the class overall. |
Prerequisites | CS107 (or equivalent experience) |
Explore courses | http://goo.gl/naINjW |
Basic syntactic structure and elements of Javascript: variables, types, conditionals, loops, functions. Brief overview of HTML.
We'll implement a basic version of Instagram together in class! Download the starter files before-hand.
What exactly are callbacks, and why do we use them? What is HTML, and how does it interface with JavaScript?
Traversing the DOM with selectors. Attaching handlers to elements that fire when interesting events occur.
Modifying attributes, inserting/deleting elements, and relative traversal.
Creating a task list using our knowledge of the DOM, events, and callbacks.
For take two, we'll employ templating and event delegation to decompose and simplify our task list implementation.
What happens when you visit a site in your web browser? What is HTTP and what are the various request types? How do you pass parameters in requests?
Making HTTP requests with JavaScript, domain names, and the same origin policy. Extending our Instagram app by pulling photos off Flickr.
Adding realtime commenting to our Instagram app.
Server-side JavaScript with Node.js and Express. Modules, route handling, and static assets.
Searching and playing songs dynamically from Soundcloud.
Integrating MongoDB, a NoSQL document database, into Node.js applications for persistence.
Shorten me maybe? Creating your own URL shortener, like bit.ly.
New operator, constructors, this keyword, and prototype chains.
New operator, constructors, this keyword, and prototype chains.
Using objects and inheritance to implement the classic game of snake.
Interview questions, funny videos, and next steps. Good luck with finals!