question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Uncaught TypeError: Cannot read property 'options' of undefined at new Translate (translate.js:63)

See original GitHub issue

I am not sure why this error is happening. Looks like something to do with the configuration of i18n.

The line at translate.js:63 is:

namespaces = namespaces || _this.i18n.options.defaultNS;

Where do the i18n options get configured? Am I configuring something wrong with my reducer?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
admangumcommented, Dec 20, 2017

Is your component wrapped in a I18nextProvider?

2reactions
BaggioWongHKcommented, Jan 17, 2019

What did it for me was exactly what @admangum suggested, literally wrap your component like so

<I18nextProvider i18n={i18n}>
          // your component
</I18nextProvider>

where i18n would be your i18nConfig. Not sure how helpful this is, but just wanted to add a comment in case it is to someone.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Jest error: TypeError: Cannot read property 'options' of ...
The error has to do with react-i18next not being configured correctly in your testing environment. translate() wraps your component and is ...
Read more >
Error: Uncaught [TypeError: Cannot read property 'options' of ...
Uncaught TypeError: Cannot read property 'options' of undefined at new Translate (translate.js:63) · Issue #31 ...
Read more >
Uncaught TypeError: Cannot read properties of undefined ...
Hi, i have this kind of error in two my site with 6.1 Elementor pro version. Your tool is required for Elments Elementor...
Read more >
cannot read properties of undefined (reading 'get') nestjs
When i try to leftJoin and load all products of a category I get error: TypeError: Cannot read properties of undefined (reading 'joinColumns')....
Read more >
ANGULAR 13 TypeError Cannot read property of undefined
In this tutorial, we will see a most common error faced by the Angular developers named as " TypeError Cannot read property of...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found