Skip to content

Fix live_title having line breaks#6667

Merged
SteffenDE merged 1 commit into
phoenixframework:mainfrom
lubien:fix-live-title-formatting-issues
Apr 29, 2026
Merged

Fix live_title having line breaks#6667
SteffenDE merged 1 commit into
phoenixframework:mainfrom
lubien:fix-live-title-formatting-issues

Conversation

@lubien
Copy link
Copy Markdown
Contributor

@lubien lubien commented Apr 29, 2026

Related to #6666

Can confirm it works after installing locally

~/workspace
❯ mix phx.new testfix --database sqlite3
warning! Erlang/OTP 28.0 detected.
Regexes will be re-compiled from source at runtime, which will cause degraded performance.
This can be fixed by using Erlang OTP 28.1+ or 27-.
* creating ...
* initializing git repository

Fetch and install dependencies? [Yn]
* running mix deps.get
* running mix assets.setup
* running mix deps.compile

We are almost there! The following steps are missing:

    $ cd testfix

Then configure your database in config/dev.exs and run:

    $ mix ecto.create

Start your Phoenix app with:

    $ mix phx.server

You can also run your app inside IEx (Interactive Elixir) as:

    $ iex -S mix phx.server


~/workspace took 18s
❯ cat testfix/lib/testfix_web/components/layouts/root.html.heex | grep live_title
    <.live_title default="Testfix" suffix=" · Phoenix Framework" phx-no-format>{assigns[:page_title]}</.live_title>

~/workspace
❯ http get http://localhost:4000 | grep "title"
    <!-- @caller lib/testfix_web/components/layouts/root.html.heex:7 (testfix) --><!-- <Phoenix.Component.live_title> lib/phoenix_component.ex:2248 (phoenix_live_view) --><title data-phx-loc="2249" data-default="Testfix" data-suffix=" · Phoenix Framework">Testfix · Phoenix Framework</title><!-- </Phoenix.Component.live_title> -->
    
~/workspace
❯ cd testfix

testfix on  main [?] is 📦 v0.1.0 via 💧 v1.19.3 (OTP 28)
❯ mix format
warning! Erlang/OTP 28.0 detected.
Regexes will be re-compiled from source at runtime, which will cause degraded performance.
This can be fixed by using Erlang OTP 28.1+ or 27-.

testfix on  main [?] is 📦 v0.1.0 via 💧 v1.19.3 (OTP 28)
❯ cat lib/testfix_web/components/layouts/root.html.heex | grep live_title
    <.live_title default="Testfix" suffix=" · Phoenix Framework" phx-no-format>{assigns[:page_title]}</.live_title>

@SteffenDE SteffenDE merged commit 7dc2de3 into phoenixframework:main Apr 29, 2026
6 checks passed
@SteffenDE
Copy link
Copy Markdown
Member

Thank you! 🙌

@lubien lubien deleted the fix-live-title-formatting-issues branch April 29, 2026 18:17
zorn added a commit to zorn/flick that referenced this pull request May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants