WARNING: The [sjs-3] engine was deprecated, use [sjs-4] instead.


Find a file specified by its path relative to the files in the collection, return the first match.


collection.select(selector string) File collection.select(selector string) null


selector string

A path and any filters. Selectors that may match multiple files, like the child selector, are invalid. See selectors for more details.


Can’t select files relative to an empty collection.

Basic example.

Returns the first match.

Example when no match is found.

It is invalid to use selectors that may match multiple files.