Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 15 additions & 14 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
{
"image": "mcr.microsoft.com/devcontainers/php:8.2",
"forwardPorts": [
8000,
5173,
9000,
9003
],
"remoteEnv": {
"COMPOSER_MEMORY_LIMIT": "-1",
"COMPOSER_PROCESS_TIMEOUT": "0"
},
"features": {
"ghcr.io/devcontainers/features/node:1": {}
}
"image": "mcr.microsoft.com/devcontainers/php:8.3",
"forwardPorts": [
8000,
5173,
9000,
9003
],
"remoteEnv": {
"COMPOSER_MEMORY_LIMIT": "-1",
"COMPOSER_PROCESS_TIMEOUT": "0",
"PHPUNIT_TELEMETRY": "off"
},
"features": {
"ghcr.io/devcontainers/features/node:1": {}
}
}
40 changes: 32 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,16 @@
<img alt="fabricator banner" src="https://raw.githubusercontent.com/z3d0x/filament-fabricator/2.x/art/banner.jpg" />
</p>

***What is Filament Fabricator?*** Filament Fabricator is simply said a block-based page builder skeleton. Filament Fabricator takes care of the PageResource & frontend routing, so you can focus on what really matters: your [Layouts](https://filamentphp.com/plugins/z3d0x-fabricator#layouts) & [Page Blocks](https://filamentphp.com/plugins/z3d0x-fabricator#page-blocks).
**_What is Filament Fabricator?_** Filament Fabricator is simply said a block-based page builder skeleton. Filament Fabricator takes care of the PageResource & frontend routing, so you can focus on what really matters: your [Layouts](https://filamentphp.com/plugins/z3d0x-fabricator#layouts) & [Page Blocks](https://filamentphp.com/plugins/z3d0x-fabricator#page-blocks).

## Compatibility
| Fabricator | Filament | PHP |
|------|----------|--------|
| [1.x](https://github.com/z3d0x/filament-fabricator/tree/1.x) | ^2.0 | ^8.0 |
| [2.x](https://github.com/z3d0x/filament-fabricator/tree/2.x) | ^3.0 | ^8.1 |
| [3.x](https://github.com/z3d0x/filament-fabricator/tree/3.x) | ^4.0 | ^8.2 |

| Fabricator | Filament | PHP |
| ------------------------------------------------------------ | -------- | ---- |
| [1.x](https://github.com/z3d0x/filament-fabricator/tree/1.x) | ^2.0 | ^8.0 |
| [2.x](https://github.com/z3d0x/filament-fabricator/tree/2.x) | ^3.0 | ^8.1 |
| [3.x](https://github.com/z3d0x/filament-fabricator/tree/3.x) | ^4.0 | ^8.2 |
| [4.x](https://github.com/z3d0x/filament-fabricator/tree/4.x) | ^5.0 | ^8.3 |

## Installation

Expand All @@ -24,8 +26,8 @@ You can install the package via composer:
composer require z3d0x/filament-fabricator
```


After that run the install command:

```bash
php artisan filament-fabricator:install
```
Expand Down Expand Up @@ -65,20 +67,42 @@ Documentation can be viewed at: https://filamentphp.com/plugins/z3d0x-fabricator

## Migrate

### From 3.x to 4.x

- Relies on PHP 8.3 as the minimum version

### From 2.x to 3.x

- There is no longer a default value for the `pages.layout` database column
- `FilamentFabricatorManager#getPageUrlFromId` no longer has a `prefixSlash` parameter
- Relies on PHP 8.2 as the minimum version

### From Filament v4 to Filament v5

Following [the upgrade guide from Filament](https://filamentphp.com/docs/5.x/upgrade-guide) should be enough.

In case it isn't, you can run the following commands:

```bash
composer require filament/upgrade:"^5.0" -W --dev

./vendor/bin/filament-v5

# Run the commands output by the upgrade script, they are unique to your app
composer require filament/filament:"^5.0" z3d0x/filament-fabricator:"^5.0" -W --no-update
composer update
```

### From Filament v3 to Filament v4

Following [the upgrade guide from Filament](https://filamentphp.com/docs/4.x/upgrade-guide) should be enough.

In case it isn't, you can run the following commands:

```bash
composer require filament/upgrade:"^4.0" -W --dev

vendor/bin/filament-v4
./vendor/bin/filament-v4

# Run the commands output by the upgrade script, they are unique to your app
composer require filament/filament:"^4.0" z3d0x/filament-fabricator:"^4.0" -W --no-update
Expand Down
15 changes: 8 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,23 @@
}
],
"require": {
"php": "^8.2",
"filament/filament": "^4.0",
"php": "^8.3",
"filament/filament": "^5.0",
"illuminate/contracts": "^11.0 | ^12.0",
"pboivin/filament-peek": "^3.0",
"livewire/livewire": "^4.0",
"pboivin/filament-peek": "^4.0",
"spatie/laravel-package-tools": "^1.13.5"
},
"require-dev": {
"driftingly/rector-laravel": "^2.0",
"filament/upgrade": "^4.0",
"filament/upgrade": "^5.0",
"larastan/larastan": "^2.9 | ^3.7",
"laravel/pint": "^1.24",
"nunomaduro/collision": "^8.0",
"orchestra/testbench": "^10.0",
"pestphp/pest": "^3.0",
"pestphp/pest-plugin-laravel": "^3.1",
"pestphp/pest-plugin-livewire": "^3.0",
"pestphp/pest": "^4.0",
"pestphp/pest-plugin-laravel": "^4.0",
"pestphp/pest-plugin-livewire": "^4.0",
"phpstan/phpstan-deprecation-rules": "^2.0",
"phpstan/phpstan-phpunit": "^2.0",
"rector/rector": "^2.1",
Expand Down
1 change: 1 addition & 0 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
>
<php>
<env name="APP_KEY" value="base64:+1JX1LrX2QMk/Gaxv5r89uiy9JWOMKSKhUlwVrJL1A8="/>
<env name="PHPUNIT_TELEMETRY" value="off"/>
</php>
<source ignoreIndirectDeprecations="true" restrictNotices="true" restrictWarnings="true">
<include>
Expand Down
2 changes: 1 addition & 1 deletion tests/Commands/ClearRoutesCacheCommand.test.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

describe(ClearRoutesCacheCommand::class, function () {
beforeEach(function () {
Config::set('filament-fabricator.routing.prefix', null);
Config::set('filament-fabricator.routing.prefix');
});

it('can be resolved through the container', function () {
Expand Down