chore: make Rehydratable use Awaitable; add docblock

This commit is contained in:
2021-07-02 21:44:34 -05:00
parent cf6d14abca
commit 5d960e6186
3 changed files with 17 additions and 6 deletions

View File

@@ -73,6 +73,14 @@ export class Routing extends Unit {
return this.compiledRoutes
}
/**
* Resolve a UniversalPath to a file served as an asset.
* @example
* ```ts
* this.getAssetPath('images', '123.jpg').toRemote // => http://localhost:8000/assets/images/123.jpg
* ```
* @param parts
*/
public getAssetPath(...parts: string[]): UniversalPath {
return this.getAssetBase().concat(...parts)
}