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

Uncaught TypeError: intl is undefined #27

Closed
mauritsvanrees opened this issue Sep 12, 2024 · 2 comments
Closed

Uncaught TypeError: intl is undefined #27

mauritsvanrees opened this issue Sep 12, 2024 · 2 comments

Comments

@mauritsvanrees
Copy link
Contributor

Adding and then editing a quote block works, but viewing it gives an error Uncaught TypeError: intl is undefined. That is on this line. intl should have come from the props, but apparently that does not work.

In other places I have seen const intl = useSelector((state) => state.intl);. Should we use that?
I have no idea if the best way to get intl differs per Volto version.

My setup: latest Volto 18 (18.0.0-alpha.42), Volto light theme 5.0.0, Plone 6.0.13.

@davisagli
Copy link
Member

@mauritsvanrees @jonaspiterek Nothing passes intl to the props, so expecting it there is a bug.

Getting it with useSelector is a good way to go for function-based components.

@mauritsvanrees
Copy link
Contributor Author

The fix is in release 1.1.2. Thanks.

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