ember-autolinkify

1.3.0 • Public • Published

ember-autolinkify

This addon is a template helper for https://github.com/gregjacobs/Autolinker.js.

  • ember install ember-autolinkify

Usage

  {{{linkify 'https://google.com'}}}

Will be: <a href="https://google.com/" target="_blank" rel="noopener noreferrer">google.com</a>

  {{{linkify 'https://google.com' newWindow=false}}}

Will be: <a href="https://google.com/">google.com</a>

WARNING: you need to use this helper with unsafe handlebars ({{{htmlHereThatCanBeBad}}}). It is recommended if this is being used for user inserted data that you use it alongside https://github.com/sivakumar-kailasam/ember-purify.

Configuration

Defaults and available options

https://github.com/gregjacobs/Autolinker.js#options

Global configuration

ENV.APP.linkify = {
  // Refer to various config options in the Autolinker.js README
};

Helper options

You can pass any of the options into the helper.

  {{linkify 'https://google.com' newWindow=false}}

Will be: <a href="https://google.com/">google.com</a>

Installation for Development

  • git clone https://github.com/postedin/ember-autolinkify.git

  • cd ember-autolinkify

  • yarn install

  • Ember.js v2.18 or above

  • Ember CLI v2.13 or above

  • Node.js v8 or above

Installation

<<<<<<< HEAD

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

15ec31c... message

<<<<<<< HEAD

  • ember build ======= Usage

[Longer description of how to use the addon in apps.]

Contributing

See the Contributing guide for details.

License

This project is licensed under the MIT License.

15ec31c... message

Readme

Keywords

Package Sidebar

Install

npm i ember-autolinkify

Weekly Downloads

4

Version

1.3.0

License

MIT

Unpacked Size

6.87 kB

Total Files

8

Last publish

Collaborators

  • robbo