htmlescape

WebJar for htmlescape

Лицензия

Лицензия

MIT
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

htmlescape
Последняя версия

Последняя версия

1.1.1
Дата

Дата

Тип

Тип

jar
Описание

Описание

htmlescape
WebJar for htmlescape
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/zertosh/htmlescape

Скачать htmlescape

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/htmlescape/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>htmlescape</artifactId>
    <version>1.1.1</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/htmlescape/
implementation 'org.webjars.npm:htmlescape:1.1.1'
// https://jarcasting.com/artifacts/org.webjars.npm/htmlescape/
implementation ("org.webjars.npm:htmlescape:1.1.1")
'org.webjars.npm:htmlescape:jar:1.1.1'
<dependency org="org.webjars.npm" name="htmlescape" rev="1.1.1">
  <artifact name="htmlescape" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='htmlescape', version='1.1.1')
)
libraryDependencies += "org.webjars.npm" % "htmlescape" % "1.1.1"
[org.webjars.npm/htmlescape "1.1.1"]

Зависимости

Библиотека не имеет зависимостей. Это самодостаточное приложение, которое не зависит ни от каких других библиотек.

Модули Проекта

Данный проект не имеет модулей.

htmlescape

Properly escape JSON for usage as an object literal inside of a <script> tag. Use htmlescape in place of JSON.stringify. For more info see JSON: The JavaScript subset that isn't.

Transformations

from to
& \\u0026
> \\u003e
< \\u003c
\u2028 \\u2028
\u2029 \\u2029

Usage

var htmlescape = require('htmlescape');
htmlescape({prop:'value'});
//=> '{"prop":"value"}'

Or in your templates:

<script>
var payload = <%= htmlescape(payload) %>;
</script>

Версии библиотеки

Версия
1.1.1
1.1.0