chncrs.js
function(source, fromCRS, toCRS) {
        if (!source) {
            return null;
        }
        if (!fromCRS || !toCRS) {
            throw new Error('must provide a valid fromCRS and toCRS.');
        }
        if (this._isCoord(source)) {
            return this._transformCoordinate(source, fromCRS, toCRS);
        } else if (this._isArray(source)) {
            var result = [];
            for (var i = 0; i < source.length; i++) {
                result.push(this.transform(source[i], fromCRS, toCRS));
            }
            return result;
        }
        return this._transformGeoJSON(source, fromCRS, toCRS);
    }
function(source, fromCRS, toCRS) {
        if (!source) {
            return null;
        }
        if (!fromCRS || !toCRS) {
            throw new Error('must provide a valid fromCRS and toCRS.');
        }
        if (this._isCoord(source)) {
            return this._transformCoordinate(source, fromCRS, toCRS);
        } else if (this._isArray(source)) {
            var result = [];
            for (var i = 0; i < source.length; i++) {
                result.push(this.transform(source[i], fromCRS, toCRS));
            }
            return result;
        }
        return this._transformGeoJSON(source, fromCRS, toCRS);
    }
function ( source , fromCRS , toCRS ) { if ( ! source ) { return null ; } if ( ! fromCRS || ! toCRS ) { throw new Error ( 'must provide a valid fromCRS and toCRS.' ) ; } if ( this . _isCoord ( source ) ) { return this . _transformCoordinate ( source , fromCRS , toCRS ) ; } else if ( this . _isArray ( source ) ) { var result = [ ] ; for ( var i = 0 ; i < source . length ; i ++ ) { result . push ( this . transform ( source [ i ] , fromCRS , toCRS ) ) ; } return result ; } return this . _transformGeoJSON ( source , fromCRS , toCRS ) ; }
transform geojson's coordinates
@param  {Object | Array} source a coordinate [x,y] or a geoJSON object to convert
@param  {String | CRS Object} fromCRS    crs converted from
@param  {String | CRS Object} toCRS      crs converted to
@return {Object} result geoJSON object
transform geojson s coordinates