Git Product home page Git Product logo

Comments (11)

choonkending avatar choonkending commented on May 17, 2024

@joshhornby Thanks for your feedback!! :)

I didn't rewrite the node part in ES6 initially because it was not part of the webpack build step and I thought Heroku didn't support the node 0.12 runtime.

But I'm happy to have the node end have a ES6 refactor. If you're interested, would you like to submit a PR for this?

from reactgo.

joshhornby avatar joshhornby commented on May 17, 2024

I should have some time to ES6 the node side, although may need some help with the webpack build step.

from reactgo.

choonkending avatar choonkending commented on May 17, 2024

@joshhornby Sure thing! Thanks!

from reactgo.

SOSANA avatar SOSANA commented on May 17, 2024

1+ be nice for people coming from ES5 to ES6 to see the difference. I will be hacking away with this. Be cool to have a branch for ES5 just for learning but understand the need to move forward with ES6.

from reactgo.

choonkending avatar choonkending commented on May 17, 2024

@SOSANA Thanks!

Yea I agree. I considered having separate branches for ES5 and ES6 when I made the ES6 change, but went ahead with just one branch and thought having docs for it would be good enough.

I have a small README here for moving to ES6 from ES5 with React. If you like you can create a separate ES5 branch, or update that doc :)

from reactgo.

SOSANA avatar SOSANA commented on May 17, 2024

@choonkending your so money, Just checked outed README. Good job! Hope to contribute when I can :)

from reactgo.

choonkending avatar choonkending commented on May 17, 2024

I've been using io.js to run npm.

We could go with node v0.12 with the --harmony flag (i think)

or io.js (which supports ES6 by default)

@joshhornby what do you think? I'm leaning towards io.js.

Heroku also supports this: https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version

from reactgo.

joshhornby avatar joshhornby commented on May 17, 2024

@choonkending I have no issues with switching to io.js.

Although whats the deal with io.js and node.js merging? I thought I heard discussions at one point?

from reactgo.

choonkending avatar choonkending commented on May 17, 2024

I'm using node 5 currently. Just haven't made the switch for the server side code. Should really look into this.

from reactgo.

caranicas avatar caranicas commented on May 17, 2024

the best example I have found using es6 on the server is the react starter kit from kriasoft. https://github.com/kriasoft/react-starter-kit

the way it uses webpack is and the build scripts is pretty different, so I am still trying to detangle it all, and figure out why the bable-loader isn't running on our server code.

from reactgo.

choonkending avatar choonkending commented on May 17, 2024

I reckon we should compile with babel-cli instead of the babel-node method being used in the react-starter-kit because we are aiming for production use. Read babel-node.

from reactgo.

Related Issues (20)

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.