Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Error Solutions Laravel Package

spatie/laravel-error-solutions

Shows helpful, actionable “solutions” directly on Laravel’s error page, explaining likely causes and fixes. Some solutions are runnable with one click (e.g., generate APP_KEY), speeding up debugging during local development.

View on GitHub
Deep Wiki
Context7

title: Creating a solution class weight: 2

A solution is a simple PHP class that implements the Spatie\ErrorSolutions\Contracts\Solution interface.

Here's a simple example.

class MySolution implements Solution
{
    public function getSolutionTitle(): string
    {
        return 'My custom solution';
    }

    public function getSolutionDescription(): string
    {
        return 'My custom solution description';
    }

    public function getDocumentationLinks(): array
    {
        return [
            'Spatie docs' => 'https://spatie.be/docs',
        ];
    }
}

Optionally, you can add "provided by" information to a solution by implementing the methods.

// in your solution class

public function solutionProvidedByName(): string
{
    return 'Flare';
}

public function solutionProvidedByLink(): string
{
    return 'https://flareapp.io';
}
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport