Upgrade to v22.0.5 causes type errors because of t returning null #1866
-
There are several locations in my React code where I use the
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
// i18next.d.ts
import 'i18next';
declare module 'i18next' {
interface CustomTypeOptions {
returnNull: false;
...
}
} I also recommend updating your i18next.init({
returnNull: false,
...
}); |
Beta Was this translation helpful? Give feedback.
t
function can returnnull
, this behaviour is set by default, if you want to change it, setreturnNull
type tofalse
.I also recommend updating your
i18next
configuration to behave accordantly. https://www.i18next.com/overview/configuration-options#translation-defaults