HNHacker News
TopNewBestAskShowJobs

frontendbeauty

389 karma · joined November 23, 2011

submissionscomments
frontendbeauty··on Ask HN: If you restarted your career, what would you do differently?
> In every software company the people who are the most influential, and the best paid, are in management or sales.

I don't think that's necessarily true in Silicon Valley, where companies like Google, Facebook, Airbnb, Uber, etc. have parallel career tracks for individual contributor vs manager, with equal salary bands. I'm earning way more as a high-level IC than mid-leveled managers.

frontendbeauty··on Developing Our First iOS App with React Native
> Here's the litmus test. Ask the Reactive Native team to port their non-trivial paper app or mission critical messenger app or main app to Reactive Native.

Facebook is rewriting the News Feed in RN. That's not a trivial example.

frontendbeauty··on Airbnb tests booking your entire trip with new 'Journeys' service
s/AirBnb/Airbnb/
frontendbeauty··on Airbnb Engineering
We've called ourselves "nerds" since the very early days, at least 5 years.
frontendbeauty··on What happens when a host cancels with Airbnb?
See Brian's post: https://news.ycombinator.com/item?id=7254986

Airbnb does leave an automated review about the cancellation and dings the host's listing in search results.

frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
Why couldn't you use a CDN for the JS files? We most certainly do.
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
There are already two problems, if you're building a rich client-side web app. Have you done this? If so, you would understand the problem.
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
I like "multiplatform" -- current winner :)
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
There are a few options. Easiest is to just render HTML strings on the server, not actual DOM. But, you can also use a DOM implementation if you want to, like jsdom or PhantomJS, and then capture the outerHTML of an element as an HTML string to serve. But, that is slower. React.js has a nice middleground approach; it has a fast pure-JavaScript DOM abstraction that can emit either DOM (browser) or HTML (server).
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
(author here) Good point. TBH, I have no idea what "isomorphic" means in the mathematical sense.

I was inspired to use "isomorphic" from a 2011 article by Nodejitsu [1]. It seemed like a fine way to describe this approach. I would gladly use a better would if I were to find one.

[1] http://blog.nodejitsu.com/scaling-isomorphic-javascript-code

frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
(author here) We just bootstrap some JSON onto the page to transfer application state to the client. It's the same approach as the `express-state` (mentioned in a below comment). Same as any client-side app.
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
The approach you mention is much easier. However, it does make for slower perceived page load times, even when serializing JSON on the page, because the browser has to fetch, parse, and evaluate JS files before rendering the HTML into the document. This can take many hundreds of milliseconds, especially on mobile devices.

In my experience, server-side rendering has led to a much better UX.

frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
Correct. If you're already writing a bunch of JavaScript for the client-side, then just think about this approach as migrating some of that client, UI logic to the server.
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
(author) Cool! What's the JavaScript runtime on the server? Something JVM-based?
frontendbeauty··on Isomorphic JavaScript: The Future of Web Apps
(OP here) Probably your best bet is to create a small Node web service that takes a template name and data and returns HTML. Then your (Rails, Python, PHP) app can call out to that in the request cycle.

Instagram.com does something similar; it's a Django app.

frontendbeauty··on Ask HN: What are you working on and why is it cool?
That is just amazing. Keep it up.
frontendbeauty··on Introducing SmartStack: Service Discovery in the Cloud
Yep.
frontendbeauty··on We've Open-sourced Rendr
At the time of the previous post, Rendr was not yet open-sourced.
frontendbeauty··on We've Open-sourced Rendr
We're using Rendr in a few more apps in production, in progress. It's starting to eat away at our Rails site a bit.
frontendbeauty··on We've Open-sourced Rendr
https://www.airbnb.com/jobs :)
frontendbeauty··on We've Open-sourced Rendr
The app template is such an example, consuming the public GitHub API: https://github.com/airbnb/rendr-app-template

In the future, we'd like to come up with some more in-depth tutorials.

frontendbeauty··on We've Open-sourced Rendr
Yep! Because links use full URLs which get intercepted by JavaScript, if JS is disabled, you can still navigate around the app, getting full HTML from the server. Of course, any client-specific code wouldn't run (slideshows, etc).
frontendbeauty··on We've Open-sourced Rendr
SEO was our first concern, but then we realized performance was the big win. Serving the user a full page of HTML rather than waiting for JS to download before rendering HTML makes a big difference, especially on high-latency or low-bandwidth connections (mobile).

EDIT: We decided against using something like PhantomJS or node-chimera because why deal with a DOM if you don't have to? DOM is complicated and slow, compared to string-based templating. Plus, it's another moving part, another process to keep up and running. The Meteor guys aren't too excited about the PhantomJS approach either, and IIRC they'd like to be able to serve HTML without firing up a DOM.

frontendbeauty··on We've Open-sourced Rendr
This is exactly right. We still have 5 years worth of business logic in Rails, so we just expose a RESTful API as part of the Rails app. The same API is consumed by our iOS, Android, Mobile Web, and Desktop clients.
frontendbeauty··on We've Open-sourced Rendr
Thanks, fixed.
frontendbeauty··on Rendr - Use Backbone on both the server and client
Cool, I like that ViewModel pattern. You could certainly use that with Rendr.
frontendbeauty··on Rendr - Use Backbone on both the server and client
We are absolutely hiring! airbnb.com/jobs
frontendbeauty··on Chrome Extension Replaces Every Instance of ‘The Cloud’ With ‘My Butt’
http://cl.ly/image/0M2g1Z1G3G0M
frontendbeauty··on Simple user styles for popular websites
Awesome effort. Be careful, though, when you post screenshots of your Twitter, Facebook, Instagram feeds to the world to see -- don't forget that the people who you follow may see that as a breach of privacy. Very likely the things that we can see in those screenshots were never intended to be public.
frontendbeauty··on Simple user styles for popular websites
I imagine the custom styles would be hard to maintain on more rapidly-evolving products.
Page 1 of 2Next →