Building application, images not loaded from `.scss` files


#1

Hi everyone,

I just just started with Ionic more than a week ago, and I started to like it, as I already have some experiences with Javascipt/NodeJS, and a bit of Angular.

I got few pages work perfectly, but the problem is when building into apk (I’m working only on Android for now), those images defined in .scss files are not loaded.
I see that only those embedded in img or ion-img elements are working.

anyone encounters this issue?


#2

you should try"…/assets/img.png"
like this
background-image: url(’…/assets/png/background.png’);


#3

Wow, thanks, it works great now!
I didn’t know it’d be simple as that
and that means I should get relative paths according to structure of www directory, right?

anw thanks for your answer!