Skip to main content

getAsset

Summary

Retrieve a registered file asset by its virtual path.

Signature

Parameters

path

Type:string Virtual path of the asset (e.g. “/textures/hero.png”).

Returns

Type:NfFile Retrieve a registered file asset by its virtual path.

Remarks

The path is normalised before lookup: leading and duplicate slashes are collapsed and trailing slashes are removed.