url-trim
Trims query and hash parameters off of a URL.
Install
npm install url-trim --save
Example
var urlTrim = //=> 'http://localhost:9966/' //=> '/path/foo'
Usage
trimmed = trim([url])
Trims the query string and hash parameters from a URL.
If url
is empty or not a string, this method returns an empty string.
License
MIT, see LICENSE.md for details.