Check out the code snippet I wrote below:
import React from 'react'
function OurCourse() {
return (
<div className='w-full '>
<div className='w-full h-[390px]' style={{
backgroundImage:'url(https://images.unsplash.com/photo-1532012197267-da84d127e765?ixlib=rb-
4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=387&q=80)',
backgroundSize:'contain',
backgroundRepeat:'no-repeat',
}}>
</div>
</div>
)
}
export default OurCourse
The issue is that the background image doesn't adjust according to the size of its div as expected after running the code.
https://i.stack.imgur.com/veHFw.png
I'm aiming for a result similar to this:
https://i.stack.imgur.com/omedP.png
I have been able to modify the text, but the background image isn't displaying correctly.