Blog
Zack DeRose
September 20, 2024

Nx 19.8 Update!!

Nx 19.8 is here! This is our last minor release before we get ready to move ahead into Nx v20, which should land in October around the same time as the Monorepo World Conference!

As always, you can find the general details for all Nx releases on our changelog, as well as details on our Github Releases for the Nx repo.

Table of Contents

In this blog post:

Nx Import

In Nx 19.8, nx import has now moved from beta support to now generally available!

Nx Import is a new top-level command of the Nx CLI which allows you to import projects along with its git history from some other repository into your current Nx workspace.

Keep an eye out for more on Nx Import on our YouTube Channel coming soon, and in the meantime be sure to check the documentation as this is now fully documented!

Improved Task Scheduling!

We've added some optimizations to the core of Nx - particularly around Nx's task scheduling. At the core of Nx is a task runner that supports task dependencies (configurable for your entire workspace in the targetDefaults of your nx.json file, and on a per-project basis in your project.json files!), as well as the ability to run mulitple tasks in parallel.

With 19.8, nx will leverage historical data of previous runs of tasks to add some prioritization to the scheduling tasks that tend to take longer. This should optimize the total runtime of large batch commands in your workspace!

Read more on running tasks with Nx! And checkout this new optimization on GitHub for more details!

Project Crystal Comes to Angular

Project Crystal has come to Angular!

Project Crystal allows Nx to infer tasks for projects in your workspace - rather than requiring that they exist in every project.json or angular.json file of your workspace.

You can now run the command nx init in a project created by the Angular CLI, and we will generate project.json files for each angular project in your workspace - splitting that data out from the root angular.json file created by the Angular CLI.

This decision was made based on our feedback from the Angular community - where there is a strong preference for being able to split out the config.

Crystalize Your Entire Workspace In One Command

When we initially launched Project Crystal, we shipped originally with convert-to-inferred generators, which would allow you to convert your workspace one plugin at a time.

With Nx 19.8, we've added a infer-targets generator, which will automatically detect all available convert-to-inferred generators, and run the ones you choose. You may also specify a specific project using the --project option of the generator.

New Nx Workspaces Created with ESLint v9

When creating a new workspace with the command: npx create-nx-workspace, those workspaces will now be created with eslint v9, and typescript-eslint v8 - their most recent versions respectively.

Keep in mind as well that ESLint v8 faces end-of-life on October 5th, meaning only flat config is supported moving forward. Nx users should migrate to this new config format using our flat config generator.

For more on eslint's flat config, and how to use our generator to get to flat config checkout this video:

Nx Release Enhancements

nx release is a framework/language/platform agnostic solution to versioning, publishing, and changelogs for your monorepo. We've been continuing to invest in Nx Release in 19.8, adding support specifically for pnpm publish and Github Enterprise Server!

We also have a new feature from Nx Champion, Jonathan Gelin - which allows you to use groupPreVersionCommand in addition to the preVersionCommand when using the release groups feature to support building before versioning.

Migrate to Latest

As always - updating Nx and its plugins is easy as we ship an automated migration command.

npx nx migrate latest

After updating your dependencies, run any necessary migrations.

npx nx migrate --run-migrations

Round 2 of Monorepo World Conference Speakers Announced!!

Monorepo World

The Monorepo World conference is coming up soon on October 7, 2024 at the Computer History museum in Mountain View, California.

Get your tickets now, consider requesting access to the invite-only Enterprise Summit on October 8, and be sure to check out the second round of speakers that was just published earlier this week!

Learn more