(name: string, type: string, category: string)
| 1608 | const directory = `${assetsPath.root}/${assetsPath[category as keyof typeof assetsPath]}`; |
| 1609 | |
| 1610 | const onSuccess = (name: string, type: string, category: string) => { |
| 1611 | this.trigger('assetLoaded', { name, type, category }); |
| 1612 | } |
| 1613 | |
| 1614 | if (FileSystem.isImage(asset)) { |
| 1615 | promises.push(Preload.image(`${directory}/${asset}`).then(() => onSuccess(asset, 'image', category))); |