github / relative-time-element

Web component extensions to the standard <time> element.

Home Page:https://github.github.io/relative-time-element/examples/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Custom prefix for relative-time

tomas-mikula opened this issue · comments

I noticed that for <relative-time> which is further than 1 month ago we show example: on 14 April 2018

Would it be possible to add custom prefix, which if not specified would default to on (for backwards compatibility) but in case I could specify empty string so I would get just 14 April 2018?

This is now possible with the prefix attribute, which defaults to 'on' but can be set to '' to remove the prefix.