Data-phx-session is 6825 characters long in a div container of a LiveView. Is this normal?

Environment

  • Elixir 1.10.2 (compiled with Erlang/OTP 21)
  • phoenix 1.4.16
  • phoenix_live_view 0.10.0
  • v10.15.2
  • 6.14.4
  • Ubuntu 19.10
  • Chrome
  • yes

data-phx-session is 6825 characters long in a div container of a LiveView. Is this normal?

Is this in development or in production?

Most likely, if you are testing tons of apps on http://localhost:4000, you would pass the cookies from all those apps around.

Clear your cookies or test in an incognito session. See if this changes anything.

What are you putting in the session?

1 Like

incognito doesn’t change it. Thanks!

I see, yes, actually I am putting a pretty big struct in the session. I think this should solve it, will post later once I make sure. Thanks a lot!

edit: solved.

1 Like