Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
dayjs-abbr-timezone
Advanced tools
A plugin for day.js that extends the 'format' function, enabling the correct output of abbreviated timezones instead of the standard GMT display.
This package is a plugin for day.js that enhances the format function to correctly output abbreviated time zones. This is especially beneficial when the standard z
format does not meet your requirements.
For instance, when the timezone is set to Asia/Tokyo, the z
format would usually output GMT+9. However, with this plugin, you can use the tz
format to output JST correctly.
npm install dayjs-abbr-timezone
To use the plugin, first import it into your file:
import dayjs from 'dayjs';
import abbrTimezone from 'dayjs-abbr-timezone';
dayjs.extend(abbrTimezone);
Then you can use the format function with the tz
option:
const date = dayjs('2023-01-01T12:00:00Z');
console.log(date.format('YYYY-MM-DD HH:mm:ss tz'));
This will correctly display the abbreviated timezone rather than the standard GMT display.
If you encounter any issues or would like to contribute to the development of this plugin, please refer to this day.js issue or open an issue in this repository.
FAQs
A plugin for day.js that extends the 'format' function, enabling the correct output of abbreviated timezones instead of the standard GMT display.
The npm package dayjs-abbr-timezone receives a total of 247 weekly downloads. As such, dayjs-abbr-timezone popularity was classified as not popular.
We found that dayjs-abbr-timezone 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.