Issues using react-localize-redux without redux
See original GitHub issueHi !
According to the release notes from 3.0, react-localize-redux
is supposed to be usable without using redux. But I seem to be getting issues compiling.
When trying to start a new project with bare bones dependencies:
"dependencies": {
"react": "^16.3.2",
"react-dom": "^16.3.2",
"react-localize-redux": "^3.3.2"
},
And a really basic index.jsx
:
import React from 'react';
import { render } from 'react-dom';
import { LocalizeProvider } from 'react-localize-redux';
class App extends React.Component<any, any> {
render() {
console.log(this.state.store);
return (
<LocalizeProvider>
bloop
</LocalizeProvider>
);
}
}
render(<App />, document.getElementById('root'));
I get compile issues:
ERROR in ./node_modules/react-localize-redux/es/localize.js
Module not found: Error: Can't resolve 'redux' in '[snip]/node_modules/react-localize-redux/es'
@ ./node_modules/react-localize-redux/es/localize.js 10:0-40
@ ./node_modules/react-localize-redux/es/index.js
ERROR in ./node_modules/react-localize-redux/es/LocalizeProvider.js
Module not found: Error: Can't resolve 'redux' in '[snip]/node_modules/react-localize-redux/es'
@ ./node_modules/react-localize-redux/es/LocalizeProvider.js 10:0-15
@ ./node_modules/react-localize-redux/es/index.js
ERROR in ./node_modules/react-localize-redux/es/utils.js
Module not found: Error: Can't resolve 'redux' in '[snip]/node_modules/react-localize-redux/es'
@ ./node_modules/react-localize-redux/es/utils.js 4:0-15
@ ./node_modules/react-localize-redux/es/localize.js
@ ./node_modules/react-localize-redux/es/index.js
Exact yarn.lock
for react-localize-redux
:
react-localize-redux@^3.3.2:
version "3.3.2"
resolved "https://registry.yarnpkg.com/react-localize-redux/-/react-localize-redux-3.3.2.tgz#cf42a90bdd640bf0fd92f3528f3e1707232cc9dc"
dependencies:
create-react-context "^0.2.2"
flat "^2.0.1"
prop-types "^15.6.1"
reselect "^3.0.1"
I quite new at all this, so I’m expecting that I’m doing something wrong 😃
Thanks for any help, Js
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
FAQ - react-localize-redux
How do I persist active language? · 1. Save active language to local storage · 2. Keep active language in the url.
Read more >React Localize Redux 3.0 - Medium
I'm happy to announce the latest release of react-localize-redux. New features, new docs, new logo, and now works without Redux by default.
Read more >react-localize-redux examples - CodeSandbox
Learn how to use react-localize-redux by viewing and forking example apps that make use of react-localize-redux on CodeSandbox. React TypescriptAdding types to ...
Read more >Localize Your App With React Intl - Better Programming
In short, it is necessary for Translate to handle default translations in HTML but is not included in the react-localize-redux package as it...
Read more >Top 5 react-localize-redux Code Examples - Snyk
Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@pixelplant @lyndseybrowning I just pushed removed a few left over redux references I found in the source #129 . Hopefully this takes care of the issue - fixes are published in
v3.4.1
.@ryandrewjohnson Nope, still getting this in 3.4.0
Error: Can't resolve 'redux'