{"size": 507, "ext": "js", "max_stars_repo_path": "src/HelperString.js", "max_stars_repo_name": "adinan-cenci/http", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/HelperString.js", "max_issues_repo_name": "adinan-cenci/http", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/HelperString.js", "max_forks_repo_name": "adinan-cenci/http", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 21.125, "max_line_length": 50, "alphanum_fraction": 0.5207100592}
class HelperString 
{
    static ltrim(string, char = ' ') 
    {
        var exp = new RegExp('^' + char + '+');
        return string.replace(exp, '');
    }

    static rtrim(string, char = ' ') 
    {
        var exp = new RegExp(char + '+$');
        return string.replace(exp, '');
    }
    
    static trim(string, char = ' ') 
    {
        string = HelperString.ltrim(string, char);
        string = HelperString.rtrim(string, char);
        return string;
    }
}

module.exports = HelperString;
