That's intentional. Grocery stores are laid out to encourage you to spend more.

Like almost everything people complain about nowadays, this is not a tech problem, has never been a tech problem, and cannot be fixed with tech.

Third parties with tech could fix it.