Skip to content

feat(formly): add formly-next entry point with ngx-formly v7 support#1771

Open
chintankavathia wants to merge 1 commit intomainfrom
feat/formly/v7
Open

feat(formly): add formly-next entry point with ngx-formly v7 support#1771
chintankavathia wants to merge 1 commit intomainfrom
feat/formly/v7

Conversation

@chintankavathia
Copy link
Copy Markdown
Member

@chintankavathia chintankavathia commented Mar 27, 2026

Introduce @siemens/element-ng/formly-next as a separate secondary entry point supporting @ngx-formly/core v7. This enables standalone component usage without NgModules, improved tree-shaking through provider-based configuration, and alignment with modern Angular patterns.

The existing @siemens/element-ng/formly entry point remains v6-compatible. Both SiFormlyComponent and SiFormlyModule are marked as deprecated with guidance to migrate to SiFormlyNextComponent when upgrading to v7.

Before (v6 — @siemens/element-ng/formly):

  import { SiFormlyModule } from '@siemens/element-ng/formly';

  @NgModule({
    imports: [SiFormlyModule.forRoot()]
  })
  export class AppModule {}

After (v7 — @siemens/element-ng/formly-next):

  import { SiFormlyNextComponent } from '@siemens/element-ng/formly-next';

  @Component({
    imports: [SiFormlyNextComponent]
  })
  export class MyComponent {}

Documentation.
Examples.
Dashboards Demo.
Playwright report.

Coverage Reports:

Code Coverage

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request upgrades @ngx-formly to version 7 and introduces SiFormlyNextComponent as the new component for this version, while deprecating the existing SiFormlyComponent and SiFormlyModule. The application configuration and examples have been updated to use the new component and the provideFormlyCore provider. Feedback includes a request to apply ChangeDetectionStrategy.OnPush to the new component per the style guide and to remove a redundant commented-out import in the app configuration.

@chintankavathia chintankavathia force-pushed the feat/formly/v7 branch 5 times, most recently from 56f7066 to 71acaa1 Compare March 27, 2026 13:21
@chintankavathia chintankavathia marked this pull request as ready for review March 27, 2026 13:43
@chintankavathia chintankavathia requested review from a team as code owners March 27, 2026 13:43
Copy link
Copy Markdown
Member

@spike-rabbit spike-rabbit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am a little divided here:
Can we wait until v50 an then just fully update to formly@7?

Or this there a way, where we can still have the same 6 and 7 with the exact same entry point and code?

Introduce `@siemens/element-ng/formly-next` as a separate secondary entry
point supporting `@ngx-formly/core` v7. This enables standalone component
usage without NgModules, improved tree-shaking through provider-based
configuration, and alignment with modern Angular patterns.

The existing `@siemens/element-ng/formly` entry point remains v6-compatible.

Before (v6 — `@siemens/element-ng/formly`):

```ts
  import { SiFormlyModule } from '@siemens/element-ng/formly';

  @NgModule({
    imports: [SiFormlyModule.forRoot()]
  })
  export class AppModule {}

```

After (v7 — `@siemens/element-ng/formly-next`):

```ts
  import { SiFormlyNextComponent } from '@siemens/element-ng/formly-next';

  @component({
    imports: [SiFormlyNextComponent]
  })
  export class MyComponent {}
```
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.

3 participants