Skip to content

re-utils/deuri

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

deuri

Encode, decode URI components.

  • Comparable speed to native in valid input cases.
  • 2-3x overall faster than fast-decode-uri-component.
  • Return null instead of throwing errors in invalid input cases.
import { encode, decode, decodeSegment } from 'deuri';

// Encode the full string
// Returns null if invalid
encode(url);

// Decode the full string
// Returns null if invalid
decode(url);

// Decode a substring of the input string
// Returns null if invalid
decodeSegment(url, startIndex, endIndex);

This implementation is an optimized version of fast-decode-uri-component.

About

Fast decode URI component

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •