I'm struggling to set a backgroundImage because it's not recognizing the local path URL.
Here is my code snippet:
import { makeStyles } from '@material-ui/core/styles';
const loginWrapperStyles = makeStyles(theme => ({
image: {
backgroundImage: 'url(../../../public/assets/regbackground.jpg)',
}}))
When I tested the import statement to locate the assets folder, they confirmed that the path was correct:
https://i.sstatic.net/WQP2c.png
This is the exact name and format of the image file:
https://i.sstatic.net/PBSba.png
However, despite all this, my image still fails to render. What am I doing wrong?