02. Passing Parameters
The Problem
A parent screen may need to open a reusable component with a customer ID, invoice ID, or other business context.
The Angular Difficulty
Angular uses `@Input()` bindings for component inputs. The developer defines the input contract and binds values through Angular template syntax.
Angular Approach
@Component({
selector: "app-customer",
template: "Customer {{ customerId }} — {{ mode }}"
})
export class CustomerComponent {
@Input() customerId!: number;
@Input() mode = "view";
}
// parent template
<app-customer [customerId]="1001" mode="edit" />
MS Approach
ManySet provides a direct runtime-oriented approach for this recurring business-application task.
const customer = await ms.inject(
"./Customers/Customer",
"content",
{ customerId: 1001, mode: "edit" }
);
Why this way is useful in business applications :
The comparison is intended to show where ManySet supplies a business-application abstraction around a recurring task, while keeping HTML and JavaScript visible and directly usable.
Key Point :
ManySet reduces the amount of framework-specific composition required for this particular task, without requiring the React/Angular mechanism to be represented as inherently wrong or incapable.