Gathering detailed insights and metrics for ts-luxon
Gathering detailed insights and metrics for ts-luxon
Gathering detailed insights and metrics for ts-luxon
Gathering detailed insights and metrics for ts-luxon
@odata2ts/converter-luxon
Luxon based odata2ts compatible converters for date and time related OData types
@ngx-tonysamperi/ts-luxon-date-adapter
Material date adapter for Angular 13+ (w/ Material) applications. Uses [ts-luxon](https://github.com/tonysamperi/ts-luxon) (typescript version of Luxon) to provide values for datepickers. @angular/material is required as dependency. Plus this offers some
fuzzy-date-ts
A TypeScript library for handling dates with variable precision
io-ts-datetime
io-ts datetime types with luxon
Typescript based Luxon: ⏱ A library for working with dates and times in TS and JS (immutable)
npm install ts-luxon
Typescript
Module System
Min. Node Version
Node Version
NPM Version
99.2
Supply Chain
100
Quality
85.4
Maintenance
100
Vulnerability
100
License
TypeScript (99.48%)
JavaScript (0.31%)
Nix (0.21%)
Total Downloads
3,327,242
Last Day
1,060
Last Week
36,131
Last Month
166,991
Last Year
1,687,919
MIT License
14 Stars
209 Commits
4 Forks
2 Watchers
11 Branches
2 Contributors
Updated on Jun 02, 2025
Minified
Minified + Gzipped
Latest Version
6.1.0
Package Id
ts-luxon@6.1.0
Unpacked Size
486.95 kB
Size
114.12 kB
File Count
71
NPM Version
10.9.2
Node Version
22.14.0
Published on
Jun 02, 2025
Cumulative downloads
Total Downloads
Last Day
-16.3%
1,060
Compared to previous day
Last Week
-17.6%
36,131
Compared to previous week
Last Month
-9.1%
166,991
Compared to previous month
Last Year
68.4%
1,687,919
Compared to previous year
TS Luxon is a library for working with dates and times in Javscript and Typescript.
This repo was initially created by GillesDebunne which of course started from Luxon itself.
Many thanks to both of them for this fantastic work.
I decided to fork his work, because we don't know for sure if and when Luxon will adopt this source.
I realized moment wasn't suitable anymore for my projects, but I couldn't wait to have a more stable version and at this time Luxon (v 1.25.0) had structural issues, which resulted in errors in my Angular projects.
With v6 I introduced a new release tag next
.
These versions are basically release candidates that can be tried out before they get released.
The next version tag gets cleared out automatically upon release of the latest stable version.
The beta releases instead, like it's always been, represent unstable releases, and they're subject to dramatic changes.
This finally solves the coexistence of ESM and CJS.
Many thanks to the autors of arethetypeswrong and publint, which were essential tools to debug and understand the package.json.
We reached a pretty much stable point for Intl support, which means we could finally drop that "compat" types that were needed to have a stable behaviour across various versions.
So in order to make everything work as expected you should have lib es2021 or later in your tsconfig.
Another option could be using skipLibCheck
, but depending on how to want to manage your compiler, you might want to keep this off (default).
1{ 2 "include": [ 3 "src" 4 ], 5 "exclude": [ 6 "test" 7 ], 8 "compilerOptions": { 9 "module": "CommonJS", 10 "target": "es6", 11 "lib": [ 12 "esnext" 13 ] 14 } 15}
Seriously. It's 2025. If you're using IE11 or require-js you may as well stick with date-fns, or moment. We drop heavy old stuff like the UMD bundle. But if you want to have tsLuxon in a global variable like it was before, you can do something like this:
1<script type="module"> 2 import * as tsLuxon from "https://unpkg.com/ts-luxon?module"; 3 window.tsLuxon = tsLuxon; 4</script>
You might even adjust this to work with require js, if you're happy! 😀 Although seriously, in that case, I suggest you to compile your own bundle with esbuild starting from the esm build. It's literally one line of code.
Compared to v4 here I only changed how the library is built and the outputs. It should be completely transparent to the user given the adjustments to the package.json and given the fact that the es6 export of v4 is interpreted as CJS anyways. I'm working on adding a real ESM module output to v5, but it seems there's no way of making the two coexist.
See the docs page
1DateTime.now().setZone('America/New_York').minus({ weeks: 1 }).endOf('day').toISO();
npm i ts-luxon --save
then
1import {DateTime} from "ts-luxon"; 2 3const myDto = DateTime.local();
You can download the umd bundle from here:
See the docs page
and the demo page
more example will be added! For suggestions open an issue or a PR (yes, even on the demo site if you want)!
Thanks to fire332 for his contribution about package.json
Please, read the CONTRIBUTING.md you can find in the master branch.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
2 existing vulnerabilities detected
Details
Reason
9 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 7
Reason
Found 0/10 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More