Scss background-image through .json

Hi, hope you’re great!

I’m tryinig to set a background image using scss, the image is obtained through a service. Here is an example of what I am trying to do:

.bg-img::after {
	...
	background: url(' + service.img + ');
	opacity: 0.5;
	...
}

When compiling the .scss reads the value “(’ + service.img + ')” as a string, literally, as if the file would not communicate with angular.

What’s the proper way to do this?