<?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[Golee Tech - Medium]]></title>
        <description><![CDATA[Golee Tech - Medium]]></description>
        <link>https://medium.com/golee-engineering?source=rss----b9ab719cc19f---4</link>
        <image>
            <url>https://cdn-images-1.medium.com/proxy/1*TGH72Nnw24QL3iV9IOm4VA.png</url>
            <title>Golee Tech - Medium</title>
            <link>https://medium.com/golee-engineering?source=rss----b9ab719cc19f---4</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 04:59:34 GMT</lastBuildDate>
        <atom:link href="https://medium.com/feed/golee-engineering" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Continuous Integration with Bitrise for iOS native app]]></title>
            <link>https://medium.com/golee-engineering/continuous-integration-with-bitrise-for-ios-native-app-7536fd2d121c?source=rss----b9ab719cc19f---4</link>
            <guid isPermaLink="false">https://medium.com/p/7536fd2d121c</guid>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[fastlane]]></category>
            <category><![CDATA[continuous-integration]]></category>
            <category><![CDATA[bitrise]]></category>
            <category><![CDATA[crashlytics]]></category>
            <dc:creator><![CDATA[Matteo Collina]]></dc:creator>
            <pubDate>Fri, 27 Apr 2018 15:52:28 GMT</pubDate>
            <atom:updated>2018-04-27T15:53:31.331Z</atom:updated>
            <content:encoded><![CDATA[<p>This was my first experience with CI. We needed a service that would help us deploy native mobile apps (I took care of the iOS app).</p><p>We have found a service that accompanies you from the configuration of the project to the creation of the pipeline… <a href="https://www.bitrise.io/">Bitrise</a> !</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/498/1*gIOeueD77xIXLo_9tMWKeQ.gif" /></figure><p>It allows you to do a free trial of the service for 30 days, after which you can subscribe to a subscription. For more information visit the <a href="https://www.bitrise.io/pricing">prices page</a>.</p><h4>Configuration</h4><p>The first configuration is very intuitive. There is a wizard that allows you to link the Bitbucket / Github account via link and set the SSH key in your repository account.</p><p>Bitrise checks whether a Carthage file or a Fastfile already exists in your iOS project and allows you to create the appropriate step.</p><h4>Let’s start!</h4><p>Once the configuration is finished, you can access the dashboard.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xp8UCFGnK-B9_QSITUZWHA.png" /></figure><ol><li>In the &quot;<strong>Build</strong>&quot; tab are all bitrate builds. There is a &quot;Deploy to Bitrise&quot; step that allows you to keep all your own. Each build will be identified by a color: green if everything went well, yellow if the manual abort was made or red if it failed.</li><li>&quot;<strong>Workflows</strong>&quot; is the heart of Bitrise. It allows you to create pipelines with steps that you can select from a wide choice made available by the system. In case there should not be what is right for you, you can always choose the &quot;Script&quot; step that identifies a shell.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z_LjMqd4mFRmvjqXTEV7mQ.png" /></figure><ul><li>This tab opens a page where there is a section to load <em>provisioning profiles</em> and certificates (development, ad-hoc, production).</li><li>Another page where you can insert <em>environment variables</em> to use in your scripts, for all workflows or only specific for some of them.</li><li><em>Trigger</em> allows you to configure the activation of a workflow when an action (push, pull, merge) is performed on a branch of your repository. In case you are using Bitbucket, you have to go to “<em>Settings / Webhoocks</em>” and configure the various actions to be managed by Bitrise.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/718/1*EE-P6vhJf1uYF2KpgXvggA.png" /></figure><ul><li><em>bitrise.yml</em> shows you the .yml file generated by the insertion of the various steps in the workflows.</li></ul><h4>An example please?</h4><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F26FL0X4d3Epuecpj2%2Ftwitter%2Fiframe&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F26FL0X4d3Epuecpj2%2Fgiphy.gif&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F26FL0X4d3Epuecpj2%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="241" frameborder="0" scrolling="no"><a href="https://medium.com/media/c6da3c52923737d1432f97494cbc5bb4/href">https://medium.com/media/c6da3c52923737d1432f97494cbc5bb4/href</a></iframe><p>An example of &quot;workflow&quot; to deploy on <a href="https://fabric.io/kits/ios/crashlytics">Crashlytics</a>, a powerful crash reporting tool by Fabric, consists of the following steps:</p><ul><li>Activate SSH key (RSA private key) : This step is automatically inserted by Bitrise when you make the initial configuration. It allows you to download your private repository.</li><li>Git Clone Repository : This step is also provided by Bitrise and by inserting the URL of the repository, the “pull” of the project is done.</li><li>Certificate and profile installer : Downloads and installs the certificate and the mobile provisioning profiles you uploaded in the “Code signing” section.</li><li>Run CocoaPods install : This step is necessary if you download dependencies (.framework) via CocoaPods. In my project I have a Podfile that specifies the names of the frameworks and any versions to download. The “Carthage” step is also present if you use that service.</li><li>Deploy to Bitrise.io : You&#39;ll see the deployed files on bitrise.io, on the build&#39;s page, in the &quot;Apps and Artifacts&quot; section.</li><li>fastlane : I used it to generate the IPA file and to handle the deployment on Crashlytics. <a href="https://docs.fastlane.tools/getting-started/ios/setup/">Fastlane</a> is a very useful service that allows you to replace difficult terminal commands with much simpler ones. It is necessary to create a “fastlane” folder with a “Fastfile” file inside that may contain different “lanes”, with different configurations.</li></ul><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e4041aa8e4503021c1595a806939ae7e/href">https://medium.com/media/e4041aa8e4503021c1595a806939ae7e/href</a></iframe><figure><img alt="" src="https://cdn-images-1.medium.com/max/256/1*FdO3ZT3poCzP_C5ufMYuag.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7536fd2d121c" width="1" height="1" alt=""><hr><p><a href="https://medium.com/golee-engineering/continuous-integration-with-bitrise-for-ios-native-app-7536fd2d121c">Continuous Integration with Bitrise for iOS native app</a> was originally published in <a href="https://medium.com/golee-engineering">Golee Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Golee tech culture, l’isola che non c’e’]]></title>
            <link>https://medium.com/golee-engineering/golee-tech-culture-lisola-che-non-c-e-715c597e9d70?source=rss----b9ab719cc19f---4</link>
            <guid isPermaLink="false">https://medium.com/p/715c597e9d70</guid>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[team-building]]></category>
            <category><![CDATA[culture]]></category>
            <dc:creator><![CDATA[creep sound]]></dc:creator>
            <pubDate>Sun, 22 Apr 2018 14:38:58 GMT</pubDate>
            <atom:updated>2018-04-22T14:38:57.789Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<p>Il team tecnologico di golee.it si descrive con pochi giri di parole: pochi ma buoni.<br>Se cerchi un lavoro dove ti venga detto cosa fare, golee.it non fa per te.<br>Se cerchi un lavoro dove quando hai concluso qualcun altro controlla la qualità del tuo operato, golee.it non fa per te.<br>Se cerchi un posto di lavoro che ti viene presentato come perfetto, golee.it non fa per te.<br>Se cerchi un progetto dove poter sperimentare con coscienza e razionalita’, golee.it fa per te.<br>Se cerchi un lavoro dove la definition of done è tua completa responsabilita’, golee.it fa per te.<br>Se cerchi un posto di lavoro che non c’è, golee.it fa per te.<br>Il team tecnologico di golee.it fa di tutto per non dover ritornare sui propri passi: prima di sviluppare una nuova feature pensiamo a fondo; successivamente pensiamo ancora più a fondo su come vada implementata e soprattutto se lo stack tecnologico in corso è sufficiente per la nuova feature.<br>In golee.it prima si decide in accordo e poi si realizza.</p><p>Nessun fraintendimento, niente lasciato al caso. Meno refactoring è necessario, più tempo ed energie per crescere abbiamo a disposizione.</p><p>Attualmente l’intero progetto è un classico elefante LAMP: rapido ed efficace.</p><p>Per evolverlo siamo in cerca di persone a loro agio quando si parla di: SOA, REST, JSON, applicazioni React Native Android/iOS, SSO, TDD, Google App Engine, Continuous Integration.</p><p>Siamo ad un punto di stop&amp;go: il prodotto funziona ed abbiamo utenti soddisfatti, adesso deve decollare.</p><p>Vuoi essere uno dei piloti? Scrivi a <a href="/service/mailto:tech@golee.it">tech@golee.it</a>.</p><p>“Uncle” Bob Martin — The Future of Programming</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FecIWPzGEbFc%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DecIWPzGEbFc&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FecIWPzGEbFc%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/3c19e6649c559f1f2f2d07c699a615ca/href">https://medium.com/media/3c19e6649c559f1f2f2d07c699a615ca/href</a></iframe><p>Joel Spolsky — Developers Writing the Future</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FAGyIbZotKlk%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DAGyIbZotKlk&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FAGyIbZotKlk%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/1cf87cc8d9ada67cdbdf617dfff92279/href">https://medium.com/media/1cf87cc8d9ada67cdbdf617dfff92279/href</a></iframe><p>Gary Bernhardt — Wat</p><p><a href="https://www.destroyallsoftware.com/talks/wat">Wat</a></p><p>Gary Bernhardt — The Birth &amp; Death of JavaScript</p><p><a href="https://www.destroyallsoftware.com/talks/the-birth-and-death-of-javascript">The Birth &amp; Death of JavaScript</a></p><p>Sebastian Markbage — Minimal API Surface Area</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F4anAwXYqLG8%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D4anAwXYqLG8&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F4anAwXYqLG8%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/cede35aea3b6fbca8d4616f839100ca3/href">https://medium.com/media/cede35aea3b6fbca8d4616f839100ca3/href</a></iframe><p>Naval Ravikant — Reading, Happiness, Systems for Decision Making, Habits, Honesty and More</p><p><a href="https://www.fs.blog/2017/02/naval-ravikant-reading-decision-making/">Naval Ravikant on Reading, Happiness, Systems for Decision Making, Habits, Honesty and More</a></p><p>Randy Pausch — Last Lecture: Achieving Your Childhood Dreams</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2Fji5_MqicxSo%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Dji5_MqicxSo&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2Fji5_MqicxSo%2Fhqdefault.jpg&amp;type=text%2Fhtml&amp;schema=youtube" width="640" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/3f24159f05ccdc7321de38b014f84130/href">https://medium.com/media/3f24159f05ccdc7321de38b014f84130/href</a></iframe><p>Randy Pausch — Time Management</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FoTugjssqOT0%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DoTugjssqOT0&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FoTugjssqOT0%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="640" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/e8b4340dbeeb8cb01731269da09e4366/href">https://medium.com/media/e8b4340dbeeb8cb01731269da09e4366/href</a></iframe><p>Daniel Tynan — The Glory That Was Yahoo</p><p><a href="https://www.fastcompany.com/40544277/the-glory-that-was-yahoo">The history of Yahoo, and how it went from phenom to has-been</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=715c597e9d70" width="1" height="1" alt=""><hr><p><a href="https://medium.com/golee-engineering/golee-tech-culture-lisola-che-non-c-e-715c597e9d70">Golee tech culture, l’isola che non c’e’</a> was originally published in <a href="https://medium.com/golee-engineering">Golee Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Bitbucket pipeline con Google Container Registry]]></title>
            <link>https://medium.com/golee-engineering/bitbucket-pipeline-con-google-container-registry-2c29c8c85ff0?source=rss----b9ab719cc19f---4</link>
            <guid isPermaLink="false">https://medium.com/p/2c29c8c85ff0</guid>
            <category><![CDATA[pipeline]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[gae]]></category>
            <dc:creator><![CDATA[Gabriele Toselli]]></dc:creator>
            <pubDate>Tue, 03 Apr 2018 16:38:55 GMT</pubDate>
            <atom:updated>2018-04-03T16:38:54.971Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/744/1*KEZlduWuA5SloOAb08q8CA.jpeg" /></figure><p>Dopo aver deciso di usare Google App Engine per il nostro backend abbiamo dovuto pensare ad una soluzione per i test. Ovviamente, la cosa migliore sarebbe avere un ambiente di test identico a quello di produzione, in modo da avere una vera e propria <em>continuous integration</em>.</p><p>La repo del nostro backend è hostata su Bitbucket, che offre un servizio di <strong>Pipelines</strong>. Le pipelines permettono di dividere il processo di rilascio in <em>stages</em>: durante ogni stage, il codice nuovo viene testato e controllato in modo che al momento del rilascio in produzione, non contenga bug che possano compromettere il funzionamento dell’app. In poche parole quindi, le pipelines testano il codice, e lo deployano in produzione solo se supera tutti gli <em>stages.</em></p><p>Abbiamo creato un’immagine Docker che cerca di imitare l’ambiente PHP di GAE, che è hostata su Google Container Registy, ovviamente privata. Abbiamo configurato quindi le pipelines di BitBucket impostando la nostra immagine come immagine base per i test.</p><p>Dallo <strong>IAM</strong> di GAE abbiamo creato un <em>service account</em> chiamato “Pipelines bitbucket”. Una volta scaricato il json contente la coppia di chiavi abbiamo copiato il contenuto del file e l’abbiamo inserito come Environment variables in Bitbucket (repo&gt;settings&gt;pipelines&gt;environment variables) in questo modo.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0xEjIoORwGvY3ZLf00dO8g.png" /><figcaption>GoogleContainerRegistry json key</figcaption></figure><p>Abbiamo creato poi il classico <em>yml</em> contenente la configurazione per la pipeline.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*YqRSXw7mVz6XORVvPd1Wcg.png" /><figcaption>Prima pipeline di test</figcaption></figure><p>In questo modo, specifichiamo alla Pipeline di usare la nostra immagine Docker privata, e quindi di testare il codice in un ambiente presumibilmente identico a quello di produzione su GAE.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2c29c8c85ff0" width="1" height="1" alt=""><hr><p><a href="https://medium.com/golee-engineering/bitbucket-pipeline-con-google-container-registry-2c29c8c85ff0">Bitbucket pipeline con Google Container Registry</a> was originally published in <a href="https://medium.com/golee-engineering">Golee Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My experience of integration between React-Native and iOS]]></title>
            <link>https://medium.com/golee-engineering/my-experience-of-integration-between-react-native-and-ios-f1b9848f292a?source=rss----b9ab719cc19f---4</link>
            <guid isPermaLink="false">https://medium.com/p/f1b9848f292a</guid>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[yarn]]></category>
            <category><![CDATA[npm]]></category>
            <category><![CDATA[cocoapods]]></category>
            <category><![CDATA[react-native]]></category>
            <dc:creator><![CDATA[Matteo Collina]]></dc:creator>
            <pubDate>Mon, 02 Apr 2018 16:40:57 GMT</pubDate>
            <atom:updated>2018-04-05T10:44:10.320Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<p>Well, it was my first experience with React Native, but not only, the first integration with a native iOS application.</p><h3>Project Configuration</h3><p>As a good rule, I started from the official Facebook documentation:</p><p><a href="https://facebook.github.io/react-native/docs/integration-with-existing-apps.html">Integration with Existing Apps · React Native</a></p><p>The required prerequisites are to have installed <strong>npm</strong>, that is the package manager for JavaScript. All very simple here :</p><p><a href="https://nodejs.org/en/download/">https://nodejs.org/en/download/</a></p><p>and finally I execute:</p><pre>$ npm -v</pre><p>and I see that I have installed version 5.6.0</p><p>In addition to this, it is recommended to install: <strong>CocoaPods</strong>, a dependency manager for the Objective-C, Swift and any other languages ​​that run on the Objective-C runtime. To facilitate installation, I do it with <strong>Homebrew</strong>, the missing package manager for macOS:</p><pre>$ brew install cocoapods</pre><p>Ok, you can start setting up the project ..<br>Within the iOS project, I created a &quot;<strong>js</strong>&quot; folder that will contain the React-Native project. First, inside this folder, I create a file called “<strong>package.json</strong>”, with the following structure. <em>Note that my app is called “StoryReact”</em></p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7d6fcb70fad1e0f2ba94380d235ebbc8/href">https://medium.com/media/7d6fcb70fad1e0f2ba94380d235ebbc8/href</a></iframe><p>We have also to install <a href="https://facebook.github.io/watchman/"><strong>watchman</strong></a><strong>.</strong></p><blockquote>React Native uses watchman to detect when you’ve made code changes and then automatically build and push the update your device without you needing to manually refresh it.</blockquote><pre>$ npm install -g watchman</pre><p>Now to continue, we need to install <strong>yarn:</strong></p><blockquote>Yarn is a package manager for your code. It allows you to use and share code with other developers from around the world. Code is shared through something called a <strong>package</strong> (sometimes referred to as a <strong>module</strong>). A package contains all the code being shared as well as a package.json file which describes the package.</blockquote><p>I recommend to install always with Homebrew: <a href="https://yarnpkg.com/lang/en/docs/install/">https://yarnpkg.com/lang/en/docs/install/</a></p><p>With this command, we just have to enter to the &quot;js&quot; folder and install the react-native command:</p><pre>$ yarn add react-native</pre><p>This will print something like:</p><p><em>react-native@0.54.3&quot; has unmet peer dependency “react@^16.3.0-alpha.1”</em></p><p>This is OK, it means we also need to install react:</p><pre>$ yarn add react@^16.3.0-alpha.1</pre><p>As written in the documentation :</p><blockquote>This will create a new /node_modules folder. This folder stores all the JavaScript dependencies required to build your project.</blockquote><p>Add node_modules/ to your .gitignore file, if you’re using git.</p><p>My configuration is :</p><pre>react-native-cli: 2.0.1</pre><pre>react-native: 0.54.3</pre><p>Let&#39;s go back to the project root and start configuring the <strong>Podfile</strong> to install the project dependencies:</p><pre>$ pod init</pre><p>Edit Podfile with specifications in the documentation : (path starts with “js” because it contains “<a href="https://github.com/facebook/react-native/blob/master/React.podspec">/node_modules/react-native/React.podspec</a>”)</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0a89d5f4f7053e720e643bb07a546f30/href">https://medium.com/media/0a89d5f4f7053e720e643bb07a546f30/href</a></iframe><p>let’s install the dependencies:</p><pre>$ pod install</pre><p>Ops, first error comes out:</p><p><em>[!] The name of the given podspec `glog` doesn’t match the expected one `GLog`</em></p><p>Just edit the name in Podfile from :</p><pre>pod &#39;GLog&#39;, :podspec =&gt; &#39;./js/node_modules/react-native/third-party-podspecs/GLog.podspec&#39;</pre><p>to:</p><pre>pod &#39;glog&#39;, :podspec =&gt; &#39;./js/node_modules/react-native/third-party-podspecs/GLog.podspec&#39;</pre><p>Yess, dependencies have been installed :</p><pre>Downloading dependencies<br>Installing DoubleConversion (1.1.5)<br>Installing Folly (2016.09.26.00)<br>Installing React (0.54.3)<br>Installing boost-for-react-native (1.63.0)<br>Installing glog (0.3.4)<br>Installing yoga (0.54.3.React)<br>Generating Pods project<br>Integrating client project</pre><pre>[!] Please close any current Xcode sessions and use `StoryReact.xcworkspace` for this project from now on.</pre><pre>Sending stats</pre><pre>Pod installation complete! There are 10 dependencies from the Podfile and 6 total pods installed.</pre><p>Now let&#39;s try opening the .<em>xcworkspace</em> file and try to build the app to see if everything went well..</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8640m7bPlB3t7B6Hshqiow.png" /></figure><p>The app fails to build, there seems to be an error with the &quot;Yoga-internal.h&quot; file. After some online research, I decided to create an <a href="https://github.com/facebook/react-native/issues/18504">issue on GitHub</a> but I had negative feedback, I would have to change the code of the framework by hand. But I did not like it as a solution, so I tried to <em>switch to another version</em>.</p><p>Then I <em>delete :</em></p><ul><li><em>&quot;Pods&quot;</em></li><li><em>“Podfile.lock”</em></li><li><em>&quot;js / node_modules&quot;</em></li></ul><p>I go back to the terminal and <strong>install version 0.51.0 of React-Native</strong>, after reading that the version from 0.54 up to this all gave the same problem.</p><p>So, I proceed with the same commands I did before to install react-native and dependencies on the project with pod, including changes to the Podfile on the contrary :</p><pre>$ yarn add react-native@0.51.0<br>$ yarn add react@react@16.0.0<br>$ pod install</pre><pre>from: </pre><pre>pod &#39;glog&#39;, :podspec =&gt; &#39;./js/node_modules/react-native/third-party-podspecs/GLog.podspec&#39;</pre><pre>to:</pre><pre>pod &#39;GLog&#39;, :podspec =&gt; &#39;./js/node_modules/react-native/third-party-podspecs/GLog.podspec&#39;</pre><p>Let’s try to build again the .<em>xcworkspace</em> file ..</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VbhKIe3wW48y-Ma_KovQjQ.png" /></figure><p>Another error appears, it can not import the &quot;<em>fishhook.h</em>&quot; file.</p><p>But this time the solution is easier than expected. It is only necessary to change the line in the code as described in the <a href="https://github.com/facebook/react-native/issues/16039">GitHub issue</a> and everything works finally!</p><pre>from :</pre><pre>#import &lt;fishhook/fishhook.h&gt;</pre><pre>to:</pre><pre>#import &quot;fishhook.h&quot;</pre><p>However, in my experience, it was complicated and made me lose a lot of time the configuration, I hope that in the future the Facebook team will provide more detailed documentation.</p><p>Although a <em>little dated but very valid</em>, I recommend the guide of <strong>Ray Wenderlich</strong>, which also provides a trial project for those who are at the beginning.</p><p><a href="https://www.raywenderlich.com/136047/react-native-existing-app">https://www.raywenderlich.com/136047/react-native-existing-app</a></p><h3>Integrate react file and run!</h3><p>First of all, you have to enable the project to receive HTTP calls, so edit your <strong>info.plist</strong> file and add this code (<em>open as “source code” it will make your life easier</em>):</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4cff0c9ac540048898e6846f1601729e/href">https://medium.com/media/4cff0c9ac540048898e6846f1601729e/href</a></iframe><p>Now we have to create the <strong>index.ios.js</strong> file, inside js directory, to show to the user. Below is an easy example:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/35b03783a9818f08a0b5d5b2c61d35e1/href">https://medium.com/media/35b03783a9818f08a0b5d5b2c61d35e1/href</a></iframe><p>Now, open your XCode project and <em>paste this code on ViewController</em>:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f5c4ba99fc35d557a8ee2756b5feb538/href">https://medium.com/media/f5c4ba99fc35d557a8ee2756b5feb538/href</a></iframe><p>During the <strong>development process</strong>, React Native has loaded your JavaScript code dynamically at runtime. For a <strong>production build</strong>, you want to pre-package the JavaScript bundle and distribute it inside your application. Doing this requires a code change in your code so that it knows to load the static bundle.</p><p>I can check if I’m running on production or debug using flags:</p><ol><li>Open your Project Build Settings and search for “Swift Compiler — Custom Flags” … “Other Swift Flags”.</li><li>Add “-DDEBUG” to the Debug section</li><li>Add “-DRELEASE” to the Release section</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*VIIPdYeQ_AfqEcY8Ge-wsw.png" /><figcaption>thanks to <a href="https://kitefaster.com/2016/01/23/how-to-specify-debug-and-release-flags-in-xcode-with-swift/">https://kitefaster.com/2016/01/23/how-to-specify-debug-and-release-flags-in-xcode-with-swift/</a></figcaption></figure><p>Ok, we are at the end credits .. now go to the terminal, in the js folder and execute:</p><pre>npm start</pre><p>Build your app and voila</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/300/1*nSc4zp1l7XpfI8vTpD0rQQ.png" /></figure><p>If it does not work, check if there are any processes on port 8081:</p><pre>lsof -i :8081<br>kill -9 &lt;PID&gt;    //&lt;PID&gt; to replace with the PID of the process</pre><p>Tips:</p><ul><li>If you want to see the changes to the js file immediately on the simulator you have to activate the <strong>hot reload</strong>:</li></ul><pre>On simulator press : CMD+D<br>&quot;Enable Hot Reloading&quot;</pre><h3>Deploy your app</h3><p>If you want to release the app on TestFlight or on the AppStore, you need to create the <strong>jsbundle</strong> file bundle</p><ul><li>Open XCode project / Build Phases / [+] New Run Script Phase</li></ul><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/df39f3e5f556e3e703cac2c93cc9a32b/href">https://medium.com/media/df39f3e5f556e3e703cac2c93cc9a32b/href</a></iframe><p><em>This script must be at the top of Build Phases.</em></p><p>So when the app is in production it loads the .jsbundle created by the script</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*y6C4nSvy2Woe0m7bWEn4BA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f1b9848f292a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/golee-engineering/my-experience-of-integration-between-react-native-and-ios-f1b9848f292a">My experience of integration between React-Native and iOS</a> was originally published in <a href="https://medium.com/golee-engineering">Golee Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Come integrare React-Native in una applicazione Android esistente]]></title>
            <link>https://medium.com/golee-engineering/come-integrare-react-native-in-una-applicazione-android-esistente-7aea7b861ebd?source=rss----b9ab719cc19f---4</link>
            <guid isPermaLink="false">https://medium.com/p/7aea7b861ebd</guid>
            <category><![CDATA[yarn]]></category>
            <category><![CDATA[npm]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[android-app-development]]></category>
            <category><![CDATA[react-native]]></category>
            <dc:creator><![CDATA[Roberto Colombo]]></dc:creator>
            <pubDate>Mon, 02 Apr 2018 15:53:49 GMT</pubDate>
            <atom:updated>2018-04-20T10:00:08.535Z</atom:updated>
            <content:encoded><![CDATA[<p>Da poco entrato nel mondo Dev-Android, mi sono subito scontrato con una delle più grandi problematiche che possa affliggere un programmatore: la mancanza di risorse su web.</p><p>Con questa guida vorrei quindi mostrarvi come integrare React-Native in un’applicazione Android pre-esistente. Nella fattispecie creeremo un’activity cui contenuti saranno caricati da un <em>bundle, </em>il quale verrà generato da React in fase di build dell’applicazione Android.<br>Seguirò questa <a href="https://facebook.github.io/react-native/docs/integration-with-existing-apps.html">guida</a> integrandola con sezioni e correzioni.</p><h3>Outline</h3><p>I passi che seguiremo per integrare React Native all’interno dell’applicazione Android sono i seguenti:</p><ol><li>Setup directory e librerie.</li><li>Setup delle dipendenze.</li><li>Scrittura dei contenuti dell’activity nel file Javascript.</li><li>Aggiunta del <em>ReactRootView </em>all’interno dell’activity Android. (La view fungerà da container alla nostra componente di React-Native).</li><li>Avvio del server di React Native e lancio dell’applicazione Android nativa.</li><li>Build React Native bundle.</li></ol><h3>1. Set Up directory</h3><p>Creiamo all’interno del progetto una cartella denominata <em>react-native </em>che conterrà tutti i file riguardanti React, di modo da non ‘sporcare’ il progetto nativo.</p><p>All’interno di essa creiamo un nuovo file chiamato <em>package.json</em> con il seguente contenuto:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1d98d2d2a5f4e8381f9ddb85cd468f9a/href">https://medium.com/media/1d98d2d2a5f4e8381f9ddb85cd468f9a/href</a></iframe><p>Assicuriamoci di aver installato il <a href="https://yarnpkg.com/lang/en/docs/install/"><em>package manager di yarn</em></a>.</p><p>Installiamo ora i packages di <em>react </em>e di <em>react-native aprendo </em>un terminale e puntando la cartella<em> react-native.</em> Lanciamo il comando:</p><pre>$ yarn add react-native</pre><p>Ora installiamo le librerie di react:</p><pre>$ yarn add react@16.2.0    <br># Make sure you use the same react version as printed by yarn when installing react-native!</pre><p>Questo comando creerà una ulteriore sottocartella <em>/node_modules</em> che conterrà tutte le dipendenze JavaScript necessarie per bildare il progetto.<br>Se state usando git (e dovreste) aggiungere tutta la sottocartella <em>/nodel_modules </em>al file <em>.gitignore</em>.</p><h3>2. Setup dipendenze</h3><p>In questa seconda fase aggiungeremo le dipendenze di <em>react</em> al progetto Android. <br>Apriamo quindi il file <em>build.gradle</em> relativo all’applicazione (dovrebbe essere nella sottocartella /app), e aggiungiamo il seguente codice che scaricherà in fase di <em>build</em> alcune librerie. (Il simbolo ‘+’ fa riferimento alla versione più recente).</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1d95a4cf709c77d265cdf2b082d13155/href">https://medium.com/media/1d95a4cf709c77d265cdf2b082d13155/href</a></iframe><p>Apriamo ora il file <em>build.gradle </em>relativo al progetto (dovrebbe trovarsi nella <em>root</em>), e aggiungiamo il seguente codice, ossia creiamo una corrispondenza alla cartella contente le librerie di React Native:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2d39c4f89498835c407276ebc2405271/href">https://medium.com/media/2d39c4f89498835c407276ebc2405271/href</a></iframe><p>Ultimo passaggio, abilitiamo i permessi internet aggiungendo nel <em>AndroidManifest.xml </em>la seguente riga:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9811f02201a116008eeffb03c1e3a7c7/href">https://medium.com/media/9811f02201a116008eeffb03c1e3a7c7/href</a></iframe><h3>3. File JavaScript</h3><p>Una volta importate e buildate tutte le librerie, siamo pronti a scrivere il nostro script React.<br>Sempre all’interno della cartella <em>/react-native </em>creiamo un nuovo file chiamato <em>index.android.js</em> che sarà il punto di partenza dell’applicazione di React Native. Da questo semplice file JS potremo poi eventualmente richiamare altri file JS, per il momento accontentiamoci di scrivere un semplice testo! “<strong>Ciao Mondo!</strong>”,</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6ea376897b192f98f884d4ac5fa05e5b/href">https://medium.com/media/6ea376897b192f98f884d4ac5fa05e5b/href</a></iframe><h3>4. Activity con R<em>eactRootView</em></h3><p>Non ci resta che creare l’Activity che ospiterà i contenuti della nostra applicazione React-Native.</p><p>Creiamo una nuova Activity e chiamiamola <em>MyReactActivity</em>.<br>Incolliamo il codice di questa classe. Ho commentato direttamente sul codice alcune spiegazioni relative alle varie istruzioni.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c29fcd55d5b5ec21eb535f6912870fe6/href">https://medium.com/media/c29fcd55d5b5ec21eb535f6912870fe6/href</a></iframe><p>Di seguito un paio di <em>screenshoot </em>per contestualizzare ciò di cui stiamo parlando.<br>L’immagine a sinistra appare la prima volta che accediamo all’applicazione React e sono i permessi per mostrarvi eventuali messaggi di errore provenienti da React (sperando non ci siano ovviamente :-) ).<br>A destra il messaggio di errore che riceveremo nel caso in cui l’applicazione React non riuscisse ad accedere al server.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dcT9RkS0jE4R8OvPX_o0qA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JOBDYJiq3sRcZPRMKrxvAA.png" /><figcaption>Sinistra: Richiesta permessi per mostrare schermata di errore. Destra: esempio di schermata di errore</figcaption></figure><h3>5. Lanciamo l’applicazione</h3><p>Per prima cosa dobbiamo avviare il server di react in locale, che permetterà all’applicazione di collegarsi e richiedere il <em>bundle</em> compilato della mia applicazione React.</p><p>Apriamo il terminale, rechiamoci all’interno della cartella react-native, e lanciamo il comando:</p><pre>$ npm start</pre><p>Il server partirà e rimarrà in attesa di richieste con questa schermata:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rXtdBA6fKQhHAkCsS7KbgA.png" /></figure><p>Ora lanciando l’applicazione da Android Studio, apriamo con l’emulatore la schermata contente l’applicazione react, il server risponderà caricando il <em>bundle</em> e mostrandoci il contenuto nell’activity.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Nt2kCyOdkLtBwWA8BPR48Q.png" /></figure><h3>6. Builld del React Native Bundle locale.</h3><p>Ad ora siamo riusciti a creare il <em>bundle</em> dell’applicazione React scaricandolo dal server a runtime. Questo però richiede due condizioni: che il server sia in esecuzione nel momento in cui l’utente richiede la visualizzazione dell’activity, e che l’utente sia connesso alla rete internet.<br>Questo potrebbe essere un problema, vedremo quindi come creare un <em>bundle </em>locale e inserirlo automaticamente nell’apk nel momento in cui verrà fatto la <em>build</em> dell’applicazione.</p><p>Di seguito alcune linee guida generiche che gli sviluppatori di React Native ci hanno voluto dare in merito:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/98bed54fddd93c0974c1a501fa6e8419/href">https://medium.com/media/98bed54fddd93c0974c1a501fa6e8419/href</a></iframe><p>Basandoci su questa guida aggiungiamo il seguente script all’interno del file <em>gradle</em> dell’applicazione:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1011ff79767bf2a1bc9957d6c1c7b840/href">https://medium.com/media/1011ff79767bf2a1bc9957d6c1c7b840/href</a></iframe><p>In poche parole stiamo dicendo a React di generare il <em>bundle</em> solo se facciamo la <em>build</em> del progetto in modalità release.</p><p>In caso stessimo facendo la <em>build</em> in modalità <em>release</em>, troveremo il <em>bundle</em> al percorso:<br><em>/$rootDir/app/build/intermediates/assets/release/index.android.bundle</em></p><h3>Conclusioni</h3><p>E questo è tutto per ora! Spero di esservi stato d’aiuto e magari di avervi risparmiato qualche oretta di imprecazioni! Buon Lavoro!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7aea7b861ebd" width="1" height="1" alt=""><hr><p><a href="https://medium.com/golee-engineering/come-integrare-react-native-in-una-applicazione-android-esistente-7aea7b861ebd">Come integrare React-Native in una applicazione Android esistente</a> was originally published in <a href="https://medium.com/golee-engineering">Golee Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>