GithubHelp home page GithubHelp logo

danielstern / advanced-redux Goto Github PK

View Code? Open in Web Editor NEW
92.0 12.0 93.0 50 KB

A messenger service built with Redux

HTML 1.62% JavaScript 97.86% CSS 0.51%
react react-redux redux websockets reselect express

advanced-redux's Introduction

Advanced Redux Messenger

Redux Messenger

2017-03-28 08_00_27-redux messaging app

Introduction

This application is a fully functional messenger application similar to Slack or HipChat. It includes the following features,

  • State managed with Redux
  • React-Redux view
  • Selectors with Reselect
  • Immutable State
  • Live server updates with websockets
  • Redux-Saga
  • More!

How to Use This Application

  • This application is meant as a reference for students completing Advanced Redux on Pluralsight
  • Developers who are already familiar with the technology are welcome to copy the application and make any desired changes

Getting started

  1. Clone the application,
git clone [email protected]:danielstern/advanced-redux.git
  1. Install dependencies
cd advanced-redux
npm install
npm install -g babel-cli
  1. Start the application
npm start

or

npm run dev 
  • npm run dev is meant for development and includes file monitoring with Nodemon
  1. Navigate to the application in Chrome http://localhost:9000/#

Troubleshooting the Application

Refer to the following guide if the application does not seem to be working as expected

Application not working

Before trying any of the technique below, make sure your application is correctly coded.

  1. Clone this repository's master branch
  2. Without making any changes to it, run with npm install and npm start

This should solve 90% of errors. If not, see below:

Correct admin priveleges (Mac only)

  1. If you are using Mac, make sure that you installed Mac with Brew so that proper admin priveleges are configured

Install Global packages

Depending on your OS, NPM may have a hard time running locally installed packages from the command line. To resolve this, manually install the dependencies under devDependencies with npm install -g or use the following script:

advanced-redux's People

Contributors

danielstern avatar jeantroiani 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

Watchers

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

advanced-redux's Issues

package.json is missing babel-cli

`> [email protected] start /path/to/advanced-redux

babel-node server/server.js

sh: babel-node: command not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] start: babel-node server/server.js
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.`

Project worked after adding:
"devDependencies": { "babel-cli": "^6.0.0",

branch immutability-start not installing and running

after following the steps from cloning the project to installing the dependency, I am unable to start the application. The error logs.

Puspenders-MacBook-Pro:visual-studio puspender$ git clone https://github.com/danielstern/advanced-redux.git
Cloning into 'advanced-redux'...
remote: Enumerating objects: 351, done.
remote: Total 351 (delta 0), reused 0 (delta 0), pack-reused 351
Receiving objects: 100% (351/351), 50.39 KiB | 55.00 KiB/s, done.
Resolving deltas: 100% (162/162), done.
Puspenders-MacBook-Pro:visual-studio puspender$ cd re
react-basic-authentication-example/ react-redux-weather/
react-redux-blog-route/ reddice-master/
react-redux-registration-login-example/

Puspenders-MacBook-Pro:visual-studio puspender$ cd advanced-redux
Puspenders-MacBook-Pro:advanced-redux puspender$ git checkout immutability-start
Branch 'immutability-start' set up to track remote branch 'immutability-start' from 'origin'.
Switched to a new branch 'immutability-start'

Puspenders-MacBook-Pro:advanced-redux puspender$ npm install
npm WARN deprecated [email protected]: ๐Ÿ™Œ Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!

[email protected] install /Work/IDEs workspace/visual-studio/advanced-redux/node_modules/fsevents
node install

[fsevents] Success: "/Work/IDEs workspace/visual-studio/advanced-redux/node_modules/fsevents/lib/binding/Release/node-v64-darwin-x64/fse.node" already installed
Pass --update-binary to reinstall or --build-from-source to recompile

[email protected] postinstall /Work/IDEs workspace/visual-studio/advanced-redux/node_modules/nodemon
node bin/postinstall || exit 0

npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN [email protected] No repository field.

added 629 packages from 476 contributors and audited 5713 packages in 30.603s
found 2 vulnerabilities (1 high, 1 critical)
run npm audit fix to fix them, or npm audit for details

Puspenders-MacBook-Pro:advanced-redux puspender$ npm install -g [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected]
npm WARN deprecated [email protected]: ๐Ÿ™Œ Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!
/usr/local/bin/nodemon -> /usr/local/lib/node_modules/nodemon/bin/nodemon.js
/usr/local/bin/webpack -> /usr/local/lib/node_modules/webpack/bin/webpack.js
/usr/local/bin/webpack-dev-server -> /usr/local/lib/node_modules/webpack-dev-server/bin/webpack-dev-server.js
npm WARN [email protected] requires a peer of babel-core@^6.0.0 but none is installed. You must install peerdependencies yourself.

Puspenders-MacBook-Pro:advanced-redux puspender$ npm start

[email protected] start /Work/IDEs workspace/visual-studio/advanced-redux
babel-node server/server.js

sh: babel-node: command not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] start: babel-node server/server.js
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/puspender/.npm/_logs/2019-01-12T18_18_30_721Z-debug.log

Avoid install global dependencies

Hi!

First of all I'd like to thank you for this course. It's one of the best I've seen in a long time, keep up the good work!

Just to say something to be improved, instead of installing a lot of global dependencies it's better, in my humble opinion, to add those dependencies to dev scope.

Just add these dependencies to the package.json:

"devDependencies": {
    "babel-cli": "^6.24.1",
    "babel-core": "^6.18.2",
    "babel-loader": "^6.2.8",
    "babel-plugin-transform-object-rest-spread": "^6.19.0",
    "babel-preset-es2015": "^6.18.0",
    "babel-preset-react": "^6.23.0",
    "babel-regenerator-runtime": "^6.5.0",
    "nodemon": "^1.11.0",
    "webpack": "^1.13.3",
    "webpack-dev-middleware": "^1.10.1",
    "webpack-dev-server": "^1.16.2",
    "webpack-hot-middleware": "^2.17.1"
  },

And now npm start works without any global dependency installed

'babel-node' is not recognized as an internal or external command,

Hello,

I just started the tutorial and checked out the "immutability-start" branch. I followed the instructions to install the required dependencies (also installed the global ones).

I got an error while trying to start the application (npm start command):

'babel-node' is not recognized as an internal or external command,

If figured out that I had to install the babel-cli package:

npm install -g babel-cli

I don't know exactly which version should be installed, but seems like the latest one is fine.

For information, I'm running on a window 10 machine with node 7.2 and npm 3.10.9.

Btw, many thanks for the great video :)

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.