offset-dev / strapi-calendar

Visualize your Strapi content in month, week or daily view
37 stars 13 forks source link

Improve Code #32

Closed LuisRodriguezLD closed 1 year ago

LuisRodriguezLD commented 1 year ago

Strapi reached out and they want to get this plug in verified. However they are asking us to make a few updates.


From Strapi:

  1. Here you use the Box component from the design system and give it a style object. You want it to be display flex so you can use the Flex component instead. Just like Box, it also has many props you can use to avoid the need for a style object
  2. I see you have separate imports for all design system icons and components. You can now use 1 import for all icons and 1 import for all components. We handle tree shaking better in the recent versions.
  3. It's nice to see you using formatMessage for all your strings. But you should provide it a defaultMessage in addition to the id every time. Otherwise apps using languages other than English will just have the ID as the fallback, which is often unreadable.
  4. You should also provide translations for the message of your notifications