PHPackages                             peltonsolutions/laravel-pivot-table-helper - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. peltonsolutions/laravel-pivot-table-helper

ActiveLibrary[Database &amp; ORM](/categories/database)

peltonsolutions/laravel-pivot-table-helper
==========================================

A custom package for Laravel to assist with creating BelongsToMany pivot migrations.

0.2.0(2y ago)1109MITPHPPHP ^8.2

Since Feb 10Pushed 2y agoCompare

[ Source](https://github.com/peltonsolutions/laravel-pivot-table-helper)[ Packagist](https://packagist.org/packages/peltonsolutions/laravel-pivot-table-helper)[ Docs](https://github.com/peltonsolutions/laravel-pivot-table-helper)[ RSS](/packages/peltonsolutions-laravel-pivot-table-helper/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (3)Versions (5)Used By (0)

laravel-pivot-table-helper
==========================

[](#laravel-pivot-table-helper)

Description WIP

Things to add
-------------

[](#things-to-add)

- allow nullable relationships, when you have multiple
- add morphToMany
- add command to automatically create the migration file from a model/relationship
- If the target table already exists, update the table instead
- Add "down" generation, which determines if the target table only has the two column relationship or not. If it only has these two fields, it will drop the table. If it has more fields, it will remove the column for the relationship column.

Install
-------

[](#install)

You can install the package via composer using the following command:

```
composer require peltonsolutions/laravel-pivot-table-helper
```

Usage
-----

[](#usage)

```
