changeurlarg
v1.0.0
Published
get new url after param of url changed
Downloads
1
Readme
changeurlarg.js
A function to create new url when one parameter of the route is changed.
Usage
let changeUrlArg = requeire('changeurlarg.js');
let url = '/admin/v1/daily_job?name=haha';
let name = '';
changeUrlArg(url,'name',name); // '/admin/v1/daily_job'
API
changeUrlArg(URL:String,attrKey:String,attrVal):String
Return new url which the parameter is changed