Logo Beartropy Tables

Beartropy Tables

Installation
Get started with Beartropy Tables.

Install via Composer

Run this in your Laravel project:

The Tables package uses the UI package as dependency, so you don't need to install it separately.

1composer require beartropy/tables

Advanced Setup

You may want to let the user save the table arrange of columns. If so, publish the migrations and run them.

1php artisan vendor:publish --provider="Beartropy\\Tables\\YATProvider" --tag="migrations"
2 
3php artisan migrate

Optionals

You may want to publish the lang settings and change all the keys. Up to you.

1php artisan vendor:publish --provider="Beartropy\\Tables\\YATProvider" --tag="lang"

Tailwind setup

Add Beartropy Tables to your tailwind.config.js:

The Tables package uses the UI package as dependency, if you dont use Beartropy UI you will need to add it to the tailwind config.

1// tailwind.config.js
2export default {
3 presets: [
4 //beartropy preset
5 require('./vendor/beartropy/ui/tailwind.config.js'),
6 ],
7 // ...
8 content: [
9 './vendor/beartropy/tables/src/resources/views/**/*.php',
10 // ...beartropy assets
11 './vendor/beartropy/ui/resources/views/**/*.php',
12 './vendor/beartropy/ui/src/Components/**/*.php',
13 ],
14 darkMode: 'class',
15 // ...
16};

Tailwind v4 Setup

If you are using Tailwind CSS v4, use the CSS based configuration in resources/css/app.css:

1@import "tailwindcss";
2 
3@config "../../vendor/beartropy/ui/tailwind.config.js";
4 
5@source "../../vendor/beartropy/tables/src/resources/views";
6@source "../../vendor/beartropy/ui/resources/views";
7@source "../../vendor/beartropy/ui/src/Components";