Mojolicious::Plugin::Facebook - Interact with Mojo::Facebook
This module helps creating a Mojo::Facebook object.
In startup():
startup()
sub startup { my $self = shift; $self->plugin('Mojolicious::Plugin::Facebook', { app_namespace => '...', }); }
In a controller:
sub do_stuff { my $self = shift; my $token = '123456sdfgh98765'; Mojo::IOLoop->delay( sub { my($delay) = @_; $self->facebook($token)->fetch({}, $delay->begin); }, sub { my($delay, $res) = @_; $self->render(json => $res); }, ); }
Will register the helper facebook().
facebook()
See Mojo::Facebook.
To install Mojo::Facebook, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mojo::Facebook
CPAN shell
perl -MCPAN -e shell install Mojo::Facebook
For more information on module installation, please visit the detailed CPAN module installation guide.