url-params-appender
A library that builds a URL, adding query parameters
Last updated 11 days ago by jvanhent .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install url-params-appender 
SYNC missed versions from official npm registry.

url-params-appender

Build Status Coverage Status dependencies Status devDependencies Status Known Vulnerabilities

A library that builds a URL, adding query parameters, taking priority params into account. This is for very usefull when you want to rebuild the current URL, but add/replace the 'page' and 'pageSize'

Installation

To install with npm:

npm i url-params-appender --save

Usage

Usage with node:

var buildUrl = require('url-params-appender');

buildUrl('https://go/see', 
    {
        page: 1, 
        bbb: 111,
        ccc: 'val'
    }, 
    {
        page:2,
        pageSize:5
    }
);

// returns https://go/see?page=2&bbb=111&ccc=val&pageSize=5

License

This is licensed under an MIT License. See details

Contribution

If you want to contribute to this project, you can fork the repository and create pull request to have it reviewed by the Sandbox team. Make sure to link the PR to an issue or improvement for tracking purposes.

Contribution Process

Current Tags

  • 1.0.2                                ...           latest (11 days ago)

7 Versions

  • 1.0.2                                ...           11 days ago
  • 1.0.1                                ...           13 days ago
  • 1.0.0                                ...           a month ago
  • 0.2.2                                ...           a month ago
  • 0.2.1                                ...           a month ago
  • 0.2.0                                ...           a month ago
  • 0.1.0                                ...           a month ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 28
Last Day 0
Last Week 0
Last Month 52
Dependencies (0)
None
Dev Dependencies (4)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |