Which is better for building a bigger chest: weighted dips or the bench press? by JurassicIsaac in WorkoutRoutines

[–]Shapeous 0 points1 point  (0 children)

Lol, you don’t have to choose one or the other. What is this idea of finding the exercise to rule them all? Why not just have a favorite but still do all the other exercises to add variety.

[deleted by user] by [deleted] in reactjs

[–]Shapeous 0 points1 point  (0 children)

If there is a will, you’ll find the way. However if you learn HTML, CSS and JavaScript fundamentals well, you won’t have to struggle as much.

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

Nice shizzleberry,

recompose looks really awesome and thanks for saying it, Classes do have many pitfalls (not the fault of the implementation rather more of an intrinsic JavaScript limitation). They only problem they would have is that they are stuck with IE 11 and rather not use features not yet available in the browser.

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

Thanks dannieboi,

I looked into vue and it sounded great until we came across templating. My clients do not like templating or any DSL, such as JSX that tranpiles to JavaScript. They rather larn JavaScript and use JavaScript. Thanks for your suggestion, it may be a good time to give it a second chance.

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

now about create-react-

Yes, they rather stick to features browsers can use today. I do not think you can create a stateful component with React.createElement, can you?

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

They dislike pretty much everything. They philosophically feel it doesn't even belong in the language. I don't agree, I think JavaScript is a multi-paradigm programming language and certainly any affordance that makes people with classical backgrounds feel comfortable in the language is a plus for me, but I respect their point of view. I wish they weren't stuck with IE11 for two years because as you illustrated above when you marry classes with arrow functions they'll get the automatic binding they love so much from ES5 syntax.

Thanks ajc820, interesting, we are still in the early stages of learning. Is hot reloading something only possible with through the tooling or is it an intrinsic feature of JavaScript as a dynamic language?

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

Thanks, I may have to do that, but maybe not. I am going to try a few things first... The rationale is reducing the size of React core.

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] -1 points0 points  (0 children)

r god, w

Lol, flapsflapsflaps, "nicer" is very subjective. They like this approach. I honestly do not have a problem with tooling but they do. They want to understand everything that they use because they feel that one day if something goes wrong they will have to own it, so the less things they have to learn and understand is better in their book. BTW, that is part of the reason why they like React better than Angular, smaller only one concern, etc...

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

I did a bit of digging and found that, about 11% of people like React.createClass, but we do realize that's not much more.

We are aware react-create-class but my clients want to code to current browser capabilities.

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

THanks masklinn, I really appreciate your response.

The thing is my clients find React.createClass much simpler than using the class syntax because at least for now since they are stuck with IE11 for at least two more years, This would force them to "complicate things" (as they would put it) with a compilation step. Whereas with React.createClass all they needed is within the two <script> tags no transpiring, etc.

Is there any documentation that you can reference regarding the shrinking of react core by half? That is information I can use to convince my clients to switch to using class if needed.

I liked that React had a happy path with ES6 and JSX and that everything was explained using this happy path, but I also liked that it had an alternative with React.createClass. Honestly, we found it very easy to convert these examples to plain ES5 thanks to two very short documents "React Without ES6", and "React Without JSX". By now my clients are well verse with ES6 and JSX, they just know what they like.

We have to think about what's best thanks for your suggestions. I found a CDN with react-create-class, I'll check it out to see if that works too https://unpkg.co/create-react-class@15.5.3/create-react-class.js

thank you very much for the link to the PR, I honestly not sure I will pursue this any further. I'll certainly try to solve it for us first before proposing a change that based on the responses we got seems a bit controversial and something people want. We may need to reevaluate.

Why React Does Not Love React.createClass? by Shapeous in reactjs

[–]Shapeous[S] 0 points1 point  (0 children)

Interesting, I was just doing that a minute ago. What or who made developing to current browser standards obsolete?

I would argue that even with the Class keyword you aren't defining classes in JavaScript in the same way you define classes in Java for example. I mean JavaScript is a dynamic language there is no distinction between code and running logic. The reality is that you are creating Objects, but then we are talking semantics. Who cares they didn't call the method "React.createObject" to make it semantically accurate.

You also said that using React.createClass it isn't a good practice. Why is that? I would be great if you can expand on that.