How to use 'urldecode javascript' in JavaScript

Every line of 'urldecode javascript' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your JavaScript code is secure.

All examples are scanned by Snyk Code

By copying the Snyk Code Snippets you agree to
7export function base64UrlDecode(str: string): Uint8Array {
8 let temp = Base64.decode(this.replace(/-/g, '+').replace(/_/g, '/'));
9 let arr = new Uint8Array(temp.length);
10 for (let i = 0; i < str.length; i++)
11 arr[i] = str.charCodeAt(i);
12 return arr;
13}
10export function base64UrlDecode(str: string): string {
11 return base64Decode(str.replace(/-/g, '+').replace(/_/g, '/'))
12}

Related snippets