Closed chiarotto closed 3 weeks ago
Although the string passed (tableStyle="min-width: 50rem"
) works in dev mode but when we build for production it gives error.
tableStyle requires object or undefined as the error says.
I changed it to :tableStyle="{'min-width': '50rem'}"
and this works.
As of v4.1.1, the new Tailwind styles have been rewritten using the preprocessor approach with @apply instead of pass-through. As a result this issue is not relevant any more.
New Website is live.
Running
> vue-tsc --build --force
I get the following:error TS2322: Type 'string' is not assignable to type 'object'.
34 tableStyle="min-width: 50rem">
The expected type comes from property 'tableStyle' which is declared here on type 'DataTableProps & VNodeProps & AllowedComponentProps & ComponentCustomProps & Record<string, unknown>'
But in the docs,( https://tailwind.primevue.org/datatable/ ) the example reports:
DataTable :value="products" tableStyle="min-width: 50rem"