Skip to content

ThemeServiceProvider not found #98

@thewebartisan7

Description

@thewebartisan7

I follow installation guide, which is:

  1. laravel new themes // installed laravel
  2. composer require caffeinated/themes // installed package
  3. php artisan make:theme Bootstrap // created theme

Now works fine if I try to load view, for example bootstrap::welcome

But routes are not loaded, so I added service provider to config/app.php

  1. Themes\Bootstrap\Providers\ThemeServiceProvider::class

And now I get error Class 'Themes\Bootstrap\Providers\ThemeServiceProvider' not found

So I update main composer.json adding PSR-4 for "themes" folder, this:

"autoload": {
        "psr-4": {
            "App\\": "app/",
            "Themes\\": "themes/"
        }
    },

And now works fine...

But there is nothing regarding this step in docs, and I think that command for make theme already update composer...

What am I missing?

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions