Javascript : how to assign object inside another object
===

Below is the function that do some stuff.


    ns.Line2Point = function (params) {
            points = params.points;
    		// code here
    };

In code above, `params object` has another `points object` inside. So, when I want to call `Line2Point` method, I must create a object, and it contain points object. But, I don't know how to in Javascript. I just have some ideas like the code below, but don't know it true or false:

        var params;
        var points;
        // some code to initialize for points object
        params.points = points
        ns.Line2Point(params)

Please teach me this. Thanks :)




