Skip to content

Commit 202b522

Browse files
authored
Release: v0.1.5 (#279)
* Updated README * Bumped versions * Removed Chrome DevTools mention
1 parent 0ea483a commit 202b522

2 files changed

Lines changed: 20 additions & 17 deletions

File tree

README.md

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,21 @@ Add `live_debugger` to your list of dependencies in `mix.exs`:
1717
```elixir
1818
defp deps do
1919
[
20-
{:live_debugger, "~> 0.1.4", only: :dev}
20+
{:live_debugger, "~> 0.1.5", only: :dev}
2121
]
2222
end
2323
```
2424

25+
For full experience we recommend adding below line to your application root layout. It attaches `meta` tag and LiveDebugger scripts in dev environment enabling browser features.
26+
27+
```elixir
28+
# lib/my_app_web/components/layouts/root.html.heex
29+
30+
<head>
31+
<%= Application.get_env(:live_debugger, :live_debugger_tags) %>
32+
</head>
33+
```
34+
2535
After you start your application LiveDebugger will be running at a default port `http://localhost:4007`.
2636

2737
> [!WARNING]
@@ -34,23 +44,16 @@ List of browser features:
3444
- Debug button
3545
- Components highlighting (coming soon!)
3646

37-
Some features require injecting JS into the debugged application. To achieve that you need to turn them on in the config and add LiveDebugger scripts to your application root layout.
47+
Some features require injecting JS into the debugged application. You can disable them in your config.
3848

3949
```elixir
4050
# config/dev.exs
4151

42-
config :live_debugger, browser_features?: true
43-
```
52+
# Disables all browser features and does not inject LiveDebugger JS
53+
config :live_debugger, browser_features?: false
4454

45-
```elixir
46-
# lib/my_app_web/components/layouts/root.html.heex
47-
48-
<head>
49-
<%= if Application.get_env(:live_debugger, :browser_features?) do %>
50-
<script id="live-debugger-scripts" src={Application.get_env(:live_debugger, :assets_url)}>
51-
</script>
52-
<% end %>
53-
</head>
55+
# Disables only debug button
56+
config :live_debugger, debug_button?: false
5457
```
5558

5659
### Content Security Policy
@@ -67,14 +70,14 @@ In `router.ex` of your Phoenix app, make sure your locally running Phoenix app c
6770

6871
## Igniter
6972

70-
LiveDebugger has [Igniter](https://github.com/ash-project/igniter) support - an alternative for standard mix installation. It'll automatically add LiveDebugger scripts to `root.html.heex` and enable browser features in your `config/dev.exs` after you use the below command.
71-
72-
Make sure that added dependency is `:dev` only.
73+
LiveDebugger has [Igniter](https://github.com/ash-project/igniter) support - an alternative for standard mix installation. It'll automatically add LiveDebugger dependency and modify your `root.html.heex` after you use the below command.
7374

7475
```bash
7576
mix igniter.install live_debugger
7677
```
7778

79+
Make sure that added dependency is `:dev` only.
80+
7881
## Optional configuration
7982

8083
```elixir

mix.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
defmodule LiveDebugger.MixProject do
22
use Mix.Project
33

4-
@version "0.1.4"
4+
@version "0.1.5"
55

66
def project do
77
[

0 commit comments

Comments
 (0)