solid-start icon indicating copy to clipboard operation
solid-start copied to clipboard

Rendering always has flickering issues, I'm not sure what the problem is

Open zhangfisher opened this issue 9 months ago • 3 comments

Rendering always has flickering issues, I'm not sure what the problem is

VoerkaI18n provides a new international experimental solution for SolidJS. In practical examples, when the default language refreshes the webpage in 'en-US', there is always a delay, and' zh CN 'is displayed first before English.

I cannot confirm if there is a problem with my usage method or other factors. I hope someone can help.

The example is here

zhangfisher avatar Mar 25 '25 01:03 zhangfisher

Image

The issue appears to be because createSignal initial value is set as a function, which causes the message to initially display in Chinese.

createSignal的值初始是message,导致先显示的中文

yefu24324 avatar Apr 29 '25 10:04 yefu24324

Setting ssr: false in app.config.ts fixed the problem, as SSR requires server-side initialization of the language configuration.


我在app.config.ts将ssr关闭后就正常了ssr: false. 主要还是ssr时, 需要服务器端就要初始化对应的语言

yefu24324 avatar Apr 29 '25 11:04 yefu24324

I see this is a SolidStart issue.. I will move it there. If you consider it complete please close it there.

ryansolid avatar Apr 30 '25 21:04 ryansolid