ice.fo.utils
Version:
14 lines (9 loc) • 349 B
JavaScript
import getFileUrl from './getFileUrl';
import getResizeImagePath from '../String/getResizeImagePath';
export default function fullFileUrl(data, { width, height, $config } = {}) {
const filePath = getFileUrl(data, { $config });
if (process.client) {
return filePath;
}
return getResizeImagePath({ value: filePath, width, height });
}