Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@walletconnect/utils

Package Overview
Dependencies
Maintainers
1
Versions
661
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@walletconnect/utils - npm Package Compare versions

Comparing version 1.0.0-beta.22 to 1.0.0-beta.23

3

lib/index.d.ts

@@ -30,5 +30,6 @@ /// <reference types="node" />

export declare function uuid(): string;
export declare const toChecksumAddress: (address: string) => string;
export declare const toChecksumAddress: (address: string) => any;
export declare const isValidAddress: (address?: string | undefined) => boolean;
export declare function getMeta(): IClientMeta | null;
export declare function parseQueryString(queryString: string): any;
export declare function parseWalletConnectUri(str: string): IParseURIResult;

@@ -35,0 +36,0 @@ export declare function promisify(originalFn: (...args: any[]) => void, thisArg?: any): (...callArgs: any[]) => Promise<IJsonRpcResponseSuccess | IJsonRpcResponseError>;

{
"name": "@walletconnect/utils",
"version": "1.0.0-beta.22",
"version": "1.0.0-beta.23",
"description": "Utility Library for WalletConnect",

@@ -58,6 +58,6 @@ "scripts": {

"dependencies": {
"@walletconnect/types": "^1.0.0-beta.21",
"ethers": "^4.0.27"
"@walletconnect/types": "^1.0.0-beta.23",
"ethers-utils": "^2.1.11"
},
"gitHead": "165f7993c2acc907c653c02847fb02721052c6e7"
}

@@ -1,2 +0,2 @@

import { utils } from 'ethers'
const utils = require('ethers-utils')

@@ -350,2 +350,23 @@ import {

export function parseQueryString (queryString: string): any {
const result: any = {}
const pairs = (queryString[0] === '?'
? queryString.substr(1)
: queryString
).split('&')
for (let i = 0; i < pairs.length; i++) {
const keyArr: string[] = pairs[i].match(/\w+(?==)/i) || []
const valueArr: string[] = pairs[i].match(/=.+/i) || []
if (keyArr[0]) {
result[decodeURIComponent(keyArr[0])] = decodeURIComponent(
valueArr[0].substr(1)
)
}
}
return result
}
export function parseWalletConnectUri (str: string): IParseURIResult {

@@ -380,20 +401,5 @@ const pathStart: number = str.indexOf(':')

function parseQueryParams (queryString: string): IQueryParamsResult {
const result: any = {}
const result = parseQueryString(queryString)
const pairs = (queryString[0] === '?'
? queryString.substr(1)
: queryString
).split('&')
for (let i = 0; i < pairs.length; i++) {
const keyArr: string[] = pairs[i].match(/\w+(?==)/i) || []
const valueArr: string[] = pairs[i].match(/=.+/i) || []
if (keyArr[0]) {
result[decodeURIComponent(keyArr[0])] = decodeURIComponent(
valueArr[0].substr(1)
)
}
}
const parameters = {
const parameters: IQueryParamsResult = {
key: result.key || '',

@@ -400,0 +406,0 @@ bridge: result.bridge || ''

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc