Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Cart Laravel Package

joelwmale/laravel-cart

A simple shopping cart package for Laravel with support for multiple cart instances, quantities, prices, taxes, discounts, and persistent storage. Offers an easy API for adding, updating, and removing items, calculating totals, and managing carts across sessions.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Cart reliability and checkout conversion. The new removeInvalidItems() cleanup runs on every cart session load, automatically stripping items missing id, name, or quantity. This is a defensive-data-integrity feature that reduces cart-state bugs reaching checkout — a direct lever on conversion and support-ticket volume.
  • Platform upgrade planning (roadmap-level, time-sensitive). v2.0.0 drops Laravel 10 and PHP 8.2, requiring PHP 8.3+ and Laravel ^11.0|^12.0|^13.0. Any product surface still on Laravel 10 must be scheduled for upgrade before this package can be adopted or upgraded.
  • Build vs. buy on cart/checkout plumbing. A maintained cart package with session-level validation means engineering does not build bespoke cart-hygiene logic; PM can allocate that capacity to differentiated checkout UX instead.
  • Support-cost modeling. Automatic invalid-item stripping should reduce "my cart is broken/empty/wrong" incidents. Worth instrumenting before/after to validate the assumption rather than treating it as guaranteed.
  • Risk decision: silent data loss. Because cleanup is automatic and unconditional on session load, a real product decision is needed on whether silently dropping items is acceptable, or whether it should be logged, surfaced to the user ("an item is no longer available"), or gated behind config. This is a UX and trust question, not just a technical one.
  • Use cases supported: single-merchant storefronts, session-backed carts, lightweight commerce inside an existing Laravel app, MVPs and internal ordering tools.

When to Consider This Package

Adopt when:

  • The application is on Laravel 11, 12, or 13 and PHP 8.3+ (or will be within the current planning cycle). Confirm this before committing — v2.0.0 is a hard cut.
  • The cart model is genuinely simple: line items with id, name, quantity, session persistence, single currency, no complex entitlement or bundle logic.
  • You want fast time-to-market on cart mechanics and are comfortable with a package owning that state.
  • You can accept an opinionated default of stripping malformed items, or you have a plan to wrap/log that behavior.

Look elsewhere when:

  • Still on Laravel 10 or PHP 8.2 and an upgrade is not funded — stay on the prior major or pick an alternative; do not adopt v2.0.0.
  • You need multi-warehouse inventory, promotions engines, subscriptions, tax calculation, or multi-currency — these are outside scope and will require surrounding systems regardless.
  • Silent removal of items is unacceptable without an audit trail or user-facing notice; verify whether the cleanup is configurable or observable before committing.
  • You require a vendor with an SLA or commercial support contract.

How to Pitch It (Stakeholders)

For executives: This release keeps our cart layer on currently supported PHP and Laravel versions and adds automatic cleanup of corrupted cart entries. The business value is fewer broken carts at checkout and fewer support tickets — both conversion-protective. The cost is a mandatory platform upgrade: Laravel 10 and PHP 8.2 are no longer supported, so adopting v2.0.0 requires us to be on Laravel 11+ and PHP 8.3+. That upgrade should be treated as a scheduled dependency of adoption, not an afterthought.

For engineering: v2.0.0 is a breaking release. Minimum PHP moves 8.2 → 8.3; framework support moves to Laravel ^11.0|^12.0|^13.0, dropping Laravel 10; CI now covers PHP 8.3, 8.4, 8.5. New removeInvalidItems() runs on every cart session load and drops items lacking id, name, or quantity. Two asks before we ship: (1) confirm our PHP/Laravel versions and upgrade path, and (2) confirm whether that cleanup is logged or configurable — we want visibility into silently dropped items so we can decide if a user-facing message is warranted.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
ably/pubsub-server
mstfkhazaal/defender
mfonte/base62x
karnoweb/metapilot
tobya/bcsapiwrapper
swalker2/cpanel
vish4395/laravel-translation-manager
morningtrain/economic
teksite/systeminfo-laravel
atomcms/voting
run6/weather
siokas/laravelembeddirectives
adamlien/pkuuids
gilsonsouza/lara-doc-generator
manelgavalda/enrollment_mobile
unabomber/timezone
delatbabel/contacts
astritzeqiri/g-recaptcha
kevinongko/laravel-genode
developeruz/laravel-analytics