Custom Columns

UI Components for Vue
Post Reply
cdl_engineering
Posts: 4
Joined: 16 Jul 2021, 17:04

17 Nov 2021, 23:31

Hey, I would like a to make custom columns for a project I'm working on. From looking at the code, columns are just a model for the DataTable to use. I wanted to start simple and work to more complex columns. The challenge I'm having is with the columns slots and Vue3. I wanted to create a DateColumn where the value will always render a certain date format when used. So I would like to hijack the body slot. Though because Columns is more a renderless component, I can't just add a slot. So I was wondering how can I achieve my goal of having a default slot provided? I eventually want to make more (ie: LinkColumn, etc)

tugce.kucukoglu
Posts: 560
Joined: 23 Oct 2020, 09:28

24 Nov 2021, 14:05

Hi,

DataTable requires at least one Column component and a value set, do not render any slot even default slot. For now we strongly recommend using this approach.

Post Reply

Return to “PrimeVue”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 6 guests