Security News
RubyGems.org Adds New Maintainer Role
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.
temporal-polyfill
Advanced tools
A spec-compliant* Temporal JavaScript polyfill in less than 15kb**.
Works in modern browsers***, not Internet Explorer.
npm install temporal-polyfill
A) Import globally:
import 'temporal-polyfill/global'
// the global Temporal object is now available
const zdt = Temporal.ZonedDateTime.from('2020-08-05T20:06:13[America/Chicago]')
console.log(zdt.toLocaleString())
B) Import as an ES module without side effects:
import { ZonedDateTime } from 'temporal-polyfill'
const zdt = ZonedDateTime.from('2020-08-05T20:06:13[America/Chicago]')
console.log(zdt.toLocaleString())
The above techniques try using the built-in Temporal
object and fall back to the polyfill.
To guarantee using the polyfill, do this:
import { ZonedDateTime } from 'temporal-polyfill/impl'
const zdt = ZonedDateTime.from('2020-08-05T20:06:13[America/Chicago]')
console.log(zdt.toLocaleString())
* = almost spec-compliant. a few more tests must pass (see results)
** = the size will shrink as the codebase is cleaned up
*** = targets browsers that support BigInt, however, more browser-compatibility work is needed
FAQs
A lightweight polyfill for Temporal, successor to the JavaScript Date object
The npm package temporal-polyfill receives a total of 46,912 weekly downloads. As such, temporal-polyfill popularity was classified as popular.
We found that temporal-polyfill demonstrated a healthy version release cadence and project activity because the last version was released less than 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
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.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.