Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
JDate aka Date class implementation for Jalali calendar
This package aimed to develop and maintain Jalaali Calendar also called Persian Calendar in the form of Javascript Date Class, Basically we have a JDate class with identical interface and behavior of Data class
I believe we need more atomic libraries in javascript that are independent of other frameworks/libs. this package is one of those atomics, I searched a lot to find a real implementation of Date class for Jalali calendar and found a few. All of them was not really identical with Date class in term of interface and behavior. the only on that was close to this idea was jdate and it was pure in coding, maintenance and modern development, still I'm not sure about it's possible logical bugs! I refactored this code to a modern and modular npm package for ease of use in modern work flow.
npm install j-date --save
using node, webpack, browserify and other commonjs modular environments
var JDate = require('./dist/j-date.src').JDate;
// will log someting like 1394/12/02 03:30:00
console.log((new JDate('1394-12-2')).toLocaleString());
// using harmony modules
// default export
import JDate from 'j-date'
// or named export
import { JDate } from 'j-date'
using globals in browser download dist/j-date.js and load it using script tag
// will log someting like 1394/12/02 03:30:00
console.log((new JDate('1394-12-2')).toLocaleString());
Fork this repo and always keep your code on a git branch other than master branch,
requirements
npm 3.. or upper
node 4.. or upper
git clone clone git@github.com:you/j-date.git
npm install
npm run serve
run build script to make sure build passes without errors
npm run build
Writing Tests
Making sure it's identical to Date
Refactor code
Resolve eslint errors
Document known differences to Data Class
Writing documentation
FAQs
Date class implementation in Jalali calendar
We found that j-date demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.