Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const CategoryTile = props => {
const talonProps = useCategoryTile({
item: props.item
});
const { image, item } = talonProps;
const imagePath = resourceUrl(image.url, {
type: image.type,
width: image.width
});
// interpolation doesn't work inside `url()` for legacy reasons
// so a custom property should wrap its value in `url()`
const imageUrl = imagePath ? `url(${imagePath})` : 'none';
const imageWrapperStyle = { '--venia-image': imageUrl };
const classes = mergeClasses(defaultClasses, props.classes);