Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enabling language configuration used in the site #103

Open
Felipe-53 opened this issue Jan 9, 2023 · 2 comments
Open

Enabling language configuration used in the site #103

Felipe-53 opened this issue Jan 9, 2023 · 2 comments

Comments

@Felipe-53
Copy link
Contributor

First of all, congratulations on this project! I really enjoy it.

I'd like to discuss an issue that I'd very much like to work on. But I thought I'd get everyone's opinion on it before forking.

Today, the blog pretty much only supports English as the language used on the page besides the content provided on the posts.

Things like: Read More (on the PostCard component), Home (on the PostPage component), etc.

I see that there is already a slot in the components for using a different language. For instance, in the PostCard component:

image

There is the lang parameter that is ultimately taken from the blog config options. Today, it is unused, but it would be ideal for this feature. I think it was left there for this purpose exactly.

So, what is missing here is a mapping between languages ISO codes and the text used in the components.

One way of accomplishing this is as follows:

So in each component we needed this feature we would have a mapping of ISO language codes and the corresponding text in each language. For example, in the PostCard component:

image

And then use it as follows:

image

So what do you guys think?

@Felipe-53
Copy link
Contributor Author

So, I was trying to come up with a clean solution to this, but I guess any way this is done it won't be that clean.

And I guess for a project that has minimal in the description this is not desired.

So, one solution would be that, if you want the content to be in your localete you could just fork and make the changes.

You can always make this repo the upstream and get the updates.

So, any thoughts on it?

@mandric
Copy link

mandric commented Apr 13, 2023

Language support is pretty important, I also want syntax highlighting for different programming languages. It would be nice if some minimal configuration could be settled upon for options like this. For now need to come up with our own hacks I guess...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants