paljs / prisma-tools

Prisma tools to help you generate CRUD system for GraphQL servers
https://paljs.com
MIT License
683 stars 54 forks source link

i18n support #169

Closed gtolarc closed 3 years ago

gtolarc commented 3 years ago

I think i18n support is needed. It would be nice if both system messages and data model field names could be supported by a common interface.

I think the following is a good example. https://marmelab.com/react-admin/Translation.html#translation-messages https://marmelab.com/react-admin/Translation.html#translating-resource-and-field-names

Could you guys add this part to the roadmap?

AhmedElywa commented 3 years ago

This is a big change and needs time. I think maybe you can help when I start on this.

gtolarc commented 3 years ago

Sure :)

gtolarc commented 3 years ago

Since adminSettings.json is saved as a file, CMS cannot be separated unless we use a SSR framework like nextjs. Also, it is impossible to scale up server instance. But how about rethinking it as the role of a static generator to make setting easier?

If we can determine permissions or settings(label, upload, editor, etc..) only at the coding stage as a js file, we can apply the existing i18n libraries and many things will be solved.

Other headless cms tools have a similar orm-like approach that describes the appearance of the db schema and the front view at once, but I like the pal.js method where everything is automatically created with prisma as idl. So, how about keeping this concept, but changing only adminSettings.json to the js file and removing the settings at the user level. What do you think? @AhmedElywa

AhmedElywa commented 3 years ago

resolved in last version