$layouts->sortBy()
Alias for Kirby\Cms\Layouts::sort()
$layouts->sortBy(string|callable $field, string|null $direction, int|null $method): Kirby\Cms\LayoutsParameters
| Name | Type | Default | Description | 
|---|---|---|---|
| $fieldrequired | stringorcallable | no default value | Field name or value callback to sort by | 
| $direction | stringornull | no default value | asc or desc | 
| $method | intornull | no default value | The sort flag, SORT_REGULAR, SORT_NUMERIC etc. | 
Return types
This method does not modify the existing $layouts object but returns a new object with the changes applied. Learn more →
Parent class
	Kirby\Cms\Layouts
		inherited from Kirby\Toolkit\Collection