dateparse icon indicating copy to clipboard operation
dateparse copied to clipboard

parses string as a date

Open shivamsouravjha opened this issue 10 months ago • 1 comments

import (
	"fmt"
	"strings"

	"github.com/araddon/dateparse"
)

func main() {
	stringDate := "music, coding, artd"
	s := strings.TrimSpace(stringDate)
	date, err := dateparse.ParseAny(s)
	fmt.Println(date, err)
}

shivamsouravjha avatar Apr 02 '24 09:04 shivamsouravjha