Echo JS 0.11.0

<~>

xat comments

xat 463 days ago. link 1 point
Nice story :)

Node was always nice to quickly show off something. I remember playing around with Node, the first time, in the end of 2009. Back then it already was clear that it will probably become huge.

I think that's often how new tech slowly sneaks itself into a company. Some developers playing around with it, talking about it at lunch, demonstrating that it is way more productiv than the previous solution. Then the technology gets used in some minor important project, after that maybe in some more important project, and so on.
Couple of years later, same thing happens with some newer technology.
xat 463 days ago. link 0 point
I don't think it plays that of a big role if a library was only created by a single person or not. Think of Node.JS, express, redis, Backbone.js, linux etc. They all became popular, despite the fact that they were created by a single person (at least at the beginning).
xat 464 days ago. link 2 points
Discussing React vs. Vue on the internet ist mostly a waste of time. People tend to be biasd towards their favorite library, like it is some sort of religious cult or something. I'm not excluding myself from this.

Maybe we would get better results if both groups were only allowed to write about the negativ parts of their favorite library.
xat 466 days ago. link 1 point
A similar example in React, using a Higher Order Component, would look somehow like this:

function createSurveyInput(SurveyComponent) {
  return (props) => (
    <div className="survey-base">
      <h4>{props.question}</h4>
      <SurveyComponent {...props} />
    </div>
  )
}

const SurveyInputText = createSurveyInput((props) => (
  <input type="text" placeholder={props.placeholder} />
))
xat 492 days ago. link 1 point
Btw, the guy you are judging is a developer from the UK.
xat 493 days ago. link 1 point
If someone explicitly passes in "const opts = { name: null }" then I would argue that he wants name to be null and it should not be overwritten by what is defined in defaults. But I agree with you that there may be some (rare?) cases where some other behaviour is wanted.
xat 493 days ago. link 2 points
The way Object.assign is usually used is like this:

const opts = Object.assign({}, defaults, options);

It will fallback to the properties defined in defaults if they don't exist in options.

Nowadays you can also use destructering to achieve the same:

const opts = { ...defaults, ...options };
xat 493 days ago. link 1 point
You can check for the existence of a property with obj.hasOwnProperty('someProp').
xat 493 days ago. link 1 point
You are welcome to write your next blog post in german (without mistakes) ;-)

The guy you are judging is a junior developer from Serbia btw.
xat 493 days ago. link 2 points
We usually namespace the constants like this:

export const FOO = '<namespace>/FOO';

Wouldn't want to type the namespace every time...
[more]