Replace preserveQueryParams with queryParamsHandling

Proprietary

Rewrites preserveQueryParams: true in navigate() and createUrlTree() navigation extras to queryParamsHandling: 'preserve', and drops the option when it holds any other value, which is what false already meant. Angular 11 removed preserveQueryParams. Matches the migration-v11-router-preserve-query-params schematic.

org.openrewrite.angular.migration.replace-preserve-query-params
mod run . --recipe=org.openrewrite.angular.migration.replace-preserve-query-params

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.