Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pvorb/node-esc
escapes HTML
https://github.com/pvorb/node-esc
Last synced: about 1 month ago
JSON representation
escapes HTML
- Host: GitHub
- URL: https://github.com/pvorb/node-esc
- Owner: pvorb
- License: mit
- Created: 2011-09-15T14:11:14.000Z (about 13 years ago)
- Default Branch: master
- Last Pushed: 2012-03-03T10:05:17.000Z (over 12 years ago)
- Last Synced: 2024-09-16T03:43:12.485Z (2 months ago)
- Language: JavaScript
- Homepage: https://npmjs.com/package/esc
- Size: 115 KB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.mkd
- License: LICENSE.mkd
Awesome Lists containing this project
README
**esc** allows you to quickly escape HTML strings. It is capable of
automatically extending URLs in the HTML for use in feeds.## Example
```javascript
var esc = require('esc');var html = 'link';
console.log(esc(html, { uri: 'http://example.com/path/to/document.html' }));
```This will print:
```
<a href="http://example.com/path/some.html">
```