Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Single field sub form interface

See original GitHub issue

Issue Description

Intent: Allow for easy implementation of single value (no form group) custom components that implement value accessor interface. This would allow to create smart components like selects / autocompletes that load data themselves that can easily be reused across the application Think customer / user / country pickers or any commonly used domain specific pickers you can think of.

Issue today:

  • NgxSubFormComponent requires a complex type as generic parameter for class fields / methods to make sense formControlNames etc.
  • Its possible to use NgxSubFormRemapComponent to wrap the single value into a form group and back but it generates boilerplate that is redundant and feels unnecessary especially for new devs joining a project

Feature request: Create an additional interface that exposes the same functionality as NgxSubFormComponent or NgxSubFormRemapComponent but all methods / fields should be singular formControlName / formControlValue etc.



  • checkout the GenericLookupComponent
  • here you can see how the single value is wrapped / unwrapped

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

ntzioliscommented, Dec 19, 2019

Will do

ntzioliscommented, Feb 15, 2020

To better understand the use cases for single value sub forms and as mentioned in #139 we have also created an additional sub form type for arrays with array related helper functionality, sample can be found here

Read more comments on GitHub >

github_iconTop Results From Across the Web

Introduction to Subforms | Granicus Support
Subforms can pull in values from the main form. This only works in the subform fields all have unique data names compared to...
Read more >
Building a Subform - CRM - Zoho Cares
A subform is a secondary form or a table, which will enable you to include multiple line items into a primary form. Learn...
Read more >
Create a form that contains a subform (a one-to-many form)
Learn how to create a form in Access that contains a subform (also known as a one-to-many form, a parent/child form, or a...
Read more >
Defining the types of application forms - Infor Documentation
A single-record form will have at least one key field. ... A subform is an application form that you can access only by...
Read more >
The Best Way to build reactive sub-forms with Angular
Forms represent one of the most important parts of almost all frontend applications. From a single input field to a multi step wizards,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found