Note: The competency table is written in such a way as to make it easy to construct additional examination questions.
- What is the Document Object Model (DOM)?
- Explain the terms DHTML, DOM scripting and Ajax.
- List three implementations of ECMAScript outside of web browsers.
- What is the difference between an interpreted and a compiled programming language?
DOM Scripting best practices (overview)
- Summarize the concepts of “graceful degradation”, “progressive enhancement” and “unobtrusive scripting”.
ECMAScript lexical structure
- In programming, what is a statement?
ECMAScript data types and variables
- What is weak typing?
- Explain why "1" + 1 == 11
- Why is 1 == "1" but not 2 === "2"?
- Summarize the concept of garbage collection
Expressions and Operators
- Explain arity.
- Explain how operator associativity and priority work in ECMAScript.
- Write an if-else statement and make a ternary operator expression with identical functionality.
- What does the operators typeof and instanceof do?
- Why is it troublesome to typecheck an array with typeof?
- Construct an expression using post- and pre- incrementation.
- Define the purpose of the var keyword.
- Define the purpose of a conditional statement.
- Define the purpose of a repeat loop.
- What are exceptions? How do one throw and catch exceptions?
Strings and String Functions
- What is concatenation?
Objects and Arrays
- What are Array and Object literals?
- Explain the difference between dot notation and bracket notation.
- What array-like (i.e. similar to but not being true arrays) objects does ECMAScript and the DOM have?
- What is a function?
- What does the return statement do?
- What is lambda?
- What is a parameter or “argument” and how is it related to a function?
- What is the arguments property of a function? How can it be used?
- What is a closure?
- Explain regular expressions.
The Date Object
- Briefly explain the usage of the Date object
Numbers and the Math object
- How can a value be converted to a number?
- How can a value be checked to see if it is a number?
- How can a number be rounded to a given precision?
- What is the purpose of the Math object?
- Explain iteration, enumeration and recursion.
- What is a Run Time Environment?
- Explain the concept of namespaces and demonstrate some ways of working around the lack of namespaces in ECMAScript 3 and 5th edition
Client side DOM Scripting/Properties and methods of the window Object
- How can one add scripts to an (X)HTML page? Give several examples and discuss their benefits and what ways should be avoided?
- What is the window object.
- List at least 5 commonly used properties or methods of the window object.
- List all major standards that apply to the DOM and the BOM and briefly state what is covered by each standard.
The Document Object Model
- Construct a simple (X)HTML document and graph out the equivalent DOM structure.
- What is a node? What types of nodes are there?
- Define childNodes, firstChild, and lastChild properties.
- What is PCDATA and CDATA?
- What is the Document Element?
- What is capability testing? Why is it important? How is it superior to browser sniffing?
- Write a line of DOM Script that demonstrates how to capability test.
Accessing DOM Elements
- Show how to access elements in the DOM in at least five different ways.
- Compare setting and getting attributes, using DOM Core methods as well as DOM HTML methods.
- What are “collections” in the DOM?
DOM and Class and Style Manipulation
- Why should the document.write() method be avoided?
- When using innerHTML in a pure XHTML page, what limitations apply?
- How can one access the text content of an element?
Manipulating the DOM
- How are elements constructed an added to the DOM using DOM Core methods?
- List and briefly explain at least three good practices to get fast script execution when manipulating the DOM or changing styles dynamically.
- HTML 5 adds a new special attribute intended for storing arbitrary data; what are those attributes and how can they be accessed?
- What are the leading DOM Scripting libraries? In a sentence or two descibe their design principles.
- What are DOM 0 event handlers?
- What are DOM 2 event listeners? What benefits do they have compared to event handlers?
- Internet Explorer up to and (at least) including 8.0 does not support W3C events; what does it have instead?
- Explain event capturing/bubbling.
- Some events are troublesome due to cross browser inconsistencies and bugs. Give an example and explain ways of working around it.
- Explain at least three ways of making sure the DOM is loaded before code is executed.
- The window object has four methods that apply to timed events, what are they and how do you use them?
- List the most commonly used form events (at least 3).
- Explain how to access the value of a radio button based field in a form.
- What is Ajax?
- List some common usability problems caused by badly written Ajax scripts (at least 3).
- What kind of disabilities or technological limitations must a developer of a web site take into consideration?
- What is ARIA? How can ARIA be used to facilitate accessibility on scripted pages?
Common DHTML mistakes and security
- What is Cross Site Scripting?