Maps the given file path to an URL and determines the content-type
The input file path.
If the path corresponds to a file.
A ResourceLink with all the necessary metadata.
Maps the given resource identifier / URL to a file path. Determines the content-type, if no content-type was provided, by finding the corresponding file. If there is no corresponding file, a file path will be generated. For containers, the content-type input gets ignored.
The input identifier.
If we are mapping the metadata of the resource instead of its data.
Optional
contentType: stringThe (optional) content-type of the resource.
A ResourceLink with all the necessary metadata.
Supports mapping a file to an URL and back.