Options
All
  • Public
  • Public/Protected
  • All
Menu

query-stringifier

Index

Interfaces

Functions

Functions

Const extract

  • extract(url: string): string
  • Extract the query string sentence from any url. If there is no query string, empty string should be returned.

    Parameters

    • url: string

      url which contains

    Returns string

    Extracted query string from url

Const parse

  • parse(queryStr: string): object
  • Add the query stringify method

    Parameters

    • queryStr: string

      The query string to parse into an object. If any type other than string, just returns it

    Returns object

    Returns query-string as object

Const stringify

  • stringify(params: object, options?: options): string
  • Add the query stringify method

    Parameters

    • params: object

      Parameters to be built into a query string

    • Default value options: options = {prefix: ''}

      Optional settings

    Returns string

    Returns query-stringified object

Generated using TypeDoc