Skip to content

Session bug when starting on a PDP and adding to cart #80

@kamui

Description

@kamui

Hey, we're working on implementing Vendure and we started using this remix storefront to get started. In our case, we started with porting the fly out cart to its own page and checkout since we have our own product detail pages (PDP) already.

So, while porting cart and checkout we created a hard coded product page so we could add things to cart to test the cart and we found what seems like a bug. In this base stock storefront app, if you go from home page or PLP > PDP > Add to cart > Cart everything works. If you clear cookies and db sessions in Vendure or otherwise start on a PDP (without loading homepage or PLP pages) > Add to cart > Cart, there seems to be a problem with the cart reading the session properly. You can add to cart, and it makes the correct API request, but if you refresh the page, the cart is empty.

I think it's related to not loading the activeCustomer correctly on the PDP. We've had multiple devs able to reproduce this with a stock storefront with the seeded data in a Vendure instance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions