-
Notifications
You must be signed in to change notification settings - Fork 1k
Closed
Description
Environment
- Elixir version (elixir -v): Elixir 1.19.0-rc.0
- Phoenix version (mix deps): 1.8.0-rc.4
- Phoenix LiveView version (mix deps): 1.1
- Operating system: Ubuntu 22.04.5 LTS
- Browsers you attempted to reproduce this bug on (the more the merrier): Chrome
- Does the problem persist after removing "assets/node_modules" and trying again? Yes/no: Yes
Actual behavior
Hi,
I was trying out LiveView 1.1 last night and I noticed something strange.
I have a root.html.heex and it does a live_render of some navbar live view.
For some reason, when I write a test like this:
{:ok, view, html} = live(conn, ~p"/")
The view and html are limited to the live rendered navbar! Elements that are not in the navbar but are on the homepage are not accessible.
Something like
assert has_element?(view, "#div-on-home-page")
is failing because the expected element is not in the navbar but it is on the home page.
I ran the app and manually tested it and everything works fine. The problem has something to do with how live is working
Expected behavior
Is it not supported any more to use live_render in root.html.heex?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels