Skip to content

feat: Support @softarc/native-federation 4.11 - #214

Merged
Aukevanoost merged 1 commit into
mainfrom
feat/core-4.11
Nov 27, 2026
Merged

Aukevanoost merged 1 commit into
mainfrom
feat/core-4.11

Conversation

@Aukevanoost

Copy link
Copy Markdown
Contributor

Brings the adapter in line with core v4.11.0.

Changes

  • @softarc/native-federation ~4.10.0 → ~4.11.0.
  • fromPackageJson() takes an optional base config. Without one, core shares every dependency with singleton, strictVersion, requiredVersion: 'auto' and build: 'package' (native-federation-core#254). The Angular skip list is still applied.
  • autoShareScope resolves projectPath with core's inferProjectPath (native-federation-core#256), so a relative path is read against workspaceRoot. Without one it starts from the packageJson folder or workspaceRoot instead of the working directory.
  • The init schematic and the README example use fromPackageJson().patch(['@angular/*'], { includeSecondaries: { keepAll: true } }).

Compatibility

autoShareScope() builds started from a folder other than the workspace root now read a different package.json. Core's own 4.11 changes reach users through the adapter too: an override no longer drops packages whose name starts with its key (native-federation-core#259), and catalog:/workspace: dependencies publish a ~ range on the installed version (native-federation-core#257).

Verification

pnpm test (502 passed), pnpm typecheck, pnpm lint (no errors), pnpm build.

- fromPackageJson() takes an optional base config, so it falls back to
  core's strict-singleton, build: 'package' default
- autoShareScope resolves projectPath with core's inferProjectPath, against
  workspaceRoot instead of the working directory
- The init schematic generates fromPackageJson().patch(...)
@Aukevanoost
Aukevanoost merged commit 3dcb03c into main Nov 27, 2026
1 check passed
Aukevanoost added a commit that referenced this pull request Nov 27, 2026
Backports 22.2.5..22.3.0 onto the Angular 21 layout.

Incoming:
- #214: @softarc/native-federation ~4.11.0; fromPackageJson() takes an
  optional base config and autoShareScope resolves projectPath against
  workspaceRoot.
- #171/#213: rewriteModulePreloads (./ssr export) for native import maps.
- #209: ngServerMode is set in exposed-module bundles.
- #210: the prod node preload no longer passes hostInstances.
- #215: NodePackageInstallTask comes from @angular-devkit/schematics/tasks.
- Tag-triggered release workflow (staged npm publish).

Angular 21 specific adaptations:
- Left out the Angular 22.3 bump: kept the -v4 name, 21.2.18 version and
  ng21 pins; bumped @softarc/native-federation to 4.11 by hand.
- Kept the `// upstream:` tags at v21.2.19 (1a728258d6) and the 21.2
  debugOptimize note.
- Dropped the remote builder, share-utils.spec.ts and
  tools/esbuild/sourcemap-ignorelist-plugin.ts as before.
- @angular/ssr 21.2 emits the same modulepreload markup as 22, so
  rewriteModulePreloads applies unchanged.
- follow-redirects@1 override raised to ^1.16.2 for a high advisory.
- pnpm-lock.yaml regenerated rather than merged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant