0

Not rendering background image and showing error.
Is there a way to render the image ?

Failed to compile
./src/App.css (./node_modules/css-loader/dist/cjs.js??ref--5-oneOf-4-1!./node_modules/postcss-loader/src??postcss!./src/App.css)
Error: Can't resolve '/images/a.png' in 'C:\Users\ankus\Desktop\test1\src'

Folder Structure

+---public
ª   ª   favicon.ico
ª   ª   index.html
ª   ª   logo512.png
ª   ª   manifest.json
ª   ª   robots.txt
ª   ª   
ª   +---images
ª           a.png
ª           
+---src
        App.css
        App.js
        index.js

App.css file

body {
  background-image: url('/images/a.png');
}

0 Answers0