github refinedev/refine @refinedev/react-table@5.1.0

Minor Changes

  • Thanks @aliemir, @alicanerdurmaz, @batuhanW, @salihozdemir, @yildirayunlu, @recepkutuk!
    All @tanstack/react-table imports re-exported from @refinedev/react-table have been removed. You should import them from the @tanstack/react-table package directly.

    If the package is not installed, you can install it with your package manager:

    npm install @tanstack/react-table
    # or
    pnpm add @tanstack/react-table
    # or
    yarn add @tanstack/react-table

    After that, you can import them from @tanstack/react-table package directly.

    - import { useTable, ColumnDef, flexRender } from "@refinedev/react-table";
    
    + import { useTable } from "@refinedev/react-table";
    + import { ColumnDef, flexRender } from "@tanstack/react-table";
  • Thanks @aliemir, @alicanerdurmaz, @batuhanW, @salihozdemir, @yildirayunlu, @recepkutuk!
    useTable return values and properties are updated.

    • initialCurrent and initialPageSize props are now deprecated. Use pagination prop instead.

    • To ensure backward compatibility, initialCurrent and initialPageSize props will work as before.

      useTable({
      -    initialCurrent,
      -    initialPageSize,
      +    pagination: {
      +        current,
      +        pageSize,
      +    },
      })
    • hasPagination prop is now deprecated. Use pagination.mode instead.

    • To ensure backward compatibility, hasPagination prop will work as before.

      useTable({
          refineCoreProps: {
      -      hasPagination,
      +       pagination: {
      +           mode: "off" | "server" | "client",
      +       },
          },
      })
    • initialSorter and permanentSorter props are now deprecated. Use sorters.initial and sorters.permanent instead.

    • To ensure backward compatibility, initialSorter and permanentSorter props will work as before.

      useTable({
          refineCoreProps: {
      -      initialSorter,
      -      permanentSorter,
      +      sorters: {
      +          initial,
      +          permanent,
      +      },
          },
      })
    • initialFilter, permanentFilter, and defaultSetFilterBehavior props are now deprecated. Use filters.initial, filters.permanent, and filters.defaultBehavior instead.

    • To ensure backward compatibility, initialFilter, permanentFilter, and defaultSetFilterBehavior props will work as before.

      useTable({
          refineCoreProps: {
      -      initialFilter,
      -      permanentFilter,
      -      defaultSetFilterBehavior,
      +      filters: {
      +          initial,
      +          permanent,
      +          defaultBehavior,
      +      },
          },
      })
    • sorter and setSorter return values are now deprecated. Use sorters and setSorters instead.

    • To ensure backward compatibility, sorter and setSorter return values will work as before.

      const {
          refineCore: {
      -        sorter,
      -        setSorter,
      +        sorters,
      +        setSorters,
          },
      } = useTable();
  • Thanks @aliemir, @alicanerdurmaz, @batuhanW, @salihozdemir, @yildirayunlu, @recepkutuk!
    Moving to the @refinedev scope 🎉🎉

    Moved to the @refinedev scope and updated our packages to use the new scope. From now on, all packages will be published under the @refinedev scope with their new names.

    Now, we're also removing the refine prefix from all packages. So, the @pankod/refine-core package is now @refinedev/core, @pankod/refine-antd is now @refinedev/antd, and so on.

Patch Changes

Don't miss a new refine release

NewReleases is sending notifications on new releases.