Big update!Announcing Socket for GitHub 1.0. Learn more
Socket
BlogLoveFAQ
Install
Log in

decode-uri-component

Package Overview
Dependencies
0
Maintainers
1
Versions
2
Issues
File Explorer

Advanced tools

decode-uri-component

A better decodeURIComponent

    0.2.0latest

Version published
Maintainers
1
Weekly downloads
22,035,557
decreased by-3.51%

Weekly downloads

Changelog

Source

  • add support for older node versions bb604831536c4aae32b05eca2a2eaf529af8e874
  • add why section 3f86a3e491a23157c26596ead2eb03ead4f04d33

Readme

Source

decode-uri-component

Build Status Coverage Status

A better decodeURIComponent

Why?

  • Decodes + to a space.
  • Converts the BOM to a replacement character .
  • Does not throw with invalid encoded input.
  • Decodes as much of the string as possible.

Install

$ npm install --save decode-uri-component

Usage

const decodeUriComponent = require('decode-uri-component'); decodeUriComponent('%25'); //=> '%' decodeUriComponent('%'); //=> '%' decodeUriComponent('st%C3%A5le'); //=> 'ståle' decodeUriComponent('%st%C3%A5le%'); //=> '%ståle%' decodeUriComponent('%%7Bst%C3%A5le%7D%'); //=> '%{ståle}%' decodeUriComponent('%7B%ab%%7C%de%%7D'); //=> '{%ab%|%de%}' decodeUriComponent('%FE%FF'); //=> '\uFFFD\uFFFD' decodeUriComponent('%C2'); //=> '\uFFFD' decodeUriComponent('%C2%B5'); //=> 'µ'

API

decodeUriComponent(encodedURI)

encodedURI

Type: string

An encoded component of a Uniform Resource Identifier.

License

MIT © Sam Verschueren

Keywords

FAQs

What is decode-uri-component?

A better decodeURIComponent

Is decode-uri-component popular?

The npm package decode-uri-component receives a total of 17,831,581 weekly downloads. As such, decode-uri-component popularity was classified as popular.

Is decode-uri-component well maintained?

We found that decode-uri-component demonstrated a not healthy version release cadence and project activity because the last version was released a year ago.It has 1 open source maintainer collaborating on the project.

Last updated on 28 Jun 2017
Socket

Product

Subscribe to our newsletter

Get open source security insights delivered straight into your inbox. Be the first to learn about new features and product updates.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc