Composer create-project prefer-dist laravel/laravel “project” composer require livewire/ livewire



Download 2,75 Mb.
Sana07.04.2022
Hajmi2,75 Mb.
#535646
Bog'liq
Laravel


#1 Project & Layout Setup

  1. composer create-project --prefer-dist laravel/laravel “project”

  2. composer require livewire/ livewire

  3. views> create folder “layouts” and in layouts> create file base.blade.php

  4. index.html copy vse kod vstavit v base.blade.php and class main container virezat vstavit kod {{$slot}}

  5. php artisan make:livewire HomeComponent

  6. in HomeComponent.php write cod return view('livewire.home-component')->layout('layouts.base');

  7. in home-component.blade.php paste code in index.html container main

  8. in base.blade.php teginin joqarisina write @livewireStyles, in base.blade.php teginin joqarisina write @livewireScripts

  9. in web.php write code “Route::get('/',HomeComponent::class);” and “use App\Http\Livewire\HomeComponent;”

  10. php artisan serve and 127.0.0.1:8000



#2 Create Shop, Cart And Checkout Page





  1. php artisan make:livewire ShopComponent

  2. php artisan make:livewire CartComponent

  3. php artisan make:livewire CheckoutComponent

  4. in web.php

  5. shop.html copy to paste viewa>livewire in shop-component

  6. cart.html copy to paste viewa>livewire in cart-component

  7. checkout.html copy to paste viewa>livewire in checkout -component

  8. php artisan serve and 127.0.0.1:8000



#3 Admin and User Authentication



  1. composer require laravel/Jetstream

  2. php artisan jetstream:install livewire

  3. database>migrations>create_users_table $table->string('utype')->default('USR')->comment("ADM for admin and USR for Useror Customer");

  4. php artisan migrate

  5. 5:22
























Download 2,75 Mb.

Do'stlaringiz bilan baham:




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish