<?php

use App\Models\Carousel;
use App\Models\Category;
use App\Models\Product;
use Livewire\Attributes\Layout;
use Livewire\Component;

return new class extends Component
{
    //use App\Concerns\WishListTrait;
    public $slides;
    #[Layout('layouts.store')]
    public function with()
    {
        return [
            'products' => Product::get(),
            'categories' => Category::get(),
            'carousels' => Carousel::get()
        ];
    }

    public function mount(){
        $this->slides = Carousel::where('is_active', true)->get();
    }

    

    protected function view($data = [])
    {
        return app('view')->file('C:\laragon\www\ecommerce\storage\framework/views/livewire/views/b9056dfa.blade.php', $data);
    }

    public function scriptModuleSrc()
    {
        return 'C:\laragon\www\ecommerce\storage\framework/views/livewire/scripts/b9056dfa.js';
    }
};
