Creating a simple scraper in Wallaby

I want to create a simple scraper in

Where does the function “visit” come from? In the examples it’s called without a module as it were imported or used. But it’s not imported from anywhere.

{:ok, user1} = Wallaby.start_session  
{:ok,  %Wallaby.Session{driver: Wallaby.Phantom..............}}


Wallaby.visit(user1, "")
** (UndefinedFunctionError) function Wallaby.visit/2 is undefined or private

Or just:

iex(79)> visit(user1, "")        
** (CompileError) iex:79: undefined function visit/2

remember most if not all hex packages have excellent documentation - go to the wallaby docs - and when you search for visit you’ll get


Wallebey.Browser.visit(user1, "")


** (UndefinedFunctionError) function Wallebey.Browser.visit/2 is undefined (module Wallebey.Browser is not available)

You’ve got the library name wrong.

Try: Wallaby.Browser.visit(user1, "")

1 Like
  1. does Wallaby support only Phantom? 2) And only in the invisible mode? 3) Thus that won’t allow me to see what’s going on on a page, what it looks like, etc?