'Is the ddd() helper not working in Laravel 9?
I upgraded to Laravel 9 the other day, and now the ddd()
helper is failing with the error Call to undefined function ddd()
. I found this post on the Laracasts forum, but at time of writing there is only a single reply that states that the facade/ignition
was replaced with spatie/laravel-ignition
. I did not see anything in the documentation for the new package that mentions anything changing with ddd()
, is there an additional configuration or something that is needed to re-enable ddd()
?
Solution 1:[1]
In spatie/laravel-ignition
version 1.2.0, ddd()
was added back in! If you are not able to use ddd()
, first check your composer.json
file to make sure that your spatie/laravel-ignition
version is 1.2.0 or above.
"require-dev": {
"spatie/laravel-ignition": "^1.2.3"
}
Solution 2:[2]
Take a look at this https://github.com/facade/ignition/pull/201#event-2712168617
jasonvarga deleted the ddd branch 2 years ago
And you are right about not seeing any documentation about it in changelogs as well.
I heard this ddd()
helper for the first time from you, so thax for that.
Please do check out the documentation of both of the packages.
Here facade / ignition and spatie / laravel-ignition
Both packages saying the same thing that
spatie/laravel-ignition works for Laravel 8 and 9 applications running on PHP 8.0 and above. Looking for Ignition for Laravel 5.x, 6.x or 7.x or old PHP versions? facade/ignition is still compatible.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | NerdyGinger |
Solution 2 | Vipertecpro |