Answers for "creating a reusable table component in angular"

0

creating a reusable table component in angular

const tableConfig: DataTableType = {
  columns: [
    {title: "First Name", dataProperty: "firstName", sortable: true, filterable: false},
    {title: "Last Name", dataProperty: "lastName", sortable: true, filterable: true},
    {title: "Occupation", dataProperty: "occupation", sortable: false, filterable: false},
    {title: "Branch", dataProperty: "companyBranch", sortable: false, filterable: true},
  ],
  rowActions: [
    {label: "Edit", actionIdToReturn: "edit", logoImageUrl: "...", showOption: (x) => true },
    {label: "Copy", actionIdToReturn: "copy", logoImageUrl: "...", showOption: (x) => x.completed },
    {label: "Delete", actionIdToReturn: "delete", logoImageUrl: "...", showOption: (x) => !x.isActive },
    {label: "Message", actionIdToReturn: "message", logoImageUrl: "...", showOption: (x) => x.permitsMessaging },
  ],
  rowsPerPage: 20,
}
Posted by: Guest on March-04-2022

Code answers related to "creating a reusable table component in angular"

Code answers related to "Javascript"

Browse Popular Code Answers by Language