alepha@docs:~/docs/.content/release/framework/docs/reference/primitives$
cat $settingsSection.md | pretty1 min read
#$settingsSection
#Import
typescript
1import { $settingsSection } from "@alepha/ui/settings";
#Overview
Add a section to a settings dialog, from any class: the dialog is named by
the value $settingsDialog returned, the way $pageNav takes a parent.
A section is not a page. No route is registered and there is no loader:
the component fetches its own data with useQuery when it is shown.
groupandorderplace it in the nav: sections sort byorderinside their group, and groups by their smallest member.canhides it, from the nav and fromopenalike.
ts
1class Billing { 2 protected readonly account = $inject(AccountSettings); 3 protected readonly api = $client<InvoiceController>(); 4 5 invoices = $settingsSection({ 6 dialog: this.account.dialog, 7 name: "invoices", 8 label: "Invoices", 9 group: "Billing",10 order: 100,11 can: () => this.api.listMyInvoices.can(),12 lazy: () => import("./MyInvoices.tsx"),13 });14}