scribe-plugin-sanitizer

WebJar for scribe-plugin-sanitizer

License

License

Apache 2.0
GroupId

GroupId

org.webjars.bower
ArtifactId

ArtifactId

scribe-plugin-sanitizer
Last Version

Last Version

0.1.10
Release Date

Release Date

Type

Type

jar
Description

Description

scribe-plugin-sanitizer
WebJar for scribe-plugin-sanitizer
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/guardian/scribe-plugin-sanitizer

Download scribe-plugin-sanitizer

How to add to project

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

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

scribe-plugin-sanitizer

**NB: this project is no longer distributed over Bower. Please use npm for future versions

Installation

bower install scribe-plugin-sanitizer

Usage Example

scribe-plugin-sanitizer is an AMD module:

require(['scribe', 'scribe-plugin-sanitizer'], function (Scribe, scribePluginSanitizer) {
  var scribeElement = document.querySelector('.scribe');
  var scribe = new Scribe(scribeElement);
  scribe.use(scribePluginSanitizer({
    tags: {
      p: true,
      a: {
        href: true,
        target: '_blank'
      }
    }
  }));
});

It uses the same format of options as html-janitor. To whitelist a tag, specify true for it. To whitelist specific attributes or even specific values, use an object.

org.webjars.bower

The Guardian

The source code of the world's leading liberal voice

Versions

Version
0.1.10