I developped a package, and when it comes to render normal views, it works just fine, but now that I want to render Full Page Livewire components, I get a “view not found message” any idea why ?
For example for a show-tickets view:
web.php:
Route::get('tickets/list', ShowTickets::class);
ServiceProvider:
public function boot()
{
$this->loadMigrationsFrom(__DIR__ . "/database/migrations");
$this->loadRoutesFrom(__DIR__ . "/routes/web.php");
$this->loadViewsFrom(__DIR__ .'/resources/views', "Tickets");
Livewire::component('show-tickets', ShowTickets::class);
}
ShowTickets.php :
<?php
namespace UHGroupTicketsAppLivewire;
use LivewireComponent;
use UHGroupTicketsAppModelsTicket;
class ShowTickets extends Component
{
public function mount()
{
$this->ticket = Ticket::where("archived_at", !null);
}
public function render()
{
$tickets = Ticket::all();
return view('Tickets::livewire.show-tickets', compact('tickets'));
}
}
and I’m getting the following error :
View [livewire.show-tickets] not found.
Although I do have a show-tickets.blade.php file in a livewire folder in my views folder….