# `PhoenixReplay.Web.Export.Access`
[🔗](https://github.com/elixir-vibe/phoenix_replay/blob/v0.6.2/lib/phoenix_replay/web/export/access.ex#L1)

Lets the export browser, and nothing else, into `PhoenixReplay.Web.Export.Router`.

An export signs the recording's id with `PhoenixReplay.Export.Runtime.stage_url/3`;
the stage and the frame take the token in their path and mount only with
a valid one for that recording. The secret is made when
`PhoenixReplay.Web.Export.Endpoint` starts, so tokens die with it.

It also points the frame at your endpoint for its stylesheet, and
renders the frame in the `:frame_layout` the `:export` configuration
names, which it puts in the frame's context too.

# `frame_layout`

```elixir
@spec frame_layout(map()) :: Phoenix.LiveView.Rendered.t()
```

The root layout of exported frames: the `:frame_layout` the `:export`
configuration names, or the dashboard's frame layout.

# `on_mount`

```elixir
@spec on_mount(:default, map(), map(), Phoenix.LiveView.Socket.t()) ::
  {:cont, Phoenix.LiveView.Socket.t()}
```

Mounts the stage or frame only with a valid token for the recording in
the path, and points the frame's stylesheet at your endpoint and its
context at the layout it renders in.

# `recording_id`

```elixir
@spec recording_id(Phoenix.LiveView.Socket.t()) :: PhoenixReplay.Recording.id()
```

The id of the recording the stage was opened for.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
