npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

date-filter

v1.0.6

Published

1.04版本后支持node

Downloads

2

Readme

1.04版本后支持node

{{ Date.now() | date '%T' }}  => '13:34:36'
{{ 'Wed Jan 20 2016 13:34:36 GMT+0800' | date '%T' }} => '13:34:36'
{{ 1453268193752 | date '%Y-%m-%d' }} => '2016-01-20'
{{ new Date | date '%I:%M:%s %p' }} => '1:39:22 PM'

more date parameters are listed below:

| param | explanation | example | |:--:|:--|:--| |%a | Abbreviated weekday. |{{ timestamp | date "%a" }} => "Sat" | |%A |Full weekday name. |{{ timestamp | date "%A" }} => "Tuesday" | |%b |Abbreviated month name. |{{ timestamp | date "%b" }} => "Jan" | |%B |Full month name |{{ timestamp | date "%B" }} => "January" | |%c |Preferred local date and time representation |{{ timestamp | date "%c" }} => "Tue Apr 22 11:16:09 2014" | |%d |Day of the month, zero-padded (01, 02, 03, etc.). |{{ timestamp | date "%d" }} => "04" | %-d |Day of the month, not zero-padded (1,2,3, etc.). |{{ timestamp | date "%-d" }} => "4" | |%D |Formats the date (dd/mm/yy). |{{ timestamp | date "%D" }} => "04/22/14" | |%e |Day of the month, blank-padded ( 1, 2, 3, etc.). |{{ timestamp | date "%e" }} => "3" | |%F |Returns the date in ISO 8601 format (yyyy-mm-dd). |{{ timestamp | date "%F" }} => "2014-04-22" | |%H |Hour of the day, 24-hour clock (00 - 23). |{{ timestamp | date "%H" }} => "15" | |%I |Hour of the day, 12-hour clock (1 - 12). |{{ timestamp | date "%I" }} => "7" | |%j |Day of the year (001 - 366). |{{ timestamp | date "%j" }} => "245" | |%k |Hour of the day, 24-hour clock (1 - 24). |{{ timestamp | date "%k" }} => "14" | |%m |Month of the year (01 - 12). |{{ timestamp | date "%m" }} => "04" | |%M |Minute of the hour (00 - 59). |{{ timestamp | date "%M" }} => "53" | |%p |Meridian indicator (AM/PM). |{{ timestamp | date "%p" }} => "PM" | |%r |12-hour time (%I:%M:%S %p) |{{ timestamp | date "%r" }} => "03:20:07 PM" | |%R |24-hour time (%H:%M) |{{ timestamp | date "%R" }} => "15:21" | |%T |24-hour time (%H:%M:%S) |{{ timestamp | date "%T" }} => "15:22:13" | |%U |The number of the week in the current year, starting with the first Sunday as the first day of the first week. |{{ timestamp | date "%U" }} => "16" | |%W |The number of the week in the current year, starting with the first Monday as the first day of the first week. |{{ timestamp | date "%W" }} => "16" | |%w |Day of the week (0 - 6, with Sunday being 0). |{{ timestamp | date "%w" }} => "2" | |%x |Preferred representation for the date alone, no time. (mm/dd/yy). |{{ timestamp | date "%x" }} => "04/22/14" | |%X |Preferred representation for the time. (hh:mm:ss). |{{ timestamp | date "%X" }} => "13:17:24" | |%y |Year without a century (00.99). |{{ timestamp | date "%y" }} => "14" | |%Y |Year with a century. |{{ timestamp | date "%Y" }} => "2014" |