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

xss

Package Overview
Dependencies
Maintainers
1
Versions
71
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xss - npm Package Compare versions

Comparing version 0.3.1 to 0.3.2

2

package.json

@@ -5,3 +5,3 @@ {

"typings": "./typings/xss.d.ts",
"version": "0.3.1",
"version": "0.3.2",
"description": "Sanitize untrusted HTML (to prevent XSS) with a configuration specified by a Whitelist",

@@ -8,0 +8,0 @@ "author": "Zongmin Lei <leizongmin@gmail.com> (http://ucdok.com)",

@@ -89,5 +89,5 @@ /**

export type OnTagHandler = (tag: string, html: string, options: {}) => string;
export type OnTagHandler = (tag: string, html: string, options: {}) => string | void;
export type OnTagAttrHandler = (tag: string, name: string, value: string) => string;
export type OnTagAttrHandler = (tag: string, name: string, value: string) => string | void;

@@ -110,3 +110,3 @@ export type SafeAttrValueHandler = (tag: string, name: string, value: string, cssFilter: ICSSFilter) => string;

isClosing: boolean;
});
}): string;
remove(html: string): string;

@@ -124,3 +124,3 @@ };

FilterXSS: typeof FilterXSS;
parseTag(html: string, onTag: (sourcePosition: number, position: number, tag: string, html: string, isClosing: boolean) => string, escapeHtml: EscapeHandler): string;
parseTag(html: string, onTag: (sourcePosition: number, position: number, tag: string, html: string, isClosing: boolean) => string, escapeHtml: XSS.EscapeHandler): string;
parseAttr(html: string, onAttr: (name: string, value: string) => string): string;

@@ -127,0 +127,0 @@ whiteList: XSS.IWhiteList;

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