I have hosted a static website in the s3 bucket successfully, but CSS, JS files, and images paths are getting an error as below. Due to that UI not displayed proper.
All JS, CSS, and images are in the assets folder.
Thanks in advance.
I have hosted a static website in the s3 bucket successfully, but CSS, JS files, and images paths are getting an error as below. Due to that UI not displayed proper.
All JS, CSS, and images are in the assets folder.
Thanks in advance.
Solution 1 => I found the solution, the issue was the folder structure that I have not created on the S3 bucket.
assets/css/filename.css
assets/js/filename.js
create the same folder structure that has in your project and uploaded files on the respective folder.
Solution 2 => you can remove the path, instead, just put the filename in index.html like this.
<link rel="stylesheet" href="bootstrap.min.css" lazyload="1">
It was working for me, both the solution.