HNHacker News
TopNewBestAskShowJobs

kentor

466 karma · joined June 8, 2013

https://kentor.me/ https://github.com/kentor
submissionscomments
kentor··on Lyft surges to the top 10 on App Store following the “DeleteUber” campaign
https://en.wikipedia.org/wiki/Virtue_signalling
kentor··on React Router: Declarative Routing for React
The code has 1 font with no backup:

        font-family: Monaco;
I don't have Monaco on Windows so it's using Times New Roman :\
kentor··on React Router: Declarative Routing for React
Will there be a way to prevent transitions when clicking on a link that isn't hooked into react router?
kentor··on Curl hearts Mozilla
At least curl is not using symbols for leetspeak.
kentor··on Lessons learned as a React contractor
Redux is for people who appreciates immutability. A lot of newbies don't appreciate immutability.
kentor··on Lessons learned as a React contractor
Reducers are pure functions so they can be tested very easily. Also the whole middleware thing and redux logger are awesome.
kentor··on Ruby 2.4.0 Released
That's an editor problem.
kentor··on Webpack 2.2 – Release Candidate
That's true, and I'm glad they aren't jumping the gun. Browserify is all about node compatibility, so I'll gladly wait until Node implements ES Module support.
kentor··on Webpack 2.2 – Release Candidate
Not having to refresh which means preserving state. If I have a modal opened and I want to make a change to the modal UI, if I refresh I would have to reopen the modal. With HMR the modal just rerenders.

Also even if you have a fast build, refreshing might require refetching data from a server.

In any case browserify also has HMR and it's great.

kentor··on Why we chose Vue.js over React
Yes and this is a tired argument by now. The talk by Pete Hunt aptly titled "React: Rethinking best practices"[0] given in 2013 points out how separating templates and logic is merely a separation of technologies, not concerns.

[0]: https://www.youtube.com/watch?v=x7cQ3mrcKaY

kentor··on Why we chose Vue.js over React
What does "want you to do things their way" even mean? Aren't you doing things a certain way by virtue of using a framework? Maybe angular/react is just making you do things in a way that you prefer not to, while vue.js is making you do things in a way that you find reasonable. For other people, it's the reverse.
kentor··on Yoga: A cross-platform layout engine
Bummer. I was using css-layout to lay out svg elements[0]

[0]: https://kentor.me/posts/creating-diagrams-with-react-svg-and...

kentor··on The State of Babel
afaik CoffeeScript has no specification
kentor··on Vue.js 2.1 Released
Of course it is, but saying it's "a ton of complexity" to use JSX, while not saying the same for transpiling current and future ECMA-262 syntax into what browsers support right now is disingenuous.
kentor··on Vue.js 2.1 Released
It's literally as complex as transpiling ES6 to ES5.

And although JSX is not in the ECMA-262 spec, it does have a spec, so there's that.

kentor··on Visual Studio Code 1.7
Which extension are you using? I'm using vscodevim and diw, ciw, and the likes work.
kentor··on Visual Studio Code 1.7
The vscodevim vim bindings have improved greatly since a couple of months ago and is comparable to Sublime's vintage.

These features are still missing and are keeping me from switching completely from Sublime:

- Project wide symbol fuzzy search (cmd+shift+r in sublime)

- Read from stdin (`git show | code`)

kentor··on Am I wrong in hating React JS?
The reason why it uses `className` is because we're in javascript land (https://developer.mozilla.org/en-US/docs/Web/API/Element/cla...) So it's not a DSL when you really think about it. It's javascript.
kentor··on Next.js – A small framework for server-rendered universal JavaScript apps
I remember I started out using `.jsx`, but switch to `.js` solely because I could use `require()` without specifying the extension, WITHOUT modifying the module resolution algorithm.
kentor··on Why we chose Vue.js
You can think of it as sugar for `React.createElement()`, and some other stuff (like spread) but that's it. It's really easy to translate into javascript in your head.

Why is this good?

1. Let's say I want to stick a debugger in my template or render function. How would you do it in Vue? Angular? I don't know, gotta look it up, not even sure if possible. How would you do it in React? I don't have to look anything up, I just have to think (use an iife):

   <div>
     <SomeComponent
       debug={(() => { this.state; debugger; })()}
       someProp="prop"
     />
   </div>
2. Let's say I want to use Immutable.JS instead of plain js arrays. How would I iterate over an immutable list in Vue. In Angular? I don't know, probably have to download some third party directive. React:

    <ul>
      {immutable.toSeq().map(x => <li>x</li>)}
    </ul>
kentor··on Why we chose Vue.js
After using React, I am firmly in the #nevertemplates camp. I don't ever want to learn a template DSL again when I could be using the full power of javascript.
kentor··on React flexbox layout and grid system
bringing in another dependency for one
kentor··on Angular 2 Final Released
Manually reload the page? No thanks, way too slow. Using React hot loader and can't go back.
kentor··on Ask HN: Is Apple about to kill the Macbooks?
Obviously I'm exaggerating my dislike of the new keyboard. They feel like crap. The travel is really low, so it's like typing on an ipad with bad feedback.
kentor··on Ask HN: Is Apple about to kill the Macbooks?
No. But if Apple replaces the keyboard with "butterfly" switches, like those on the MacBook, then the new MBPs might as well be DoA.
kentor··on How the Sugar Industry Shifted Blame to Fat
Then the question is why do they eat 3500kcal? The hypothesis is that sugar does not make people feel full whereas fat does, so they eat more. A calorie is not a calorie.
kentor··on Some bad Git situations and how I got myself out of them
I personally prefer this because old-branch@{1} is a little weird..

  git checkout new-branch
  git cherry-pick old-branch
  git checkout old-branch
  git reset --hard HEAD^
kentor··on Hexo, OpenShift and CloudFlare
Going through the same thing.

He could have saved a rule. Just have "www.nmaggioni.xyz/*" redirect to "https://nmaggioni.xyz/$1". That takes care of both http:// and https://.

Also, I'm using Gitlab pages which provides a build step after pushing.

kentor··on Twitch could be a $20B company within Amazon
Pretty sure you can stream 60fps on twitch.
kentor··on React Fiber Architecture
Data-binding is crap for many reasons. Here's a big one: inability to use immutable data types, except for the trivial case of a static component.

When you're diffing the vdom, the system doesn't care where the data comes from, i.e. the data can come from a plain js array or an Immutable.js list.

Second reason: When you have to worry about how to get your model to play nice with the view, that's a leak in the abstraction. This applies to ALL data-binding systems.

← PreviousPage 2 of 4Next →