GithubHelp home page GithubHelp logo

besrourms / cal-format-js Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 7 KB

cal-format-js is a JavaScript library that simplifies the formatting of dates in multiple calendars. It provides an easy-to-use interface for formatting dates in various calendar systems, including Gregorian, Islamic, and others.

License: MIT License

JavaScript 100.00%
calendars

cal-format-js's Introduction

License: MIT

cal-format-js

cal-format-js is a JavaScript library that simplifies the formatting of dates in multiple calendars. It provides an easy-to-use interface for formatting dates in various calendar systems, including Gregorian, Islamic, and others.

Installation

<script src="https://cdn.jsdelivr.net/gh/besrourms/cal-format-js@latest/index.min.js"></script>

Examples

console.log(new Calendars())
// Return
{
    "gregory": "Monday, March 11, 2024"
}
console.log(new Calendars('fr', 'TN'))
// Return
{
    "gregory": "lundi 11 mars 2024",
    "islamic": "lundi 1 ramadan 1445 AH",
    "islamic-civil": "lundi 1 ramadan 1445 AH",
    "islamic-tbla": "lundi 2 ramadan 1445 AH"
}
console.log(new Calendars('ar', 'TN', '1991-11-30'))
// Return
{
    "gregory": "السبت، 30 نوفمبر 1991",
    "islamic": "السبت، 24 جمادى الأولى 1412 هـ",
    "islamic-civil": "السبت، 23 جمادى الأولى 1412 هـ",
    "islamic-tbla": "السبت، 24 جمادى الأولى 1412 هـ"
}

cal-format-js's People

Contributors

besrourms avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.