JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 15192
  • Score
    100M100P100Q131911F
  • License MIT

A helper for safely embedding URLs in style properties

Package Exports

  • ember-css-url

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (ember-css-url) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

ember-css-url

A helper for safely embedding URLs in style properties. Avoids CSS XSS exposure and sanitizes user-provided URLs.

<div style={{css-url "background-image" user.avatarURL}} ></div>
<div style='background-image: url("https://example.com/avatar.png")' ></div>

Installation

  • git clone <repository-url> this repository
  • cd ember-css-url
  • yarn install

Running

Running Tests

  • yarn test (Runs ember try:each to test your addon against multiple Ember versions)
  • ember test
  • ember test --server

Building

  • ember build

For more information on using ember-cli, visit https://ember-cli.com/.