better-prettydate
Enhances
.prettydateelement to update text in realtime
Strings like "an hour ago", "X minutes ago" etc. became to be a standard solution for some UI elements. This project aims to solve adding support for such kind of extension by enhancing elements with the prettydate class in HTML markup.
Installing
Use bower to download this extension with all required dependencies.
bower install better-prettydate
This will clone the latest version of the better-prettydate into the bower_components directory at the root of your project.
Then append the following html elements on your page:
<html>
<head>
...
<!--[if IE]>
<link href="bower_components/better-dom/dist/better-dom-legacy.htc" rel="htc"/>
<script src="bower_components/better-dom/dist/better-dom-legacy.js"></script>
<![endif]-->
</head>
<body>
...
<script src="bower_components/better-dom/dist/better-dom.js"></script>
<script src="bower_components/better-prettydate/dist/better-prettydate.js"></script>
</body>
</html>Browser support
Desktop
- Chrome
- Safari 6.0+
- Firefox 16+
- Opera 12.10+
- IE8+
Mobile
- iOS Safari 6+
- Android 2.3+
- Chrome for Android

