New package repository JSR; proposed Set methods; Array.prototype.with(); Promise collection methods

WorkOS, the modern API for auth and user identity.

workos.com Sponsor

WorkOS enables B2B SaaS companies to accelerate enterprise adoption with identity management and complex features like Single Sign-On, SCIM, and User Management. Built for developers tired of using legacy providers like Auth0, WorkOS delivers a unified platform with modern APIs and a predictable pricing model that will scale seamlessly with your enterprise motion.

JSR first impressions (new package repository by Deno team)

www.kitsonkelly.com @kitsonk@aus.social

“JSR is a JavaScript/TypeScript registry. It is not a package manager. It is pretty clear that npm was the first viable package manager and registry for the JavaScript ecosystem. Since then we have seen a lot of innovation in the package manager side of the equation, with yarn, pnpm, and even run-times integrating that package manager like Bun. [...] There has been little change or innovation on the registry side that still has the npm registry at its core.”

Highlights:

  • “JSR supports semver expression of dependencies.” This feature helps Deno – which, until now, has used exact versions.
  • JSR dynamically adapts its packages to specific requests:
    • “[...] you publish your source, be it [only] TypeScript or [only] JavaScript, and the registry makes sure that the users consume the right version of code.”
    • “[...] while it isn't part of JSR at the moment, very soon JSR will generate type definitions along with transpiled JavaScript code when targeting the npm ecosystem.”
    • “The registry is runtime aware in that the package creator publishes a single version and the registry handles serving up a version specific to the target runtime [Deno, Node.js, etc.].”
  • TypeScript-related features:
    • “[...] published code is ‘zapped’” – type-checked in a limited, quick way.
    • “[...] published code can be fully documented via automatic document generation.”

Union, intersection, difference, and more are coming to JavaScript Sets

www.sonarsource.com @philnash@mastodon.social

Proposed methods:
  • Set.prototype.intersection(other)
  • Set.prototype.union(other)
  • Set.prototype.difference(other)
  • Set.prototype.symmetricDifference(other)
  • Set.prototype.isSubsetOf(other)
  • Set.prototype.isSupersetOf(other)
  • Set.prototype.isDisjointFrom(other)

Immutable array updates via Array.prototype.with()

web.dev github.com/jadjoubran

“Browsers recently gained a new interoperable method that you can call on Arrays: Array.prototype.with().”

“This article explores how this method works and how to use it to update an array without mutating the original array.”

const ages = [10, 15, 20, 25];
const newAges = ages.with(1, 16);

console.log(newAges); // [10, 16, 20, 25]
console.log(ages); // [10, 15, 20, 25] (unchanged)

Looking at the JavaScript Promise Collection Methods

www.raymondcamden.com @raymondcamden@mastodon.social

“[...] ‘Promise Collection Methods’ is not something I’ve seen mentioned elsewhere, but is my own way of referring to the various methods of the Promise API that work with multiple promises.” They are:
  • Promise.all()
  • Promise.allSettled()
  • Promise.any()
  • Promise.race()

Detect and block JavaScript supply chain attacks

socket.dev Sponsor

Quickly evaluate the security and health of any npm package. Socket is not a traditional vulnerability scanner. Socket proactively detects and blocks 70+ signals of supply chain risk in open source code, for comprehensive protection.

“Tempo”: date and time library that works with JavaScript Date objects and supports time zones

tempo.formkit.com github.com/formkit

Tempo is a date and time library:
  • It works with JavaScript Date objects and supports time zone operations.
  • “Under the hood, Tempo mines JavaScript’s Intl.DateTimeFormat to extract complex data like time zone offsets and locale aware date formats, giving you a simple API to format, parse, and manipulate dates.”

Hot Module Replacement (HMR) is easy

bjornlu.com @bluwy@webtoo.ls

“If you’ve built projects with Vite, chances are you’ve also used Hot Module Replacement (HMR). HMR allows you to update your code without having to refresh the page, such as editing a component markup or adjusting styles, the changes are immediately reflected in the browser, which enables faster code interation and improved developer experience.”

“While HMR is also a feature in other bundlers like Webpack and Parcel, in this blog we’ll dig deeper into how it works in Vite specfically. Generally other bundlers should also work similarly.”

“To preface, HMR is not easy and certain topics may require some time to digest, but I hope to have piqued your interest!”

What do you think of this issue?

If you have any comments or feedback, just reply to this email!

This email was sent to you. You can unsubscribe from this list here or update your preferences.

Older messages

Unbundling npm; new JS runtime by Amazon; Vite 5.1; February TC39 meeting; ES stage 2.7; Web IDL for

Tuesday, February 13, 2024

We have 9 links for you - Stay up-to-date on JavaScript and tools WorkOS, the modern API for auth and user identity. workos.com Sponsor WorkOS enables B2B SaaS companies to accelerate enterprise

Deno in 2023; Turborepo 1.12; Promise.withResolvers; import attributes; Christopher “vjeux” Chedeau

Tuesday, February 6, 2024

WorkOS, the modern API for auth and user identity. workos.com Sponsor WorkOS enables B2B SaaS companies to accelerate enterprise adoption with identity management and complex features like Single Sign-

Deno 1.40; esbuild v0.20.0; ES proposal: explicit resource management; deprecated npm packages

Tuesday, January 30, 2024

WorkOS, the modern API for auth and user identity. workos.com Sponsor WorkOS enables B2B SaaS companies to accelerate enterprise adoption with identity management and complex features like Single Sign-

Npm 2023 retrospective; Prettier 3.2; Rspack 0.5; Bun v1.0.23; library for immutable updaes; Bun

Tuesday, January 23, 2024

npm in review: a 2023 retrospective on growth, security, and quirky facts socket.dev github.com/Planeshifter @SocketSecurity@fosstodon.org “It's a new year! So let's look back at how npm, the

JavaScript’s birthday; TC39 FAQ; ESLint v8.55.0; Bun v1.0.15; Socket CLI v0.9.0; Turborepo 1.11

Tuesday, December 12, 2023

Dear readers! We are taking our end-of-the-year break and will be back on 23 January 2024. Be well and see you soon! Axel and Jowe 28 years ago (1995-12-04): “Netscape and Sun announce JavaScript, the

You Might Also Like

🖤 Laravel Black Friday Deals!

Wednesday, November 27, 2024

The biggest deals of the year Laravel Black Friday Deals View in browser Laravel News Editor Note: We are sending this outside the regular Sunday newsletter schedule because some of these specials end

BetterDev #271 - Memory: The Forgotten History and Why did Windows 95 setup use three operating systems?

Wednesday, November 27, 2024

Better Dev #271 Nov 26, 2024 Hi all, Welcome to thanksgiving issue of BetterDev. Hope everyone had a safe and warm thanksgiving. It's getting so cold these days. If you are in warzone such as

Mapped | Unemployment Rate By U.S. State in 2024 💼

Tuesday, November 26, 2024

As of October 2024, DC and Nevada tied for the highest unemployment rate in the US at 5.7%. Which states saw the lowest rates? View Online | Subscribe | Download Our App FINAL CHANCE - ENDS TONIGHT!

🔊 7 DIY Tips for Soundproofing a Room — Why I Switched to Xfce for Linux Mint

Tuesday, November 26, 2024

Also: Home Theater Sound Terms Explained, and More! How-To Geek Logo November 26, 2024 Did You Know The shiny layer of a CD doesn't contain the data; the plastic polycarbonate layer does. The shiny

JSK Daily for Nov 26, 2024

Tuesday, November 26, 2024

JSK Daily for Nov 26, 2024 View this email in your browser A community curated daily e-mail of JavaScript news JavaScript Certification Black Friday Offer – Up to 54% Off! Certificates.dev, the trusted

NumPy, Loop Targets, Vector Animation, and More

Tuesday, November 26, 2024

NumPy Practical Examples: Useful Techniques #657 – NOVEMBER 26, 2024 VIEW IN BROWSER The PyCoder's Weekly Logo NumPy Practical Examples: Useful Techniques In this tutorial, you'll learn how to

Your Games Quarterly newsletter has arrived

Tuesday, November 26, 2024

What's new for games in Google Play and Android Email not displaying correctly? View it online November 2024 The First Developer Preview of Android 16 The First Developer Preview of Android 16

Daily Coding Problem: Problem #1620 [Hard]

Tuesday, November 26, 2024

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Dropbox. Sudoku is a puzzle where you're given a partially-filled 9 by 9 grid with

Final Hours: Help Save "The Art of Data" From Falling Short 🙏

Tuesday, November 26, 2024

Will Visual Capitalist end up revealing the secrets behind data storytelling? There are 12 hours left to change the fate of "The Art of Data". View Online | Subscribe | Download Our App Help

Spyglass Dispatch: Meta's Bluesky • Apple's China AI Problem • Apple's Chinese iPhone Problem • Perplexity Voice Pin • Susan's Message on Lung Cancer

Tuesday, November 26, 2024

Meta's Bluesky • Apple's China AI Problem • Apple's Chinese iPhone Problem • Perplexity Voice Pin • Susan's Message on Lung Cancer The Spyglass Dispatch is a free newsletter sent out