mirror of
https://github.com/wearepixel/laravel-cart.git
synced 2026-11-14 22:01:48 +00:00
feat: finish tests & docs
This commit is contained in:
@@ -300,10 +300,20 @@ #### Check if cart is empty: **Cart::isEmpty()**
|
||||
|
||||
#### Clearing the Cart: **Cart::clear()**
|
||||
|
||||
This clears all items and conditions from the cart.
|
||||
|
||||
```php
|
||||
Cart::clear();
|
||||
```
|
||||
|
||||
#### Clearing the cart items only: **Cart::clearItems()**
|
||||
|
||||
This clears all items, but keeps the conditions (useful for when you want to keep the conditions but remove the items)
|
||||
|
||||
```php
|
||||
Cart::clearItems();
|
||||
```
|
||||
|
||||
### Conditions
|
||||
|
||||
Conditions are very useful for adding things like discounts, taxes, shipping, etc.
|
||||
|
||||
Reference in New Issue
Block a user