I am trying to set an image as the background for ion-content element, but always got on error:
./src/pages/public/home/home.style.css (./node_modules/css-loader/dist/cjs.js??ref--5-oneOf-4-1!./node_modules/postcss-loader/src??postcss!./src/pages/public/home/home.style.css) Error: Can't resolve '/assets/images/logo.png' in 'd:\CityInfo\development\mobileUI\src\pages\public\home'
My css class:
ion-content
{
--background: none;
background-image: url("/assets/images/logo.png");
background-position: center top;
background-repeat: no-repeat;
background-size: cover;;
}
--background: url(../../../assets/images/logo.png);
– Ravi Ashara