Coder Social home page Coder Social logo

simplest-redux-example's People

Contributors

gaearon avatar haotian-infotrack avatar jackielii avatar luixlacrux avatar namelos avatar reggi avatar sacret avatar simoneast avatar yanhkim avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

simplest-redux-example's Issues

Redux structure with CRUD operation.

I would be great in case of a share or develop functionality like CRUD operation with small sample with this so that everyone can get an exact idea over the redux structure.

Removing Provider wrapper breaks

I used this repo as a starter a few days ago and it worked great. I just cloned it again as a new starter and got this:

Uncaught TypeError: children is not a function

Putting the wrapper back fixes the error:

{() => <App />}

Commit: 62e6f34

This was a fresh clone with a successful npm install

proptypes deprecated

Proptypes are being phased out, to be replaced with flow annotations

Maybe create 2 branches or samples, one with flow type, and one without.

Errors on Mac OS

Running npm install resulted in this npm-debug.log:
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'start' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info prestart [email protected]
6 info start [email protected]
7 verbose unsafe-perm in lifecycle true
8 info [email protected] Failed to exec start script
9 verbose stack Error: [email protected] start: watchify --debug --extension=js -o bundle.js index.js & python -m SimpleHTTPServer
9 verbose stack Exit status 1
9 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:214:16)
9 verbose stack at emitTwo (events.js:87:13)
9 verbose stack at EventEmitter.emit (events.js:172:7)
9 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:24:14)
9 verbose stack at emitTwo (events.js:87:13)
9 verbose stack at ChildProcess.emit (events.js:172:7)
9 verbose stack at maybeClose (internal/child_process.js:827:16)
9 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
10 verbose pkgid [email protected]
11 verbose cwd /Users/ejane/Programming/react/simplest-redux-example-master
12 error Darwin 15.4.0
13 error argv "/usr/local/bin/node" "/usr/local/bin/npm" "start"
14 error node v4.4.1
15 error npm v2.14.20
16 error code ELIFECYCLE
17 error [email protected] start: watchify --debug --extension=js -o bundle.js index.js & python -m SimpleHTTPServer
17 error Exit status 1
18 error Failed at the [email protected] start script 'watchify --debug --extension=js -o bundle.js index.js & python -m SimpleHTTPServer'.
18 error This is most likely a problem with the simplest-redux-example package,
18 error not with npm itself.
18 error Tell the author that this fails on your system:
18 error watchify --debug --extension=js -o bundle.js index.js & python -m SimpleHTTPServer
18 error You can get information on how to open an issue for this project with:
18 error npm bugs simplest-redux-example
18 error Or if that isn't available, you can get their info via:
18 error
18 error npm owner ls simplest-redux-example
18 error There is likely additional logging output above.
19 verbose exit [ 1, true ]

can't visit localhost:8000

image
image

I'm new to redux ,and it got a situation that i post here when i type npm start .Can you give me some advice.

Python server in "npm start"

Thanks for this great example, it helped me finally understand how to use Redux (especially the ES5 example.)

However, I couldn't run it on my system because of the python dependency. Just thought I'd bring this up in case this example can run off a node server, especially as it's aimed towards beginners.

Can't run

> [email protected] start /Users/dan/p/simplest-redux-example
> watchify --extension=js -o bundle.js index.js & python -m SimpleHTTPServer

sh: watchify: command not found

I think watchify needs to be in devDependencies?

Update babelify and include es2015 or react plugins

Using version 7.3.0 of babelify, some functionality has been moved to plugins, which aren't included by default. Using that version of babelify, I had to do the following additional steps:

npm install --save-dev babel-preset-es2015 babel-preset-react

Then update the transform in the package.json:

"browserify": {
  "transform": [
    [ "babelify", { "presets": ["es2015", "react"] } ]
  ]
},

pass data from when i click on button

i want to increment by 5 or 6,
but the condition is that i have to pass this data when i click on button.

something like Increase

then the counter will be 0,5,10,15,......

something like Increase

then the counter will be 0,3,6,9,12......

in short i will pass the value from button click.

Remove React?

Removing React would simplify this example even further, although I think people looking into Redux will most likely be using it with React. Just something to consider.

Thanks for sharing this.

Why python dependency?

The project seems to be dependent on python to run which is absolutely nonsense as nodejs is already a web server. Without installed python the simplest-redux-example just doesn't work which is somewhat hilarious.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.