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

@ensdomains/ens-avatar

Package Overview
Dependencies
Maintainers
0
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ensdomains/ens-avatar - npm Package Compare versions

Comparing version 1.0.0-alpha.2.ethers.6 to 1.0.0-alpha.3.ethers.6

25

dist/index.js

@@ -312,3 +312,5 @@ 'use strict';

// purges malicious scripting from svg content
var cleanDOM = DOMPurify.sanitize(data);
var cleanDOM = DOMPurify.sanitize(data, {
FORBID_TAGS: ['a', 'area', 'base', 'iframe', 'link']
});
return Buffer.from(cleanDOM);

@@ -340,24 +342,3 @@ }

// ref: https://github.com/flexdinesh/browser-or-node/blob/master/src/index.ts
var isBrowser = typeof window !== 'undefined' && typeof window.document !== 'undefined';
typeof process !== 'undefined' &&
process.versions != null &&
process.versions.node != null;
// https://github.com/jsdom/jsdom/issues/1537#issuecomment-229405327
(typeof window !== 'undefined' && window.name === 'nodejs') ||
(typeof navigator !== 'undefined' &&
'userAgent' in navigator &&
typeof navigator.userAgent === 'string' &&
(navigator.userAgent.includes('Node.js') ||
navigator.userAgent.includes('jsdom')));
// @ts-expect-error
typeof Deno !== 'undefined' &&
// @ts-expect-error
typeof Deno.version !== 'undefined' &&
// @ts-expect-error
typeof Deno.version.deno !== 'undefined';
/** @see {@link https://bun.sh/guides/util/detect-bun} */
typeof process !== 'undefined' &&
process.versions != null &&
process.versions.bun != null;

@@ -364,0 +345,0 @@ function createAgentAdapter(fetch, agents) {

declare const isBrowser: boolean;
declare const isNode: boolean;
declare const isWebWorker: boolean;
declare const isJsDom: boolean;
declare const isDeno: boolean;
/** @see {@link https://bun.sh/guides/util/detect-bun} */
declare const isBun: boolean;
export { isBrowser, isWebWorker, isNode, isJsDom, isDeno, isBun };
export { isBrowser };

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

// ref: https://github.com/flexdinesh/browser-or-node/blob/master/src/index.ts
var isBrowser = typeof window !== 'undefined' && typeof window.document !== 'undefined';
typeof process !== 'undefined' &&
process.versions != null &&
process.versions.node != null;
// https://github.com/jsdom/jsdom/issues/1537#issuecomment-229405327
(typeof window !== 'undefined' && window.name === 'nodejs') ||
(typeof navigator !== 'undefined' &&
'userAgent' in navigator &&
typeof navigator.userAgent === 'string' &&
(navigator.userAgent.includes('Node.js') ||
navigator.userAgent.includes('jsdom')));
// @ts-expect-error
typeof Deno !== 'undefined' &&
// @ts-expect-error
typeof Deno.version !== 'undefined' &&
// @ts-expect-error
typeof Deno.version.deno !== 'undefined';
/** @see {@link https://bun.sh/guides/util/detect-bun} */
typeof process !== 'undefined' &&
process.versions != null &&
process.versions.bun != null;
export { isBrowser };

4

dist/utils/getImageURI.js

@@ -69,3 +69,5 @@ import createDOMPurify from 'dompurify';

// purges malicious scripting from svg content
var cleanDOM = DOMPurify.sanitize(data);
var cleanDOM = DOMPurify.sanitize(data, {
FORBID_TAGS: ['a', 'area', 'base', 'iframe', 'link']
});
return Buffer.from(cleanDOM);

@@ -72,0 +74,0 @@ }

{
"version": "1.0.0-alpha.2.ethers.6",
"version": "1.0.0-alpha.3.ethers.6",
"license": "MIT",

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

@@ -1,38 +0,4 @@

// ref: https://github.com/flexdinesh/browser-or-node/blob/master/src/index.ts
const isBrowser: boolean =
typeof window !== 'undefined' && typeof window.document !== 'undefined';
const isNode: boolean =
typeof process !== 'undefined' &&
process.versions != null &&
process.versions.node != null;
const isWebWorker: boolean =
typeof self === 'object' &&
self.constructor &&
self.constructor.name === 'DedicatedWorkerGlobalScope';
// https://github.com/jsdom/jsdom/issues/1537#issuecomment-229405327
const isJsDom: boolean =
(typeof window !== 'undefined' && window.name === 'nodejs') ||
(typeof navigator !== 'undefined' &&
'userAgent' in navigator &&
typeof navigator.userAgent === 'string' &&
(navigator.userAgent.includes('Node.js') ||
navigator.userAgent.includes('jsdom')));
const isDeno: boolean =
// @ts-expect-error
typeof Deno !== 'undefined' &&
// @ts-expect-error
typeof Deno.version !== 'undefined' &&
// @ts-expect-error
typeof Deno.version.deno !== 'undefined';
/** @see {@link https://bun.sh/guides/util/detect-bun} */
const isBun =
typeof process !== 'undefined' &&
process.versions != null &&
process.versions.bun != null;
export { isBrowser, isWebWorker, isNode, isJsDom, isDeno, isBun };
export { isBrowser };

@@ -74,3 +74,5 @@ import createDOMPurify from 'dompurify';

// purges malicious scripting from svg content
const cleanDOM = DOMPurify.sanitize(data);
const cleanDOM = DOMPurify.sanitize(data, {
FORBID_TAGS: ['a', 'area', 'base', 'iframe', 'link'],
});
return Buffer.from(cleanDOM);

@@ -77,0 +79,0 @@ }

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