DEV Community

Remon Hasan
Remon Hasan

Posted on • Edited on

2

Shopping Cart Laravel 8: Part 02

Source Code

Github

Component Create

Create your own component for cart,product details and shop.
Then create a store function in shopcomponent.php as like:

Alt Text

pass the parameters to the product page as like by adding:

wire:click.prevent="store({{$product->id}},'{{$product->name}}',{{$product->regular_price}})"

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

Best practices for optimal infrastructure performance with Magento

Running a Magento store? Struggling with performance bottlenecks? Join us and get actionable insights and real-world strategies to keep your store fast and reliable.

Tune in to the full event

DEV is partnering to bring live events to the community. Join us or dismiss this billboard if you're not interested. ❤️