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

@pooltogether/utilities

Package Overview
Dependencies
Maintainers
4
Versions
77
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pooltogether/utilities - npm Package Compare versions

Comparing version 0.0.21 to 0.0.22

6

dist/address.d.ts

@@ -8,1 +8,7 @@ /**

export declare const isValidAddress: (address: any) => boolean;
/**
* Shortens a hash into something a little more user friendly
* @param hash
* @returns
*/
export declare const shorten: (hash: any) => string;

19

dist/address.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.isValidAddress = void 0;
exports.shorten = exports.isValidAddress = void 0;
const ethers_1 = require("ethers");

@@ -26,2 +26,17 @@ /**

exports.isValidAddress = isValidAddress;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWRkcmVzcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9hZGRyZXNzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBLG1DQUErQjtBQUUvQjs7Ozs7R0FLRztBQUNJLE1BQU0sY0FBYyxHQUFHLENBQUMsT0FBTyxFQUFFLEVBQUU7SUFDeEMsSUFBSSxDQUFDLE9BQU87UUFBRSxPQUFNO0lBRXBCLElBQUk7UUFDRixlQUFNLENBQUMsS0FBSyxDQUFDLFVBQVUsQ0FBQyxPQUFPLENBQUMsQ0FBQTtLQUNqQztJQUFDLE9BQU8sQ0FBQyxFQUFFO1FBQ1YsT0FBTyxDQUFDLEtBQUssQ0FBQyxDQUFDLENBQUMsQ0FBQTtRQUVoQixJQUFJLENBQUMsQ0FBQyxPQUFPLENBQUMsS0FBSyxDQUFDLGlCQUFpQixDQUFDLEVBQUU7WUFDdEMsT0FBTyxLQUFLLENBQUE7U0FDYjtLQUNGO0lBQ0QsT0FBTyxJQUFJLENBQUE7QUFDYixDQUFDLENBQUE7QUFiWSxRQUFBLGNBQWMsa0JBYTFCIn0=
const expression = /^(\w{6})\w*(\w{4})$/;
/**
* Shortens a hash into something a little more user friendly
* @param hash
* @returns
*/
const shorten = (hash) => {
let result;
if (!hash) {
return null;
}
result = expression.exec(hash);
return `${result[1]}...${result[2]}`;
};
exports.shorten = shorten;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWRkcmVzcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9hZGRyZXNzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBLG1DQUErQjtBQUUvQjs7Ozs7R0FLRztBQUNJLE1BQU0sY0FBYyxHQUFHLENBQUMsT0FBTyxFQUFFLEVBQUU7SUFDeEMsSUFBSSxDQUFDLE9BQU87UUFBRSxPQUFNO0lBRXBCLElBQUk7UUFDRixlQUFNLENBQUMsS0FBSyxDQUFDLFVBQVUsQ0FBQyxPQUFPLENBQUMsQ0FBQTtLQUNqQztJQUFDLE9BQU8sQ0FBQyxFQUFFO1FBQ1YsT0FBTyxDQUFDLEtBQUssQ0FBQyxDQUFDLENBQUMsQ0FBQTtRQUVoQixJQUFJLENBQUMsQ0FBQyxPQUFPLENBQUMsS0FBSyxDQUFDLGlCQUFpQixDQUFDLEVBQUU7WUFDdEMsT0FBTyxLQUFLLENBQUE7U0FDYjtLQUNGO0lBQ0QsT0FBTyxJQUFJLENBQUE7QUFDYixDQUFDLENBQUE7QUFiWSxRQUFBLGNBQWMsa0JBYTFCO0FBRUQsTUFBTSxVQUFVLEdBQUcscUJBQXFCLENBQUE7QUFDeEM7Ozs7R0FJRztBQUNJLE1BQU0sT0FBTyxHQUFHLENBQUMsSUFBSSxFQUFFLEVBQUU7SUFDOUIsSUFBSSxNQUFNLENBQUE7SUFFVixJQUFJLENBQUMsSUFBSSxFQUFFO1FBQ1QsT0FBTyxJQUFJLENBQUE7S0FDWjtJQUVELE1BQU0sR0FBRyxVQUFVLENBQUMsSUFBSSxDQUFDLElBQUksQ0FBQyxDQUFBO0lBRTlCLE9BQU8sR0FBRyxNQUFNLENBQUMsQ0FBQyxDQUFDLE1BQU0sTUFBTSxDQUFDLENBQUMsQ0FBQyxFQUFFLENBQUE7QUFDdEMsQ0FBQyxDQUFBO0FBVlksUUFBQSxPQUFPLFdBVW5CIn0=

@@ -292,3 +292,4 @@ declare const _default: {

isValidAddress: (address: any) => boolean;
shorten: (hash: any) => string;
};
export = _default;

2

package.json
{
"name": "@pooltogether/utilities",
"version": "0.0.21",
"version": "0.0.22",
"description": "Shared utility functions across PoolTogether apps",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

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