CS 142 Discussion SessionJavascript
Set up the environment
Install Node.jsDownload and install node.js from Run command:node -vnpm -vShould see version number
Download the Project2 CodeUnzip the directorynpm install
Checking Your Codejshintnpm run jshint
Test Your CodeRun html file on browsernpm test
Starter Code
The Provided Codecs142-test-project2.htmlcs142-test-project2.jsnode_modulespackage.jsonrun-tests-using-node.js
cs142-test-project2.html<head><title>CS 142 Project 2 Test</title><script src="./cs142-make-multi-filter.js"></script><script src="./cs142-template-processor.js"></script><script src="./cs142-test-project2.js"></script></head>
cs142-test-project2.js'use strict';
cs142-test-project2.jsBlock Comments/** This file tests the CS142 Project #2 JavaScript assignment problems. It prints what* it finds to the console log and updates the text being displayed in the window with a* summary of the results.*/Line Comments// We assume these symbols will be globally defined by the user.
cs142-test-project2.jsvar cs142MakeMultiFilter;var Cs142TemplateProcessor;global scopeundefined if they are not defined anywhereif they are defined in the global scope by some other script, they will have those values.
cs142-test-project2.js

You've reached the end of your free preview.
Want to read all 36 pages?
- Fall '09
- html file, Cs142-test-project2.js- Testing p1