Skip to content
Returns the start of the week based on the locale.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
source
.editorconfig
.gitignore
.npmignore
.travis.yml
CONTRIBUTING.md
HISTORY.md
LICENSE.md
README.md
package-lock.json
package.json
tsconfig.json

README.md

start-of-week

Travis CI Build Status NPM version NPM downloads Dependency Status Dev Dependency Status
Patreon donate button Flattr donate button Liberapay donate button Thanks App donate button Boost Lab donate button Buy Me A Coffee donate button Open Collective donate button crypto donate button PayPal donate button Wishlist browse button

Returns the start of the week based on the locale.

Install

npm

  • Install: npm install --save start-of-week
  • Require: require('start-of-week')

jspm

<script type="module">
    import * as pkg from '//dev.jspm.io/start-of-week'
</script>

Editions

This package is published with the following editions:

  • start-of-week/source/index.ts is typescript source code with import for modules
  • start-of-week/edition-browsers/index.js is typescript compiled for browsers with import for modules
  • start-of-week aliases start-of-week/edition-node-12/index.js
  • start-of-week/edition-node-12/index.js is typescript compiled for node.js 12 with require for modules

Usage

API Documentation.

const startOfWeek = require('start-of-week')
console.log(startOfWeek) // 0 (Sunday) if North American, otherwise 1 (Monday)

If you want something comprehensive, use gamtiq/weekstart instead.

History

Discover the release history by heading on over to the HISTORY.md file.

Contribute

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

Backers

Maintainers

These amazing people are maintaining this project:

  • Benjamin Lupton

Sponsors

No sponsors yet! Will you be the first?

Patreon donate button Flattr donate button Liberapay donate button Thanks App donate button Boost Lab donate button Buy Me A Coffee donate button Open Collective donate button crypto donate button PayPal donate button Wishlist browse button

Contributors

These amazing people have contributed code to this project:

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

License

Unless stated otherwise all works are:

  • Copyright © 2019+ Benjamin Lupton

and licensed under:


You can’t perform that action at this time.