- Function Literals
var squares = function(x){ return x*x; }var square = new Function("x", "return x*x;"); - Object Literals
var point = {x:2.3, y:-1.2};?? var point = new Object({x:2.3, y:-1.2}); - Array Literals
var a = [1.2, "Javascript", true, {x:1, y:3}];var a = new Array(1.2, "Javascript", true, {x:1, y:3});
0 Responses to “Javascript Literals”