All Projects → relvacode → iso8601

relvacode / iso8601

Licence: MIT license
A fast ISO8601 date parser for Go

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to iso8601

Gostradamus
Gostradamus: Better DateTimes for Go 🕰️
Stars: ✭ 148 (+21.31%)
Mutual labels:  time, datetime, date
Dpicker
A framework-agnostic minimal date picker
Stars: ✭ 187 (+53.28%)
Mutual labels:  time, datetime, date
Carbon
A simple PHP API extension for DateTime
Stars: ✭ 75 (-38.52%)
Mutual labels:  time, datetime, date
Iso8601
Ruby parser to work with ISO8601 dateTimes and durations — http://en.wikipedia.org/wiki/ISO_8601
Stars: ✭ 70 (-42.62%)
Mutual labels:  time, datetime, date
ptera
Ptera is DateTime library for Deno
Stars: ✭ 62 (-49.18%)
Mutual labels:  time, datetime, date
Delorean
Delorean: Time Travel Made Easy
Stars: ✭ 1,793 (+1369.67%)
Mutual labels:  time, datetime, date
Tail.datetime
A lightweight, translat- and configurable Open Source DateTime Picker, written in pure vanilla JavaScript!
Stars: ✭ 139 (+13.93%)
Mutual labels:  time, datetime, date
Zulu
A drop-in replacement for native Python datetimes that embraces UTC.
Stars: ✭ 52 (-57.38%)
Mutual labels:  time, datetime, date
Jiffy
Jiffy is a Flutter (Android, IOS and Web) date time package inspired by momentjs for parsing, manipulating, querying and formatting dates
Stars: ✭ 238 (+95.08%)
Mutual labels:  time, datetime, date
Dateparse
GoLang Parse many date strings without knowing format in advance.
Stars: ✭ 1,365 (+1018.85%)
Mutual labels:  time, datetime, date
Date Picker
📅 Custom responsive date picker widget for Android, written in Kotlin.
Stars: ✭ 146 (+19.67%)
Mutual labels:  time, datetime, date
Calendar
📅 PHP Date & Time library that solves common problems in object oriented, immutable way.
Stars: ✭ 113 (-7.38%)
Mutual labels:  time, datetime, date
When
A natural language date/time parser with pluggable rules
Stars: ✭ 1,113 (+812.3%)
Mutual labels:  time, datetime, date
Time
Building a better date/time library for Swift
Stars: ✭ 1,983 (+1525.41%)
Mutual labels:  time, datetime, date
Laydate
layDate(日期与时间组件) 是 layui 独立维护的三大组件之一
Stars: ✭ 1,066 (+773.77%)
Mutual labels:  time, datetime, date
Graphql Java Datetime
GraphQL ISO Date is a set of RFC 3339 compliant date/time scalar types to be used with graphql-java.
Stars: ✭ 89 (-27.05%)
Mutual labels:  time, datetime, date
Dayjs
⏰ Day.js 2kB immutable date-time library alternative to Moment.js with the same modern API
Stars: ✭ 37,373 (+30533.61%)
Mutual labels:  time, datetime, date
Tinydate
A tiny (349B) reusable date formatter. Extremely fast!
Stars: ✭ 990 (+711.48%)
Mutual labels:  time, datetime, date
Luatz
Time, Date and Timezone library for lua
Stars: ✭ 92 (-24.59%)
Mutual labels:  time, datetime, date
Time Stamp
Get a formatted timestamp. Used in gulp, assemble, generate, and many others.
Stars: ✭ 104 (-14.75%)
Mutual labels:  time, datetime, date

A fast ISO8601 date parser for Go

GoDoc Build Status Go Report Card

go get github.com/relvacode/iso8601

The built-in RFC3333 time layout in Go is too restrictive to support any ISO8601 date-time.

This library parses any ISO8601 date into a native Go time object without regular expressions.

Usage

package main

import "github.com/relvacode/iso8601"

// iso8601.Time can be used as a drop-in replacement for time.Time with JSON responses
type ExternalAPIResponse struct {
	Timestamp *iso8601.Time
}


func main() {
	// iso8601.ParseString can also be called directly
	t, err := iso8601.ParseString("2020-01-02T16:20:00")
}

Benchmark

BenchmarkParse-16        	13364954	        77.7 ns/op	       0 B/op	       0 allocs/op

Release History

  • 1.3.0

Allow a leading + sign in the year component #11

  • 1.2.0

Time range validity checking equivalent to the standard library. Note that previous versions would not validate that a given date string was in the expected range. Additionally, this version no longer accepts 0000-00-00T00:00:00 as a valid input which can be the zero time representation in other languages nor does it support leap seconds (such that the seconds field is 60) as is the case in the standard library

  • 1.1.0

Check for -0 time zone

  • 1.0.0

Initial release

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].