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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@navigatrum/weekdays

v1.0.6

Published

Get an array of weekday names in any language, order, format.

Downloads

11

Readme

📆 weekedays

Get an array of weekday names in any language, order, format.

Supports:

  • Languages: Any locale supported by Intl.DateTimeFormat
  • Order: Start from any day (Sunday, Monday, or even "current")
  • Format:
    • Style: "long", "short", "narrow"
    • Case: "capital", "upper", "lower"

npm version Bundle size Build Status Types License


📦 Installation

npm install @navigatrum/weekdays
# or
yarn add @navigatrum/weekdays
#or
pnpm add @navigatrum/weekdays

🚀 Usage

import { weekdays } from "weekdays";

📚 Examples

// Weekdays in the current locale, starting from Sunday, using native casing
weekdays();
// ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday']

// French weekdays, starting from Sunday, using native casing
weekdays({ locales: "fr" });
// ['dimanche', 'lundi', 'mardi', 'mercredi', 'jeudi', 'vendredi', 'samedi']

// Arabic weekdays starting from Saturday
weekdays({ first: 6, locales: "ar" });
// ['السبت', 'الأحد', 'الاثنين', 'الثلاثاء', 'الأربعاء', 'الخميس', 'الجمعة']

// Spanish weekdays starting from current day (e.g. Friday), capitalized, in short form
weekdays({
  first: "current",
  case: "capital",
  style: "short",
  locales: "es-ES",
});
// ['Vie', 'Sáb', 'Dom', 'Lun', 'Mar', 'Mié', 'Jue']

// Chinese weekdays in short form, starting from Monday
weekdays({ locales: "zh-CN", first: 1, style: "short" });
// ['周一', '周二', '周三', '周四', '周五', '周六', '周日']

🛠️ Options

type WeekdaysOptions = {
  locales?: string | string[]; // default: system/browser locale
  style?: "long" | "short" | "narrow"; // default: "long"
  case?: "capital" | "upper" | "lower"; // default: native casing
  first?: 0 | 1 | 2 | 3 | 4 | 5 | 6 | "current"; // default: 0 (Sunday)
};