{"size": 1438, "ext": "js", "max_stars_repo_path": "src/js/hrm.js", "max_stars_repo_name": "GengHH/learn", "max_stars_repo_stars_event_min_datetime": "2016-07-04T03:00:58.000Z", "max_stars_repo_stars_event_max_datetime": "2019-11-20T08:11:01.000Z", "max_issues_repo_path": "src/js/hrm.js", "max_issues_repo_name": "GengHH/learn", "max_issues_repo_issues_event_min_datetime": "2016-07-16T12:28:26.000Z", "max_issues_repo_issues_event_max_datetime": "2017-08-07T03:07:48.000Z", "max_forks_repo_path": "src/js/hrm.js", "max_forks_repo_name": "GengHH/learn", "max_forks_repo_forks_event_min_datetime": "2016-07-07T06:02:16.000Z", "max_forks_repo_forks_event_max_datetime": "2022-02-24T01:11:46.000Z"}
{"max_stars_count": 86, "max_issues_count": 4, "max_forks_count": 39, "avg_line_length": 26.6296296296, "max_line_length": 155, "alphanum_fraction": 0.511821975}
function getServer() {
    /// <summary>
    /// get backend server
    /// </summary>
    if (__DEVAPI__ !==''){

        $.ajax({
            url: __DEVAPI__ + 'http://localhost:8888/',
            data: {},
            type: 'get',
            dataType: 'text',
            success: function (text) {
                $("#serverData").html(text);
            }, error: function () {


                var text = '';
                text += '▍if you see that,It means you have some trouble to get data by backend server. <br /> maybe it\'s the reason below:<br /> ';
                text += '1、you should start the nodejs server,cd to \'mockServer\' folder,then \' node server.js\' to start the server. like this:<br /> ';
                text +=' <pre>$ node server.js</pre>'
                text +='then refresh the broswer.<br /><br />';
                text += '2、if first step is no use,may be Port 8888 is occupied! change Port 8888 to another one. then refresh the broswer.';

                $("#serverData").html(text);
            }

        })

    }else {

        var text = 'if you want to test "Hot Module Replacement" with backend server,please make sure to use hrm mode :';
        text +=' <pre>$ npm run dev-hrm</pre>'

        $("#serverData").html(text);
    }

}


function initialize(params) {

    if (__DEV__) {
        console.log(params);
    }

    getServer();
}


module.exports = {

    init: initialize
}
