Meeseeks.fetch_all

You're seeing just the function fetch_all, go back to Meeseeks module for more information.
Link to this function

fetch_all(queryable, selectors)

View Source

Specs

fetch_all(queryable(), selectors()) ::
  {:ok, [Meeseeks.Result.t()]} | {:error, Meeseeks.Error.t()}

Returns {:ok, [Result, ...]} if one of more nodes in the queryable match a selector, or {:error, %Meeseeks.Error{type: :select, reason: :no_match}} if none do.

Optionally accepts a Meeseeks.Context map.

Parses the source if it is not a Meeseeks.Document or Meeseeks.Result, and may return {:error, %Meeseeks.Error{type: parser} if there is a parse error.

If multiple selections are being ran on the same unparsed source, parse first to avoid unnecessary computation.

Examples

iex> import Meeseeks.CSS
iex> Meeseeks.fetch_all("<div id=main><p>1</p><p>2</p><p>3</p></div>", css("#main p")) |> elem(1) |> List.first()
#Meeseeks.Result<{ <p>1</p> }>
Link to this function

fetch_all(queryable, selectors, context)

View Source

Specs

fetch_all(queryable(), selectors(), Meeseeks.Context.t()) ::
  {:ok, [Meeseeks.Result.t()]} | {:error, Meeseeks.Error.t()}