<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Birkir Gudjonsson on Medium]]></title>
        <description><![CDATA[Stories by Birkir Gudjonsson on Medium]]></description>
        <link>https://medium.com/@birkir.gudjonsson?source=rss-4eb1fa36ed28------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*5UIVGPO9xj0VCQ9h.jpg</url>
            <title>Stories by Birkir Gudjonsson on Medium</title>
            <link>https://medium.com/@birkir.gudjonsson?source=rss-4eb1fa36ed28------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 06:50:51 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@birkir.gudjonsson/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Rafmyntir & Kauphallir : Gjöldin & Biðin]]></title>
            <link>https://medium.com/@birkir.gudjonsson/rafmyntir-kauphallir-gj%C3%B6ldin-bi%C3%B0in-b4bee2fc7891?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/b4bee2fc7891</guid>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Sat, 17 Sep 2022 22:22:53 GMT</pubDate>
            <atom:updated>2022-09-17T22:22:53.970Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0nhYAdN-vMMwO3Muqhxf8g@2x.jpeg" /></figure><p>Eitt stærsta vandamálið við að fjárfesta í rafmyntum fyrir íslenskar krónur eru <strong>gjöldin </strong>og<strong> tíminn </strong>sem það tekur.</p><p>Allar helstu kauphallir í rafmyntaheiminum taka á móti evrum, ýmist greitt með SWIFT, SEPA eða kreditkorti. Sumir styðja bara greiðslukort, aðrir styðja bara banka millifærslur, og oft án útskýringa og engum fyrirvara, er hreinlega lokað fyrir einhvern möguleikann upp úr þurru.</p><p>Þá geta banka millifærslur tekið allt að fimm daga í framkvæmd og kostað hátt í 1700 krónur. Svo eru það gjaldeyrisviðskiptin, þ.e.a.s að breyta íslenskum krónum í evrur sem bankinn gerir áður en millifærslan er framkvæmd, en gengismunurinn getur hlupið á allt að 6–7 prósentum á kaup- og sölugengi.</p><p>Ókei, þó svo að mörgum þyki þetta almenn vitneskja, er eitt í þessu sem gleymist stundum að þessar kauphallir taka yfirleitt á móti rafmyntum, og það gjaldfrjálst, eins og til dæmis rafdollara (USDC).</p><p>Það væri því snilld ef við gætum keypt einhverskonar rafkrónur, skipt þeim í rafdollara og sent þá á kauphöllina gjaldfrjálst.</p><p><strong>En það er einmitt hægt núna!</strong></p><p><a href="https://www.sedlabanki.is/utgefid-efni/frettir-og-tilkynningar/frettasafn/frett/2022/07/08/Rafmyntasjodur-Islands-ehf.-skrad-sem-thjonustuveitandi-syndareigna/">Rafmyntasjóður Íslands</a> hefur nefnilega byrjað að gefa út Rafkrónu (ISKT), sem er gjaldgeng í Kauphöll þar sem hægt er að skipta þeim fyrir rafdollar (USDC) og öfugt.</p><p>Rafkrónan er fastgengismynt, sem þýðir að hún er bundin við íslenska krónu á genginu 1:1.</p><blockquote>Hver rafkróna í umferð er tryggð með einni íslenskri krónu (ISK) í eignasafni Rafmyntasjóðsins.</blockquote><p>Til að kynna sér málið betur má fara á <a href="https://beta.mintum.is/">Mintum</a>, sem er gátt Rafmyntasjóðs Íslands að rafkrónum.</p><p><a href="https://mintum.is/">Forsíða | Mintum</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b4bee2fc7891" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Dear Ueno: How do I pick and set up a CMS for my portfolio site?]]></title>
            <link>https://medium.com/ueno/dear-ueno-how-do-i-pick-and-set-up-a-cms-for-my-portfolio-site-eecedfb9ef9d?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/eecedfb9ef9d</guid>
            <category><![CDATA[headless-cms]]></category>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[dearueno]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Tue, 12 Feb 2019 19:29:07 GMT</pubDate>
            <atom:updated>2019-02-13T00:59:20.585Z</atom:updated>
            <content:encoded><![CDATA[<p><em>Dear Ueno is an advice column for people who for some weird reason think we know what we’re doing. Read </em><a href="https://medium.com/ueno/dear-ueno-b6946471b26a"><em>more about all this</em></a><em>, or check out our </em><a href="https://loremipsum.ueno.co/dear-ueno/"><em>old advice</em></a><em>.</em></p><p><strong><em>From Alfian Ridwan, a “learning and progressing” front-end developer in Singapore:</em></strong></p><blockquote>I’ve noticed that you use Contentful along with React and, I assume, Gatsby for the static website. Could you share with me how the process works?</blockquote><p><strong><em>Birkir Guðjónsson, Technical Director at Ueno NY is delighted to answer:</em></strong></p><p>Hi Alfian,</p><p>You are correct, we have used Contentful as a Content Management System (CMS) on multiple projects, but we don’t limit ourselves to that. What’s most important to us is that the system be headless (or decoupled) so we can write the website in our preferred programming language and not be tied to the CMS. This also means that it’s easier to swap out one system for another if and when the time comes.</p><h4>Picking a Content Management System</h4><p>Before selecting a CMS for a project, we ask a series of questions:</p><ul><li>How many people will use it, and is it affordable to the client? Systems have different pricing models for multiple users, and sometimes clients have a fixed budget for operating costs.</li><li>Does the project require dynamic content types? With dynamic content types users can create pages with multiple components.</li><li>Does it need to be self-hosted? Some clients want to keep everything behind a firewall or a closed network, where software-as-a-service is not an option.</li><li>Does it have to have multiple roles? Some clients have tens or even hundreds of users that will be operating the system in many different ways. Roles play a big role here.</li></ul><p>Contentful, the system you mentioned, is tried and true. We especially like it for enterprise projects that need advanced user management. But our go-to system is actually Prismic, mainly because it’s got a feature called <a href="https://prismic.io/feature/dynamic-layout-content-components">Slices</a> which is very powerful when it comes to creating building blocks for webpages. Using slices lets content writers compose pages with reusable components and offers greater flexibility than fixed templates.</p><p>Most hosted platforms offer a limited free plan. The free plan may work for you initially, but as your website or content team grows, you will have to start paying. Contentful limits the number of “Content Types” and “Documents” that you can create, while Prismic is more about the number of users. It may be a good idea to pick a self-hosted or open-source system like <a href="https://wordpress.com/">headless Wordpress</a>, <a href="https://strapi.io/">Strapi</a>, or — here comes a shameless plug — <a href="https://github.com/birkir/prime/">Prime CMS</a>, a simple system that I built myself.</p><p>Not everyone needs a CMS. The main reason for using a CMS is collaboration and maintainability. You could use simple JSON or Markdown files to store your content. You can even hard-code content into your codebase. This is our preferred method when we build one-off websites that don’t need editorial content updates.</p><h4>Picking the framework</h4><p>Some would call Ueno a “React” shop as we build pretty much everything with React and React Native. Nowadays we write all our code in TypeScript, the superset of JavaScript built by Microsoft. TypeScript ensures type safety in our code and reduces bugs.</p><p>In early 2017, we built our own Ueno React <a href="https://github.com/ueno-llc/starter-kit-universally">Starter Kit</a>, because we wanted to get our developers up and running faster with all the tools and libraries they needed. Since then the JavaScript community has progressed a lot, and today there are so many good React starter options out there. Some of them so good that we couldn’t pick just one, so we built a small tool called <a href="https://github.com/ueno-llc/create-ueno-app"><em>create-ueno-app</em></a><em>,</em> a command-line utility to bootstrap different projects with our stack.</p><p><a href="https://github.com/ueno-llc/create-ueno-app">ueno-llc/create-ueno-app</a></p><p>We have the option to select between three different React frameworks, <em>create-react-app,</em> Gatsby and NextJS. To figure out which one to use we, ask another set of questions:</p><ul><li>Do you need (or want) 500+ ready-to-use plugins? → Use Gatsby.</li><li>Do you want static render for better performance and reduced time to <a href="https://developers.google.com/web/tools/lighthouse/audits/first-meaningful-paint">first meaningful paint</a>? → Use Gatsby or NextJS.</li><li>Do you want a NodeJS server? → Use NextJS.</li><li>Are you building a web application that only needs client side code? → Use <em>create-react-app.</em></li></ul><p>Requirements aside, what it all comes down to is what you are most comfortable working with.</p><h4>The process</h4><p>We usually start off by building all the necessary React components and layout blocks for the provided design. This helps us think about the structure and picture how the content types will plug into the components.</p><p>React’s modular architecture is useful when a large team is working on a project because it lets us create components, content types in the CMS, and data-bind (the business logic that connects components to data from the CMS), all in parallel.</p><p>We use <a href="https://graphql.org/">GraphQL</a> to pull in data from content management systems. It is a flexible data query language that allows you to query data to match your use case and technical needs at each time.</p><p>Currently you have to contact Prismic and Contentful to have direct GraphQL access to your project but if you are using Gatsby you will have the benefit of using GraphQL without having direct access.</p><p>Gatsby has multiple CMS plugins that are easy to install and use with the <a href="https://www.gatsbyjs.org/plugins">Plugin Library</a>. Here are some of the plugins we regularly use:</p><ul><li><a href="https://www.gatsbyjs.org/packages/gatsby-source-contentful">gatsby-source-contentful</a></li><li><a href="https://www.gatsbyjs.org/packages/gatsby-source-prismic">gatsby-source-prismic</a></li><li><a href="https://www.gatsbyjs.org/packages/gatsby-source-prismic-graphql">gatsby-source-prismic-graphql</a></li><li><a href="https://www.gatsbyjs.org/packages/gatsby-source-graphql">gatsby-source-graphql</a></li></ul><p>The GraphQL query for fetching data is done by using the gql tag, like this:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/25dde15501937282753f9b5112a62276/href">https://medium.com/media/25dde15501937282753f9b5112a62276/href</a></iframe><p>And displaying the results with a React component looks like this:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2ae5c7b8f60738ccbfbf2acac3ff6329/href">https://medium.com/media/2ae5c7b8f60738ccbfbf2acac3ff6329/href</a></iframe><h4>Further information</h4><p>Here are some links to get you started on upgrading your portfolio using React and a headless CMS:</p><p>– Fantastic tutorials from Gatsby on how to build and source data from <a href="https://www.gatsbyjs.org/docs/sourcing-from-prismic/">Prismic</a> and <a href="https://www.gatsbyjs.org/docs/sourcing-from-contentful">Contentful</a>.<br>– Hacker Noon: <a href="https://hackernoon.com/building-a-blog-with-react-and-contentful-fd538f68f6fb">Building a Blog with React and Contentful</a><br>– <a href="https://github.com/birkir/prime">Prime</a>, the Open Source GraphQL CMS <br>– <a href="https://overreacted.io/">Dan Abromov’s blog</a> about React<br>– Bonus material: the one and only <a href="https://basarat.gitbooks.io/typescript/">TypeScript handbook</a></p><p>That’s more or less it. I hope this answers at least some of your questions. Best of luck with your portfolio!<br>— Birkir</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7v77rwYbNCpdeePOfsoI7w.jpeg" /></figure><p><em>Birkir Guðjónsson is Technical Director at Ueno in New York. He speaks Icelandic with a slight Akureyrish accent, but don’t let that scare you. Previously on this blog, he’s written about </em><a href="https://loremipsum.ueno.co/using-react-native-to-build-a-professional-consumer-apps-7c9c99cd0605"><em>using React Native to build professional consumer apps</em></a><em> and about </em><a href="https://loremipsum.ueno.co/everything-you-always-wanted-to-know-about-the-ueno-developers-starter-kit-fd46c0c6826f"><em>Ueno’s Starter Kit</em></a><em>. He’s </em><a href="https://github.com/birkir"><em>on Github</em></a><em>, duh.</em></p><p><strong><em>Want to work with Birkir?</em></strong><em> Check out </em><a href="https://www.ueno.co/careers"><em>our open positions</em></a><em>.</em></p><p><strong><em>Want more email? </em></strong><em>Seriously? Because </em><a href="https://www.ueno.co/newsletter"><em>Ueno has a newsletter</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eecedfb9ef9d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/ueno/dear-ueno-how-do-i-pick-and-set-up-a-cms-for-my-portfolio-site-eecedfb9ef9d">Dear Ueno: How do I pick and set up a CMS for my portfolio site?</a> was originally published in <a href="https://medium.com/ueno">Ueno.</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to re-create YouTube TV list animation in React Native]]></title>
            <link>https://medium.com/@birkir.gudjonsson/how-to-re-create-youtube-tv-list-animation-in-react-native-7477f004005e?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/7477f004005e</guid>
            <category><![CDATA[animate]]></category>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[experiment]]></category>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Mon, 10 Sep 2018 04:22:00 GMT</pubDate>
            <atom:updated>2019-03-01T20:26:53.240Z</atom:updated>
            <content:encoded><![CDATA[<p>One of the most recent UI features that I love to hate is in Google’s YouTube TV app. It’s the channel list with the parallax animation on the top but while I find it a very cool effect, there was something that bothered me about it. So I decided to build it to learn more about it.</p><p>You can follow this tutorial to see how to build the effect in React Native</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*EFaF9ShRpaGMqoEw9ndn8A.gif" /></figure><p>I gathered some nice data from <a href="https://www.themoviedb.org/">https://www.themoviedb.org/</a> that I used to populate the title and backdrop that I will be using in the demo.</p><p>The first step is to read data from the <a href="https://github.com/birkir/react-native-youtubetv-demo/blob/step/4/assets/items.json">JSON file</a> and render the rows into the ScrollView, I tried to make them look like the real thing from YouTube’s app.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/952/1*RNLampwglGR2uUswbYELxA.png" /></figure><p>We also need some kind of Row component</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0I3531qB9bc0UfHFUxeZdw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*6nfaPhXYFTeoN2P1lV6-eg.gif" /></figure><p>Try the first step on your device:</p><p><a href="https://snack.expo.io/@git/github.com/birkir/react-native-youtubetv-demo@step/1">github.com/birkir/react-native-youtubetv-demo@step/1</a></p><p>Next we need to split the row into two separate layers, I call them the Row and Preview.</p><p>The row layer is the white layer with 80px height, and the preview layer has 200px height and includes the background image. We need to animate those layers separately to achieve the desired effect.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QivYMVJUVaoDcfpMXl-JaQ.png" /></figure><p>Also we need to change our ScrollView to an Animated.ScrollView, attach the onScroll event to Animated Value and set some properties on the component.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ErTJ1gAYbra6hA4IoXSY_g.png" /></figure><p>The snapToInterval property does not work on Android. We can polyfill this behavior, but for the sake of the demo, we will just work with iOS for now.</p><p>It works by snap the scrollview to a our rows, so we don’t have to create the onScrollEnd and onMomentumScrollEnd handlers to scroll to the right row.</p><p>Next we need to pass the this.scrollY value down to our &lt;Row /&gt; components and interpolate the values to do some cool animations. We also include `index` property that we use to calculate the inputRange of the Row.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uE4Q24Xh2mgR8ufz6SLvSQ.png" /><figcaption>The magic inputRange interpolation</figcaption></figure><p>And this is what we got:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*P2HZyOYkSkPSz6K7Tv1jzA.gif" /></figure><p><a href="https://snack.expo.io/@git/github.com/birkir/react-native-youtubetv-demo@step/2">github.com/birkir/react-native-youtubetv-demo@step/2</a></p><p>Now that we can utilize the ScrollView’s animated value inside each row, with it’s index calculated as the inputRange, we can start to add more layers and interpolate them.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nDPaeKOHxhqaaVPXsLuH2g.png" /></figure><p>For the row, I settled with a Root View that translates DOWN, and an inner node that translates UP, so we get the illusion of a parallax effect. I also included a TouchableOpacity that I can use later to scroll to that Row.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*07NGBnc-vi6Fze-mDbzhOg.png" /></figure><p>For the preview, It’s a little bit more complicated. I needed a base node, a background node, overlay node and the title node.</p><p>I commented in simplified version of the interpolation for each node. The 20 value you can see, are arbitrary number that I choose to make the parallax effect a little slower than the scroll speed, It looks better that way.</p><p>I also added some styles, and this is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*ZSIL-UrKjDKHtS7_ftMmDQ.gif" /></figure><p><a href="https://snack.expo.io/@git/github.com/birkir/react-native-youtubetv-demo@step/3">github.com/birkir/react-native-youtubetv-demo@step/3</a></p><p>Last but not least, fine tuning and cleanup. I still have to fix the bottom overflowing, allow clicking the rows to scroll to them and add a progress bar.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XkeSH1zLARTMEymu95geHQ.png" /><figcaption>Calculating scrollview’s height</figcaption></figure><p>I am used to use native navigation and can get constants with heights of the Navbar, so I could calculate the above height from the device height and the constants. But as we’re using React Navigation, and to be safe, we will get the actual height of the scrollview and pass it into our Bottom view.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sUVbCgJG7xfcknUIJyo2kA.png" /><figcaption>Passing scrollTo method down to components</figcaption></figure><p>This may look weird to you. Most likely because you’re not used to React.createRef or accessing internal refs from Animated components.</p><p>React.createRef can be used to access component refs without custom functions. The only difference is that you have to access the reference through thecurrent property.</p><p>Next we have Animated, which composes the ScrollView component, but gives us access through a private property, _component . This is not completly safe and could change, but currently there is no other way of doing this.</p><p>Some updated styles and fine-tuning of the variables, you can see the result here:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*w-cZvZsk8uUPZgDZnXoPDg.gif" /></figure><p>Here is the final demo — <strong>iOS only, click the lower right corner to switch (Desktop)</strong></p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fsnack.expo.io%2Fembedded%2F%40birkir%2Fyoutube-tv-demo&amp;url=https%3A%2F%2Fsnack.expo.io%2F%40birkir%2Fyoutube-tv-demo%3Fplatform%3Dios&amp;image=https%3A%2F%2Fs3.amazonaws.com%2Fexp-brand-assets%2FExpoIcon_200.png&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=expo" width="700" height="500" frameborder="0" scrolling="no"><a href="https://medium.com/media/7d474df24e8b4b9d2b9b7efcf2709e0a/href">https://medium.com/media/7d474df24e8b4b9d2b9b7efcf2709e0a/href</a></iframe><p>On mobile, here is a direct link:</p><p><a href="https://snack.expo.io/@birkir/youtube-tv-demo">https://snack.expo.io/@birkir/youtube-tv-demo</a></p><p>Thanks for reading. I hope you enjoyed this experiment with me.</p><p>It shouldn’t be hard to add video playback and android support, maybe I’ll revisit later and update the tutorial.</p><p>Here is the full source code:</p><p><a href="https://github.com/birkir/react-native-youtubetv-demo">birkir/react-native-youtubetv-demo</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7477f004005e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Hekla for Hacker News with React Native and TypeScript]]></title>
            <link>https://medium.com/@birkir.gudjonsson/building-hekla-for-hacker-news-with-react-native-and-typescript-eba8d570ae2e?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/eba8d570ae2e</guid>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[typescript]]></category>
            <category><![CDATA[react-native-navigation]]></category>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Wed, 01 Aug 2018 16:51:25 GMT</pubDate>
            <atom:updated>2018-08-01T16:55:58.988Z</atom:updated>
            <content:encoded><![CDATA[<p>I really, really, really like <a href="https://itunes.apple.com/us/app/apollo-for-reddit/id979274575?mt=8">Apollo</a>, a beautiful and elegant Reddit client for iOS. I liked it so much that I wished there was a Hacker News client that had the same UI layout, a set of features and customizability.</p><p>I’ve been working on and maintaining a <a href="https://github.com/ueno-llc/react-native-starter">React Native starter kit</a> for Ueno for the past year, so I wanted to see how quickly I was able to use the kit to create my own Apollo-like client, just for Hacker News.</p><p>This is the result, 4 weekends later, an iOS and Android app using all the latest and greatest for React Native.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/943/1*7MGVcoZaplJqt4t9tfXLGw.png" /><figcaption>Beta Screenshots</figcaption></figure><p>It’s source code is available here:</p><p><a href="https://github.com/birkir/hekla">birkir/hekla</a></p><p>And you can download it here:</p><ul><li><a href="https://itunes.apple.com/us/app/hekla/id1405096983?mt=8">‎Hekla for Hacker News on the App Store</a></li><li><a href="https://play.google.com/store/apps/details?id=is.pipe.hekla">Hekla - Apps on Google Play</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eba8d570ae2e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using React Native to build professional consumer apps]]></title>
            <link>https://medium.com/ueno/using-react-native-to-build-a-professional-consumer-apps-7c9c99cd0605?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/7c9c99cd0605</guid>
            <category><![CDATA[development]]></category>
            <category><![CDATA[react-native-starter-kit]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[ueno]]></category>
            <category><![CDATA[react-native]]></category>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Tue, 20 Feb 2018 16:34:55 GMT</pubDate>
            <atom:updated>2018-02-23T20:38:00.460Z</atom:updated>
            <content:encoded><![CDATA[<h4>At Ueno, we built our own starter kit for React Native. Why did we do it? How did we do it? Read on.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZvxnvFkTfbsMNLepuHQHqg.jpeg" /></figure><p>React Native has grown massively since it was open-sourced by Facebook back in 2015. Today, it’s used by serious companies like Walmart, Bloomberg and Tesla, developers have access to more than <a href="https://js.coach/?collection=React+Native">two thousand libraries and tools</a> for it, and, most importantly, there’s a very <a href="https://github.com/facebook/react-native/graphs/contributors">large community</a> to back it up.</p><p>At Ueno, we started fiddling around with React Native in early 2016. We’d had a good experience with React, and Native looked really promising and easy to develop for. But at the time, we found that it was not quite there yet in terms of stability. We didn’t really think it was in good enough shape for us to use it to build professional consumer apps.</p><p>About year later, Facebook and <a href="https://expo.io/">Expo</a> released <a href="https://facebook.github.io/react-native/blog/2017/03/13/introducing-create-react-native-app.html"><em>create-react-native-app</em></a><em>,</em> a starter kit to make crafting apps easy and hassle-free. So we took another look, and found that while it would be great for beginners and entry-level developers who need to get things quickly up and running for prototyping, the starter kit still had too many drawbacks for professional use — it’s too slow, it doesn’t offer native navigation, you can’t control the build system or install third party native dependencies, you can’t modify existing native code, and continuous integration and delivery isn’t what you’d hope it to be.</p><p>We liked the idea of a starter kit, but clearly <em>create-react-native-app</em> wasn’t for us. So we decided to make our own.</p><h3>The beginning of Ueno’s React starter kit</h3><p>As we set out to assemble our own starter kit, it was important to us that our it be well documented, with carefully selected opinionated dependencies, and it had to be automation-ready.</p><p>For great apps, navigation is key. We choose <strong>react-native-navigation</strong> because it has a large community, it’s in active development, and it’s easy to contribute to. All screens are created on the native level, with their own React context, which gives it way better performance than <strong>react-navigation,</strong> the solution that create-react-native-app uses.</p><p>To deliver updates of assets and runtime code we use <strong>code-push</strong>. That way, every commit to the repository results in updates over-the-air to test devices within 30 minutes or so. Everything happens automatically, and for soft launches we can even control how many users get the update. To avoid conflicts, the library takes care of matching native app version with the built JS bundle.</p><p>Managing environment variables with <strong>react-native-config</strong> is necessary to control the environment for different build states. We keep secret environment variables within Travis so they are not exposed to the outside world, even in pull-requests.</p><p>In the documentation, you can find a <a href="https://ueno-llc.github.io/react-native-starter/#/FEATURES">list of all the features</a>.</p><p><a href="https://github.com/ueno-llc/react-native-starter">ueno-llc/react-native-starter</a></p><h3>Modifying libraries</h3><p>We use community driven libraries and tools extensively in the Ueno starter kit. But sometimes we need to go off the norm and modify a library so it fits our needs better.</p><p>We use <a href="https://github.com/ds300/patch-package">this great solution</a> where you can automatically patch node_modules files after installing so we just include patch files with the repository and everybody will get the same patched codebase after install. Currently we are mostly patching libraries that have a missing Podspec file.</p><p>If we think other people can use our modifications, we open a pull-request to the source library and try to get it accepted so we don’t have to keep a local copy. One example where we did this was with 3D Touch for react-native-navigation.</p><p><a href="https://github.com/wix/react-native-navigation/pull/2186">3D Touch Preview API by birkir · Pull Request #2186 · wix/react-native-navigation</a></p><h3>Testing and linting</h3><p>We use <strong>eslint</strong> to ensure quality code standard, and run series of tests on every commit in every branch on a CI. We even have <a href="https://www.npmjs.com/package/@ueno/eslint-config">our very own</a> ruleset (a superset of Airbnb’s config).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/463/1*Rdp96HCsbsPyALskv9rM5A.png" /></figure><p>Unit testing is something we want to do more of. We always have at least basic ones that test that the whole app renders.</p><p>We use <strong>jest</strong> to write the tests and <strong>enzyme</strong> as a test runner.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/95b80cd5374a53bd9d1d9cf706c6683b/href">https://medium.com/media/95b80cd5374a53bd9d1d9cf706c6683b/href</a></iframe><p>Integration testing (E2E) we do with a tool called <strong>detox</strong>. Created by Wix, it works by running the app in simulator where it does whatever we want it to do by writing code that scrolls, swipes, presses buttons, etc. We then write comparison tests with jest or mocha.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1d7ee12362c366dc93ffefeaafc951b9/href">https://medium.com/media/1d7ee12362c366dc93ffefeaafc951b9/href</a></iframe><p>Testing is hard but it makes delivering continuously so much easier. And we do love to automate all things.</p><h3>Continuous delivery</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/679/1*0ZrbPH2Wrli9OY54LXrm7g.png" /><figcaption>Flowchart of the pipeline</figcaption></figure><p>Imagine merging a pull-request on GitHub, and 30 minutes later your QA team being able to test the feature on their device and give you an report.</p><p>This is where testing is crucial because you wouldn’t want to automatically deploy a broken build and waste time in reporting, investigating and rollbacking.</p><p>There are a lot of moving parts involved in Continuous Delivery. We have been using Travis for a long time along with GitHub and it has worked well for us. Only thing we can complain about is that build times are slow on the OSX images (compared to Bitrise which we also use occasionally).</p><ul><li>Commits on master are automatically built on Travis/Bitrise.</li><li>Code-push delivers JavaScript and other assets over-the-air to Staging</li><li>Detect native code changes in ios or android folder (or forced build via commit message) and if so, build native iOS and Android releases and upload to iTunes Connect and Google Play Store.</li><li>Staging changes can be tested on iOS in TestFlight or Android Beta channel.</li><li>Manual promotion of Staging to Production when green light is given for release.</li></ul><h3><strong>Analytics and user engagement</strong></h3><p>We don’t want to release an app without being able to measure its usage, growth and traction.</p><p>We like using Firebase as an all-in-one solution for app analytics, user engagement and growth. Most of the data can be shared between their products which makes it a nice one-stop shop.</p><ul><li>Authentication (Anonymous/OAuth/Credentials)</li><li>Cloud Messages (Push Notifications)</li><li>Invitations (SMS, E-Mail and more)</li><li>Realtime Database (JSON)</li><li>Storage and Web hosting</li><li>Analytics (Screens, installs, audience targeting and more)</li><li>Dynamic Links (Deep linking)</li><li>Crash Reporting</li><li>Performance Monitoring</li><li>Adwords and Admob (Display ads in your app)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1006/1*E_AzcXUts0zKTOw1g9DR_A.png" /></figure><p><a href="https://github.com/invertase/react-native-firebase">invertase/react-native-firebase</a></p><h3><strong>Error reporting</strong></h3><p>In our experience, bugs happen more often in react-native projects because of the <em>extremely</em> fast release cycle, so catching them and fixing is crucial.</p><p>We have used Sentry, Firebase, Bugsnag and Crashlytics with good results in the past but we tend to like <strong>Sentry</strong> the best because it has very good react-native and code-push integration that shows mixed stack traces (native and JS).</p><p>(By the way, Crashlytics has now become a part of Firebase. Also, Bugsnag recently announced great code-push relationship, so we may give it another go in the future.)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VYUOE2R2IWirDaTJvGCgsg.png" /><figcaption>Sentry Stack Trace page</figcaption></figure><h3>In conclusion</h3><p>To come back to our original question: is React Native solid enough to build a professional consumer apps? Yes. And with the Ueno starter kit, it’s even better.</p><p>→ <a href="https://github.com/ueno-llc/react-native-starter"><strong>Get the Ueno Starter Kit on Github</strong></a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zapfPHqqtWpFrrKEVdEB-Q.jpeg" /></figure><p><em>Birkir Guðjónsson is a software engineer at Ueno in New York. He speaks Icelandic with a slight Akureyrish accent, but don’t let that stop you. He’s </em><a href="https://github.com/birkir"><em>on Github</em></a><em>, duh. Want to work with him? Check out </em><a href="https://www.ueno.co/careers"><em>our open positions</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7c9c99cd0605" width="1" height="1" alt=""><hr><p><a href="https://medium.com/ueno/using-react-native-to-build-a-professional-consumer-apps-7c9c99cd0605">Using React Native to build professional consumer apps</a> was originally published in <a href="https://medium.com/ueno">Ueno.</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Everything you always wanted to know about the Ueno Developer’s Starter Kit]]></title>
            <link>https://medium.com/ueno/everything-you-always-wanted-to-know-about-the-ueno-developers-starter-kit-fd46c0c6826f?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/fd46c0c6826f</guid>
            <category><![CDATA[development]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[react-native]]></category>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Thu, 03 Aug 2017 17:08:09 GMT</pubDate>
            <atom:updated>2017-11-15T16:09:36.964Z</atom:updated>
            <content:encoded><![CDATA[<h4>Why we use it, what’s in it and what’s not.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uNQOG56OztpqlWSWUhQR4Q.png" /><figcaption><a href="http://martinazambuja.com/">Martin Azambuja</a></figcaption></figure><p>On my way to the Ueno developers summit in Reykjavík, I thought it might be a good idea to write a few words about why we went to the trouble of creating our own starter kit, what’s different about it, and why we keep it open source.</p><p>From day one, we’ve been using React for most of the projects we’ve crafted at Ueno. With every new project, we used to copy what we did on the previous project, remove everything but the boilerplate, add a few tools and refactor the code a bit. Rinse and repeat.</p><p>Eventually we created our first simple <a href="https://github.com/ueno-llc/starter-kit-historical">starter kit</a> so we wouldn’t have to go through this painful procedure every time we started a project, with the goal of getting our developers up and running faster with all the tools and libraries they needed.</p><p>But when we discovered how much hassle it was to maintain a starter kit with the javascript world moving at the speed of sound, we decided to deprecate our first kit and <a href="https://github.com/ueno-llc/starter-kit-universally">create a fork</a> of another one we found, <a href="https://github.com/ctrlplusb/react-universally">react-universally</a>. Very similar to ours, but in active maintenance, react-universally has served us well, and we have contributed a lot to the code.</p><p>As you probably know, Facebook also created their own starter kit, <a href="https://github.com/facebookincubator/create-react-app">create-react-app</a>, developed by the React community, and maintained by Facebook. It includes all the basics needed to get started, which is why it’s used by a lot of developers.</p><p>So why didn’t we just use that?</p><p>The answer is that even though create-react-app has been great add-on for the community — we’ve even used it for some projects — it’s missing a few crucial features that we need for our development workflow to be able to work fast, structured and efficient, the two most important being server-side rendering, and CSS Modules or CSS pre-processors:</p><p><strong>Server-side rendering: </strong>It’s very hard to do, and it’s something most React developers just don’t want to deal with. Our starter kit includes it by default, thus enabling users without javascript to see the page. Time to first meaningful paint is reduced drastically.</p><p><strong>CSS modules and CSS pre-processors:</strong> These are very important to us. We are design-first-oriented front-end developers, and we want to have all the tools available to be able to maintain and apply those beautifully designed pixels to the screen.</p><p>Another thing we need that isn’t included in create-react-app is <strong>code linting </strong>to predefined standards. It reduces overhead of adjusting to the code, keeps thing tidy and clean. We include <strong>eslint,</strong> extending the <a href="https://github.com/airbnb/javascript">airbnb style guide</a> and stylelint with our own set of rules. Optionally we have available git hooks that run the linting operation before committing to GitHub.</p><p>Two dependencies that are absolutely crucial to us (that create-react-app actually does include) are <strong>Webpack</strong> and <strong>Babel:</strong></p><p><strong>Webpack</strong> is a bundler that takes all your code and packs (or compiles) it into single files. Webpack supports loaders that work by applying logic to files that go <strong>in</strong> to the bundler, and plugins that are applied usually on the code coming <strong>out</strong> of the bundler.</p><p><strong>Babel</strong> is a transpiler, that allows you to write modern javascript that works in the targets you choose (IE8, node, etc.). It also enables JSX support, so writing React gets easier and is clearer to read.</p><p>All in all there are over 90 dependencies in the Ueno starter pack … we try our best to keep them up to date.</p><p>We encourage anyone who has needs similar to ours to check it out, use it, and contribute to it if they think something’s missing.</p><p>And if you just want to get started kit, the quickest way if you have already git and node is this:</p><pre>git clone <a href="http://github.com/ueno-llc/starter-kit-universally">http://github.com/ueno-llc/starter-kit-universally</a> project<br>cd project<br>npm install<br>npm run dev</pre><p>Head to the project’s <a href="https://github.com/ueno-llc/starter-kit-universally/blob/master/README.md">README</a> for more information.</p><p>Thanks for reading!</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fupscri.be%2F9ff108%3Fas_embed%3Dtrue&amp;dntp=1&amp;url=https%3A%2F%2Fupscri.be%2F9ff108%2F&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=upscri" width="800" height="400" frameborder="0" scrolling="no"><a href="https://medium.com/media/0ab8a34c9014698c61343e5b02314cdd/href">https://medium.com/media/0ab8a34c9014698c61343e5b02314cdd/href</a></iframe><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fd46c0c6826f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/ueno/everything-you-always-wanted-to-know-about-the-ueno-developers-starter-kit-fd46c0c6826f">Everything you always wanted to know about the Ueno Developer’s Starter Kit</a> was originally published in <a href="https://medium.com/ueno">Ueno.</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[✨ Another approach to render asynchronous redux app on the server]]></title>
            <link>https://medium.com/@birkir.gudjonsson/server-side-react-redux-experiment-43e0e1f76a30?source=rss-4eb1fa36ed28------2</link>
            <guid isPermaLink="false">https://medium.com/p/43e0e1f76a30</guid>
            <category><![CDATA[universal]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[redux]]></category>
            <dc:creator><![CDATA[Birkir Gudjonsson]]></dc:creator>
            <pubDate>Thu, 16 Jun 2016 18:48:35 GMT</pubDate>
            <atom:updated>2016-06-18T09:53:43.753Z</atom:updated>
            <content:encoded><![CDATA[<p>I’m Birkir Gudjonsson, software engineer currently living in Reykjavík, Iceland and working for <a href="https://ueno.co/">UENO</a>. (a digital agency based in SF). We craft web-sites and apps for some pretty big names, using all the awesome tools and frameworks that the JS Gods have given us.</p><p>So most people render their React app only on the client while others also render on the server, often called Universal, which most of our clients usually want.</p><p>The easiest server render approach is to manually fetch the data needed and inject it into the state before rendering. Dan Abramov <a href="http://redux.js.org/docs/recipes/ServerRendering.html">demonstrates</a> how this can be achieved in the redux docs 📘.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f18b14d5e3670ebf5a4e12060720b7e2/href">https://medium.com/media/f18b14d5e3670ebf5a4e12060720b7e2/href</a></iframe><p>The problem here is that your state becomes inconsistent between the client and the server because the redux actions don’t handle adding data to the state like they do on the client.</p><p>Other, more <a href="https://www.codementor.io/reactjs/tutorial/redux-server-rendering-react-router-universal-web-app">dynamic approach</a> is to use the react-router’s “<strong>match”</strong> method to get a component tree from the router, parse it and find components that contain a special method that dispatches an async action, waits for them to resolve and then renders.</p><p><strong>This method is limited to route components only, and all later actions that might happen as an result won’t 🔥 .</strong></p><h3>OK, now what…</h3><p>After chasing the same problem in <a href="https://github.com/birkir/react-starter-kit-rdb">another project</a> involving rethinkdb (which is <a href="https://rethinkdb.com/docs/changefeeds/javascript/">pretty async</a>, right? 😎), I went in similar direction, only with these principles in mind.</p><ol><li>We need to handle all connected components, not just route components.</li><li>The redux actions can flow pretty far before we want to render.</li><li>Render before action flow completes within given timeframe.</li></ol><p>Add this tiny reducer function so we now know which action type is being dispatched in all subscription methods. 🐜</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ee9963523dec8ab8ba82dda2875b5935/href">https://medium.com/media/ee9963523dec8ab8ba82dda2875b5935/href</a></iframe><p>Next, you may need to rename some of your action types, because most of the magic 🎩🐇 lies in this part.</p><p>By appending “_AWAIT” to a action constant, we can tell that this action will be a promise, that will not execute imminently. When this particular action will complete, we dispatch similarly named action, but instead of the AWAIT suffix we use <strong>SUCCESS 👍 </strong>or <strong>FAILED 👎</strong>.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2e549673cee526cbd4344a7182317965/href">https://medium.com/media/2e549673cee526cbd4344a7182317965/href</a></iframe><p>So if I stick to the naming convention, I can write a listener function that monitors these kinds of actions, and makes decisions about waiting or rendering.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f4f3d55a8775bfd523ae34aad9da7b90/href">https://medium.com/media/f4f3d55a8775bfd523ae34aad9da7b90/href</a></iframe><p>Please checkout the github demo below which I based on this approach and give it a shot 🔫, also let me know if you have any comments or better solutions to the problem.</p><blockquote><a href="https://github.com/birkir/universal-redux-demo">https://github.com/birkir/universal-redux-demo</a></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*4NqyVE_01n9eiCSIvi1o1Q.gif" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=43e0e1f76a30" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>