It-s-Saturday / Fornear

Nurturing Oglethorpe University students with reliable access to food
1 stars 8 forks source link

feature: default text for when data is falsy #39

Closed itsjayway closed 1 year ago

itsjayway commented 1 year ago

Describe the feature when backend is not running or API call fails (when data === null or data is falsy), show default text on the screen

What would the feature solve

neeravbhaskarla commented 1 year ago

can you assign me this issue?

itsjayway commented 1 year ago

you got it @neeravbhaskarla 🏃

neeravbhaskarla commented 1 year ago

Hi @jibranabsarulislam, What should be the default text display? Should it show 'No data' or is it acceptable to have no visible data?

itsjayway commented 1 year ago

thanks for reaching out @neeravbhaskarla, what do you think of "There are no items to display.", probably with a className='text-bold'

neeravbhaskarla commented 1 year ago

if data is not there should I not display any items?

itsjayway commented 1 year ago

right, for now we can show the no items text when there's no response data

neeravbhaskarla commented 1 year ago

hi @jibranabsarulislam, submitted PR. Please review it