Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
// original
$this['events'] = $this->resource->get->uri('app://spout/resources/listing')
->withQuery([
'type' => 'event',
'sort' => 'datetime'
])
->eager
->request()['resources'];
// link
$this['events'] = $this->resource->get->link('listing')
->withQuery([
'type' => 'event',
'sort' => 'datetime'
])
->eager
->request()['resources'];
// syntax sugar proposal #1
$this['events'] = $resource('app://spout/resources/listing#resource', ['type' => 'event', 'sort' => 'datetime']);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment