/ piacw.com / dev / final / node_modules / @braintree / sanitize-url /

[ICO]NameLast modifiedSizeDescription
[PARENTDIR]Parent Directory  -  
[DIR]test/2 years ago -  
[TXT]CHANGELOG.md2 years ago400 0fb859dc fixed mobile overflwo options [كارل مبارك]
[   ]LICENSE2 years ago1.0K0fb859dc fixed mobile overflwo options [كارل مبارك]
[TXT]README.md2 years ago586 0fb859dc fixed mobile overflwo options [كارل مبارك]
[   ]index.js2 years ago854 0fb859dc fixed mobile overflwo options [كارل مبارك]
[   ]package.json2 years ago1.4K0fb859dc fixed mobile overflwo options [كارل مبارك]
README.md

sanitize-url

Installation

npm install -S @braintree/sanitize-url

Usage

var sanitizeUrl = require('@braintree/sanitize-url').sanitizeUrl;

sanitizeUrl('https://example.com'); // 'https://example.com'
sanitizeUrl('http://example.com'); // 'http://example.com'
sanitizeUrl('mailto:hello@example.com'); // 'mailto:hello@example.com'

sanitizeUrl('javascript:alert(document.domain)'); // 'about:blank'
sanitizeUrl('jAvasCrIPT:alert(document.domain)'); // 'about:blank'
sanitizeUrl(decodeURIComponent('JaVaScRiP%0at:alert(document.domain)')); // 'about:blank'
Apache/2.4.38 (Debian) Server at www.karls.computer Port 80