| 1 | package Plack::App::GraphQL::Context; | ||
| 2 | |||
| 3 | 1 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | |||
| 5 | 1 | has ['request', 'app', 'data'] => (is=>'ro', required=>1); | |
| 6 | 1 | has log => (is=>'ro', required=>0); | |
| 7 | |||
| 8 | 1 | ▶ | sub req { shift->request } |
|
Subroutine
req: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 9 | |||
| 10 | 1 | 1; | |
| 11 | |||
| 12 | =head1 NAME | ||
| 13 | |||
| 14 | Plack::App::GraphQL::Context - The Default Context | ||
| 15 | |||
| 16 | =head1 SYNOPSIS | ||
| 17 | |||
| 18 | TBD | ||
| 19 | |||
| 20 | =head1 DESCRIPTION | ||
| 21 | |||
| 22 | This is a per request context that is passed to your resolvers in addition | ||
| 23 | to the root or local value. Useful if you need to inspect some aspect of | ||
| 24 | the request. Subclass or roll your own as needed. For example you could | ||
| 25 | have a custom context with a user object for applications with user login | ||
| 26 | and security. | ||
| 27 | |||
| 28 | =head1 AUTHOR | ||
| 29 | |||
| 30 | John Napiorkowski | ||
| 31 | |||
| 32 | =head1 SEE ALSO | ||
| 33 | |||
| 34 | L<Plack::App::GraphQL> | ||
| 35 | |||
| 36 | =cut | ||