Packages
kreuzcrawl
0.3.0
0.3.0
0.3.0-rc.88
0.3.0-rc.87
0.3.0-rc.86
0.3.0-rc.85
0.3.0-rc.84
0.3.0-rc.83
0.3.0-rc.82
0.3.0-rc.81
0.3.0-rc.80
0.3.0-rc.79
0.3.0-rc.77
0.3.0-rc.72
0.3.0-rc.71
0.3.0-rc.70
0.3.0-rc.55
0.3.0-rc.51
0.3.0-rc.50
0.3.0-rc.49
0.3.0-rc.48
0.3.0-rc.47
0.3.0-rc.46
0.3.0-rc.45
0.3.0-rc.44
0.3.0-rc.43
0.3.0-rc.42
0.3.0-rc.37
0.3.0-rc.19
0.3.0-rc.18
0.3.0-rc.17
0.3.0-rc.15
0.3.0-rc.14
0.3.0-rc.13
0.3.0-rc.12
0.3.0-rc.11
0.3.0-rc.10
0.3.0-rc.9
0.3.0-rc.8
0.3.0-rc.7
0.3.0-rc.3
0.3.0-rc.2
0.2.0
0.1.2
0.1.1
0.1.0-rc.9
0.1.0-rc.8
0.1.0-rc.7
0.1.0-rc.6
0.1.0-rc.5
0.1.0-rc.2
High-performance web crawling engine
Current section
Files
Jump to
Current section
Files
lib/kreuzcrawl/browser_extras.ex
# This file is auto-generated by alef — DO NOT EDIT.
# alef:hash:c71da313df7b9a37bdd4f997f05150b92dfa5e723d3e2a4db0adafea6f951837
# To regenerate: alef generate
# To verify freshness: alef verify --exit-code
defmodule Kreuzcrawl.BrowserExtras do
@moduledoc """
Browser-specific extras populated when the native browser backend was used.
Available on `ScrapeResult.browser` when `BrowserBackend::Native` handled the request.
"""
@typedoc "Browser-specific extras populated when the native browser backend was used."
@type t :: %__MODULE__{
eval_result: String.t() | nil,
network_events: [map()],
cookies: [map()]
}
defstruct eval_result: nil,
network_events: [],
cookies: []
defimpl Jason.Encoder do
@doc false
def encode(value, opts) do
value
|> Map.from_struct()
|> Enum.reject(fn {_k, v} -> v == nil end)
|> Enum.into(%{})
|> Jason.Encoder.encode(opts)
end
end
end