JS OOP编程

 1 var com = {citi: {sao: {}}};
 2 
 3 com.citi.sao.SAOBase = new function() {
 4    this.name = null;
 5    this.age = null;
 6    this.location = null;
 7    this.drive = function() {
 8        // TODO     
 9     };
10    this.comeback = function() {
11        // TODO
12     };
13 };
原文地址:https://www.cnblogs.com/daishuguang/p/4158712.html