如何将 next-intl 更新到 2.14.4

huangapple go评论43阅读模式
英文:

How to update next-intl to 2.14.4

问题

我当前安装的是next-intl 2.13.0-beta.2

我尝试通过npm install next-intl@latest将其更新为2.14.4。

import { getTranslations } from 'next-intl/server'不起作用。我收到了错误消息getTranslation不是一个函数。

英文:

I have currently next-intl 2.13.0-beta.2 installed.

I have tried to update it to 2.14.4 with npm install next-intl@latest

But import { getTranslations } from 'next-intl/server' not working. I got the error getTranslation is not a function.

答案1

得分: 1

抱歉,我认为关于版本的问题存在一些混淆。如果您使用RSC功能,目前应该保持在beta渠道上,最新版本是next-intl@2.15.0-beta.5(参见文档)。

这里有更多背景信息:https://github.com/amannn/next-intl/issues/286。

英文:

My apologies, I think there was some confusion in regard to the versioning. If you use RSC features, you should stay on the beta channel for now, the latest version is next-intl@2.15.0-beta.5 (see docs)

Here's a bit more context: https://github.com/amannn/next-intl/issues/286.

huangapple
  • 本文由 发表于 2023年5月22日 23:36:04
  • 转载请务必保留本文链接:https://go.coder-hub.com/76307810.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定