5 ms·
WalmartLabs opensources its tool for bringing React Native to mobile apps
- jakebasile 9y agoIf their Lacinia GraphQL library for Clojure [1] is any indication of code quality, this should be very useful. I’m very impressed with the former, and I’ll be sure to look this new one over. 1: https://github.com/walmartlabs/lacinia https://github.com/walmartlabs/lacinia
- briandear 9y agoWhy a company the size of Walmart does this cross platform crap is beyond me. Do they not have the resources to actually write real native apps in actual Swift? Why is it desirable to code to the the worst common denominators for devices? Cross platform is just lazy. And React “Native” is inferior to actual native.
- mrmondo 9y agoAbsolutely agree, I avoid react / JavaScript ‘apps’ at all cost, they perform poorly, use excessive resources and seem to discourage an engineering mindset when writing code.
- deleted 9y ago[deleted]
- kcorbitt 9y agoOut of curiousity, how are you able to detect React Native apps so you can avoid them? Facebook introduced React Native to their main app months before anyone noticed. Airbnb also was using it for a while before they publicly announced the fact.
- deleted 9y ago[deleted]
- blkhp19 9y agoAt Airbnb, most core flows (search, home booking, map, trips/itinerary, inbox / messaging, the signup/login screen, profile, settings, and the hosting flow for listing your place) are all native. Most screens are built using a declarative abstraction on top of UICollectionView and UITableView. The Trips tab in the app (itinerary) was actually rewritten in native after originally being implemented using RN. It’s really too bad that people have this perception of RN’s use at Airbnb. I feel like people assume the whole thing is RN, which couldn’t be more wrong.
- mrmondo 9y agoYeah it's pretty easy to tell, even if they've been modified to not look like a browser frame if you notice poor performance or increased memory usage you just have a look in activity monitor or ps and you'll quickly see the javascript web workers etc...
- kcorbitt 9y agoIt sounds like you're talking about electron-style desktop apps, not React Native? They're quite different in architecture and performance.
- missbit 9y agohow about flutter or is it just a dream at this point?
- faceyspacey 9y agoUltimately the declarative way of writing apps is objectively better and more predictable than the old mutable way :) Now that said, I agree on the performance costs, and too wonder why Walmart is hellbent on this strategy, given the endless resources they have. But at the end of the day, they have a head of engineering and need to make their lives simpler just like everyone else. If you know how to squeeze the performance out of RN/React, developing apps in the semi-FP declarative sate-driven way is a dream compared to all the old ways of client app development. People who's views are so against React/ReactNative usually haven't experienced it for themselves. I suggest really giving it try before making these comments which usually serve just to validate decisions already made. I.e. to make one's self feel better about sticking to the old ways. However, I totally understand what it feels like for new tools to pop up that put into question old ways I've invested a lot into. That said, don't you think you'd be better off fully exploring these ways before shooting them down? Don't tell me you have--zero people that have grokked the effectiveness of declarative state-driven programming make these remarks. They usually leave some hint at their experience with React. In short, it's only you left in the dust :) Give the tools a try, which I know will likely be hard for you because you are likely coming from the Native world. I will say this: it's a lot more than just one language to make hybrid apps (i.e. like past tools such as Titanium). And, of course perf will be a challenge. That said, the perf is amazing given what it is. But more importantly, the style of development is what it's all about. It's so different and so much more predictable/debuggable than the old mutable ways. To me, it matters not that it's in JS. What matters is the declarative state driven way of development. If you can do that in native code, you're basically doing the most important aspect--and basically there's no argument from me there. There are some libraries that allow for that, but it's nowhere near the extent of what you can do in React/JS, given its ecosystem. I lot of work is being put in here to make this the best of breed future of application development. If you can't see it, you're missing out. Do your homework on React once and for all. You can thank me later. Last point: Walmart's tool here is specifically meant for making apps where some of it you want in "actual native" and other parts in "react native." Without a doubt coding the React style is the best DX for UI development. AND without a doubt, "actual native" performs far FAR better. So what they have here is a toolbox for those with an "engineering mindset" to pick the best tool for the job. Everything that's happening is just getting better and better for all parties involved, no matter where your experience lies.
- ComputerGuru 9y agoIt's this assumption that "same experience on all platforms" (aka "branding") is desirable to "native experience on all platforms". Facebook wants facebook to feel like facebook whether you're on an iPhone or an Android or your PC. Same with Chrome - it eschews native platform UI on all devices in favor of looking the same everywhere. Good UI - by definition - doesn't get in your way. But "good UI" may not be "good marketing" or "good branding" and these companies are placing a premium on their brand at the cost of the user experience. Good apps should _embrace_ rather than eschew the platforms they run on and their windowing toolkits so that their users can focus on the content rather than the presentation. Think about it - how many people (as a percentage of users of an app) will use it on multiple platforms? (Windows and Mac or iPhone and Android?) How many people use facebook _both_ in the mobile browser _and_ via the app on the same device? (Especially given the obnoxious trend to block access to the website if a native app is available cough reddit cough pinterest cough messenger cough). Not many at all. Hubris also comes into play. Obviously the UI models used in xxx platform are not perfect, but every app designer thinks "users will prefer this over xxxx's default, no question about it" because they view their layout/navigation/ui/style to be the greatest thing since sliced bread and cannot fathom that users might actually prefer the device's native windowing/widget toolkits to their abomination.
- colomon 9y agoI use OS X (laptop), Windows (VM), Android (phone), and iOS (iPad). It's not at all unusual for me to have apps installed on at least three of those platforms, and I really appreciate it when the UI is the same across platforms.
- toephu2 9y agoDo you think you represent 99% of the population?
- abiox 9y ago> But "good UI" may not be "good marketing" or "good branding" and these companies are placing a premium on their brand at the cost of the user experience. it's unclear where 'at the cost of the user experience' comes in. you say that good ui "doesn't get in the way", and later that platform windowing toolkits should be used to avoid distraction. this seems to suggest that platform toolkits are "good ui". aside from branding, one driving force for cross-platform ui is that some don't agree with the premise of platform uis being "good ui". > Think about it - how many people (as a percentage of users of an app) will use it on multiple platforms? depending on the region, i'd wager a lot, actually. > Hubris also comes into play. Obviously the UI models used in xxx platform are not perfect, but every app designer thinks "users will prefer this over xxxx's default, no question about it" (...) do any compare various options and using their reason, experience and advice, and then conclude a particular choice is preferable because of it's properties and characteristics? > (...) because they view their layout/navigation/ui/style to be the greatest thing since sliced bread and cannot fathom that users might actually prefer the device's native windowing/widget toolkits to their abomination. how many people are we talking about? truly it is terrible for the fascist designer to impose their design abomination upon the beleaguered users. ...but what about the liberated users no longer under the savage yoke of the gross and repellent 'native widget toolkit'?
- krapp 9y agoLikely Walmart feels this costs them less in the long run. The goal here is not to develop the highest quality software possible, it's to engage and capture customers as quickly and cheaply as possible, and to keep the cost of maintaining, updating and deploying that code as low as possible.
- nerdponx 9y agoJust because you have the resources do so some particular thing doesn't mean you should spend those resources doing that thing.
- HNSucksAss 9y agoI don't understand the point of this. Why "integrate" React into a native app? So you can just have a native shell of sorts, with the business logic written in React so it's portable?
- Dowwie 9y agoAre these discards from the jet.com acquisition or actual critical path libraries?
- mcescalante 9y agoWalmart acquired a company called Kosmix in 2011 and spun it out as a research division called @WalmartLabs [1]. Walmart acquired the online retailer, Jet.com in late 2016 which still has their own engineering team (using a lot of F#) Stuff coming from @WalmartLabs is almost always real stuff that Walmart is using in production (website, apps, etc.) [1] https://en.wikipedia.org/wiki/@WalmartLabs https://en.wikipedia.org/wiki/@WalmartLabs
- qmarchi 9y agoYup! A portion of Electrode is being used inside of the Walmart.com app.
- brianwawok 9y agoNo, Walmartlabs is the SV based version of walmart meant to build a walmart.com 3rd party merchant amazon killer. They use a lot of node and JS. Jet.com is a NY based startup. They use F#. They have quite separate code bases, and as far as I can tell no plans to merge them.
- rboyd 9y agoit's interesting to see the react-native detractors in this thread vs an Ask HN thread we had about react-native a couple of weeks ago. I wonder how many people could really determine an app's usage of RN in a blind taste test. could the disdain for js the language and bad memories of wrapped webviews be bleeding over? in our experience RN has offered a ton of leverage for a small team, and js makes a fine target to transpile to (we use cljs).
- qmarchi 9y agoFrom the testing we've done internally, not much difference between React Native, Xamarin, Native and Cordova. Was it scientific? Nope. But most couldn't tell.
- jjeaff 9y agoWe are in the process of rebuilding our app in react native. As a test, we created a portion of it in react native and did a side by side. Our app is your basic slide out navigation with pages and forms and some animation. There is literally no detectable difference. The only thing that I am still not sure of is performance on older devices. But on iPhone 6 and Galaxy S7... I wish we had started with react native from the beginning.