Returns the start of the week based on the locale.
npm install --save start-of-week
<script type="module"> import * as pkg from '//dev.jspm.io/start-of-week' </script>
This package is published with the following editions:
start-of-week/source/index.tsis typescript source code with import for modules
start-of-week/edition-browsers/index.jsis typescript compiled for browsers with import for modules
start-of-week/edition-node-12/index.jsis typescript compiled for node.js 12 with require for modules
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.
These amazing people are maintaining this project:
- Benjamin Lupton
No sponsors yet! Will you be the first?
These amazing people have contributed code to this project:
Unless stated otherwise all works are:
- Copyright © 2019+ Benjamin Lupton
and licensed under: