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

@0xsequence/utils

Package Overview
Dependencies
Maintainers
4
Versions
496
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@0xsequence/utils - npm Package Compare versions

Comparing version 0.21.2 to 0.21.3

6

CHANGELOG.md
# @0xsequence/utils
## 0.21.3
### Patch Changes
- add window session cache
## 0.21.2

@@ -4,0 +10,0 @@

2

dist/declarations/src/base64.d.ts
export declare const base64Encode: (val: string) => string;
export declare const base64EncodeObject: (obj: any) => string;
export declare const base64Decode: (encodedString: string) => string | undefined;
export declare const base64DecodeObject: <T = any>(encodedObject: string) => T | undefined;
export declare const base64DecodeObject: <T = any>(encodedObject: string | null) => T | undefined;

@@ -1,3 +0,3 @@

export declare const sanitizeNumberString: (numString: string) => string;
export declare const sanitizeNumberString: (numString: string | null) => string;
export declare const sanitizeAlphanumeric: (alphanum: string) => string;
export declare const sanitizeHost: (host: string) => string;
{
"name": "@0xsequence/utils",
"version": "0.21.2",
"version": "0.21.3",
"description": "utils sub-package for Sequence",

@@ -5,0 +5,0 @@ "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/utils",

@@ -18,3 +18,3 @@ import { Base64 } from 'js-base64'

export const base64DecodeObject = <T = any>(encodedObject: string): T | undefined => {
export const base64DecodeObject = <T = any>(encodedObject: string | null): T | undefined => {
if (encodedObject === null || encodedObject === undefined) {

@@ -21,0 +21,0 @@ return undefined

// sanitizeNumberString accepts a number string and returns back a clean number string.
// For example, input '1234.5678' will return '1234.5678' but '12javascript:{}etc' will return '12'
export const sanitizeNumberString = (numString: string): string => {
export const sanitizeNumberString = (numString: string | null): string => {
if (!numString || typeof(numString) !== 'string') {

@@ -6,0 +6,0 @@ return ''

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