@zestia/ember-wrap-urls
This Ember addon takes some text, which may or may not contain URLs and renders the text and each URL as an Ember component.
Installation
ember install @zestia/ember-wrap-urls
Demo
https://zestia.github.io/ember-wrap-urls/
Example
Given the following:
Will render:
Built in components
This addon comes with two built in components:
wrap-urls/url
wrap-urls/link
By default, URLs will be rendered using wrap-urls/url
You can set @Url
to change which component is used to render each URL:
Will result in:
Customising
Specify your own @pattern
to use for finding hyperlinks, and your own @Url
to customise how they are rendered.
In your component's template you will have access to: