Socket
Socket
Sign inDemoInstall

fecha

Package Overview
Dependencies
0
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Install Socket

Protect your apps from supply chain attacks

Install
23Next

4.2.3

Diff

Changelog

Source

4.2.3

  • Fixed bug with UTC date on daylights savings time #94
taylorhakes
published 4.2.2 •

taylorhakes
published 4.2.1 •

Changelog

Source

4.2.1

  • Fixed missing source map
  • Fixed security y18n
taylorhakes
published 4.2.0 •

Changelog

Source

4.2.0

Added isoDate and isoDateTime masks

taylorhakes
published 4.1.0 •

Changelog

Source

4.1.0

Added Z format/parse and fixed Peru timezone issue

  • Added Z format token. See readme for more info. Big thanks to @fer22f for writing the code.
  • Fixed a strange issue when Peru changed timezones in 1990. See #78
taylorhakes
published 4.0.0 •

Changelog

Source

4.0.0

Major Features and Breaking changes in this version

Improvements
  • Valid date parsing - By default fecha will check validity of dates. Previously 2019-55-01 or 2019-01-42 would parse correctly, since Javascript can handle it. Now invalid dates will return null instead
  • ES Module and Tree Shaking Support - You can now import fecha parse or format independently
import {format, parse} from 'fecha';

format(...);
parse(...)
Breaking changes
  • parseDate may return null when previously returned a Date. See improvements above, but invalid dates will return null now
  • Change to how to set masks and i18n Previously
import fecha from 'fecha';

fecha.i18n = { ... }
fecha.masks.myMask = 'DD , MM, YYYY' 

New

import {parse, format, setGlobalDateI18n, setGlobalDateMasks} from 'fecha';

setGlobalDateI18n({
    // ...
})
setGlobalDateMasks({
  myMask: 'DD , MM, YYYY'
});
taylorhakes
published 4.0.0-beta.0 •

taylorhakes
published 4.0.0-alpha.1 •

taylorhakes
published 4.0.0-alpha.0 •

taylorhakes
published 3.0.3 •

Changelog

Source

3.0.3

  • Fixed bug when using brackets when parsing dates
23Next
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc