<?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 Madura Pradeep on Medium]]></title>
        <description><![CDATA[Stories by Madura Pradeep on Medium]]></description>
        <link>https://medium.com/@madura?source=rss-d57dfc6f94e9------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*xSJwYGuuWLY0RgvtsNTvLQ.jpeg</url>
            <title>Stories by Madura Pradeep on Medium</title>
            <link>https://medium.com/@madura?source=rss-d57dfc6f94e9------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 19:37:16 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@madura/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[How to make your own theme with React Bootstrap]]></title>
            <link>https://medium.com/@madura/how-to-make-your-own-theme-with-react-bootstrap-a423ce04a316?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/a423ce04a316</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[react-bootstrap]]></category>
            <category><![CDATA[themes]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Wed, 04 Sep 2019 08:11:14 GMT</pubDate>
            <atom:updated>2019-09-04T08:11:14.040Z</atom:updated>
            <content:encoded><![CDATA[<p>Ever wanted to create your own theme? Inside our company <a href="https://getshoutout.com/">ShoutOUT</a>, we have a couple of products and we need to maintain consistency between products. So we thought of creating our own React theme with necessary components which can be consumed inside our products. We have used <a href="https://react-bootstrap.github.io/">React Bootstrap</a> for this.</p><p>Following is how our project structure looks like. Inside the components, we have the component&#39;s logic and inside the themes folder, we have different bootstrap themes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/266/1*bPBejxG44vjs0vPPYuwqMw.png" /><figcaption>Project structure</figcaption></figure><p>Following is the main export script (index.js). As you can see we import the custom components from the components folder and export them. Also, we export all other non-customized React Bootstrap modules from React Bootstrap.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rqTTt7FWYr-dS9eFkwxU7A.png" /><figcaption>export script</figcaption></figure><p>To create this theme we used 4 different kinds of components.</p><ol><li><strong>React Bootstrap components which do not need any changes</strong><br>Eg: Row, Col<br>Just import them from React Bootstrap and export inside the main export script.</li><li><strong>React Bootstrap components which need them as it is with own default class names and minor property updates</strong><br>Eg: Button — we only want to change default class names.<br>Create a component inside the components folder and override the default properties.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/330/1*S5bgkTY2xDfiVgvOeyJOlg.png" /><figcaption>Override default class names of button</figcaption></figure><p>3. <strong>New components made using different React Bootstrap components</strong><br>Eg: Alert Box component which used React Bootstrap Model and Buttons</p><p>Create a custom component inside the components folder. Import necessary React Bootstrap modules and export the component from the main export script.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/994/1*2H2UY1M3smenpda7Tc0IeA.png" /></figure><p>4. <strong>Non React Bootstrap 3rd party components</strong><br>Eg: DateTime picker</p><p>Third-party libraries. Follow the steps for types 1,2,3 with import them from the relevant libraries.</p><p>That’s it. Comment if you have any questions. Happy to answer.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a423ce04a316" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[PWA Service worker mistake we did which slow down the site]]></title>
            <link>https://medium.com/@madura/pwa-service-worker-mistake-we-did-which-slow-down-the-site-1ce653af59a6?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/1ce653af59a6</guid>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[service-worker]]></category>
            <category><![CDATA[pwa]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Sat, 24 Aug 2019 10:00:31 GMT</pubDate>
            <atom:updated>2019-08-24T10:00:31.022Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>The only man who never makes a mistake is the man who never does anything — Theodore Roosevelt</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dy7fi-0SjXK3eyBlFYhyEA.jpeg" /></figure><p>We have made our website as a progressive web app with service worker technique. However, we did a small mistake which slows down the website initial load time in a great amount. It was one line of code :). <br>In our site, we are pre-caching the assets inside the service worker as following.</p><blockquote>self.__precacheManifest = [</blockquote><blockquote>{</blockquote><blockquote>“url”: “0bc8a1530eb93326c901a437a8a79431.svg”,</blockquote><blockquote>“revision”: “0bc8a1530eb93326c901a437a8a79431”</blockquote><blockquote>}</blockquote><blockquote>]</blockquote><p>And load the service worker as follows.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/35ab0b626808e0f148d71b0134e80bad/href">https://medium.com/media/35ab0b626808e0f148d71b0134e80bad/href</a></iframe><p>So after the service worker has installed, it will start the caching assets specified in the service worker in the background. As you can see in the service worker installation script, the service worker will start as soon as the above script evaluated. That was the mistake. <strong>Here we should wait for the document load event</strong>. Otherwise, the service worker will start downloading the caching assets which will slow down the download of the assets required for the current page. So the corrected service worker should be like below.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2826d6a4a658590046218de288992c68/href">https://medium.com/media/2826d6a4a658590046218de288992c68/href</a></iframe><h4>Summary</h4><p>The service worker is a great way to improve user experience however, invalid configurations will cost you. Caching necessary assets is a good practice since it will reduce the loading time of the other routes and assets. However, do not install service worker before the current page fully load (wait for on load event).</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1ce653af59a6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Reduce AWS Amplify bundle size inside your app]]></title>
            <link>https://medium.com/@madura/reduce-aws-amplify-bundle-size-inside-your-app-feac2e10cd22?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/feac2e10cd22</guid>
            <category><![CDATA[amplify]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[build]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Sat, 17 Aug 2019 04:41:07 GMT</pubDate>
            <atom:updated>2019-08-17T04:41:07.100Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*cBsAZgYgJ5B41qOz9lunAw.jpeg" /></figure><p>AWS (Amazon Web Service) <a href="https://aws-amplify.github.io/">Amplify </a>is an easy to use framework for mobile and web app which utilize the AWS cloud services. However, I recently encountered a bundle size issue after building with Amplify, since it is really heavy inside the build package. This small article is about how you can optimize the import and reduce the bundle size.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hOJSG8qn2Z9Rz6vQWbIkGQ.png" /><figcaption>Bundle analyze without optimizing Amplify import (<a href="https://drive.google.com/open?id=1QwIZ6O2VKVzU4Unlss-I7_ieA5kDj-Cw">https://drive.google.com/open?id=1QwIZ6O2VKVzU4Unlss-I7_ieA5kDj-Cw</a>)</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OLWQoP-fQUngK04up6SLNg.png" /><figcaption>Bundle analyze after optimizing Amplify import (<a href="https://drive.google.com/open?id=1boaj2k5X193JRLNUGFWLjIB_Zyje4zWi">https://drive.google.com/open?id=1boaj2k5X193JRLNUGFWLjIB_Zyje4zWi</a>)</figcaption></figure><p>As you can see in the above images (click on the relevant link if you can’t see the images clearly) without optimizing Amplify import, the bundle size is around 3.39 MB and after optimize it is around 1.06 MB which is around 70% size reduction.<br>The optimization is really simple. You have to just import the submodules which required inside your application. Amplify is a heavy library since it includes different sub-modules for different AWS services. In my case, I only need the Amplify Auth module since I only used Amplify for authentication (Login, Signup, etc..) inside my application. Anyways, you have to import the Amplify Core as well. <br>Following is my Amplify initialization script looks like.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6e8aa387a34640d0a94374d8cd9efd68/href">https://medium.com/media/6e8aa387a34640d0a94374d8cd9efd68/href</a></iframe><p>This is how I import the Amplify module before optimize.</p><blockquote>import Amplify from ‘aws-amplify’;</blockquote><p>This is how I only import the submodules I need.</p><blockquote>import Amplify from ‘@aws-amplify/core’;<br>import Auth from ‘@aws-amplify/auth’;</blockquote><p>Changing this import reduces the bundle size by 70%.</p><h4>Summary</h4><p>It is always a good practice to analyze the bundle size after the build. Then you will find the unoptimized imports and libraries.</p><p>Always trying to import only the submodules from the libraries which only required inside your project.</p><p>You can use tools like “<a href="https://www.npmjs.com/package/source-map-explorer">source-map-explorer</a>” in order to analyze your build package.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=feac2e10cd22" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Migrate React Redux to React Context API with 5 lines of code]]></title>
            <link>https://medium.com/@madura/migrate-react-redux-to-react-context-api-with-5-lines-of-code-eacdffc17041?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/eacdffc17041</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[redux]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Sat, 10 Aug 2019 05:30:37 GMT</pubDate>
            <atom:updated>2019-08-10T05:30:37.107Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/450/1*rQBvLzIw2XOHtNmBZVvgIQ.jpeg" /></figure><p>In <a href="https://getshoutout.com/">ShoutOUT</a>, all our front-ends are made with React framework. In our core product, we had use React 15.x with Redux framework. But with React 16.x, the Context API is officially released and there’s no point of adding additional libraries like Redux to handling application states where that capability already built inside the React itself. Migration is hard and scary since the ShoutOUT core front-ends rely heavily on Redux. But when I think about the Redux code base and Context API, there are lots of similarities. So thinking a little bit and digging on Google solved our migration headache with few lines of code (only 5 lines). Let’s see how.</p><h4>Steps</h4><ol><li>Add this <a href="https://gist.github.com/maduraPradeep/3cd8b416eff256a983565a380611d4a8.js">script</a> to your project location. (This script I created based on an existing work done by genius. Now I can’t find the source).</li></ol><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/a0e6cbc7ca70c314b7eb45c9d3957cae/href">https://medium.com/media/a0e6cbc7ca70c314b7eb45c9d3957cae/href</a></iframe><p>2. Replace connect function import from react-redux with connect function in the above script</p><p>Eg:</p><blockquote>import {connect} from ‘react-redux’;</blockquote><blockquote>Replace with:</blockquote><blockquote>import { connect } from ‘./Script;</blockquote><p>3. Replace combineReducer function import from redux with Script</p><blockquote>Eg:</blockquote><blockquote>import {combineReducers} from ‘redux’;</blockquote><blockquote>Replace with:</blockquote><blockquote>import { combineReducer } from ‘./Script’;</blockquote><p>4. Replace Provider import from “react-redux” with ContextProvider from the script. Note that combined reducers output should provide as a property to ContextProvider.</p><p>Eg:</p><blockquote>import { Provider } from ‘react-redux’;</blockquote><blockquote>….</blockquote><blockquote>&lt;Provider store={store}&gt;</blockquote><blockquote>…</blockquote><blockquote>&lt;/Provider&gt;</blockquote><blockquote>Replace with:</blockquote><blockquote>import { ContextProvider } from ‘./Scripts;</blockquote><blockquote>…</blockquote><blockquote>&lt;ContextProvider reducer={reducers}&gt;</blockquote><blockquote>…</blockquote><blockquote>&lt;/ContextProvider&gt;</blockquote><p>Hola. That’s it.</p><p>I will explain the relevant code based we had before the migration in case your setup is different. We had separate actions, connectors and reducers.</p><p>Inside the RootReducer, we import all the reducers and combined them with the help of “combineReducer” function in “redux”.</p><p>Old RootReducer</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2cb891f0006779e520da76456efb68b5/href">https://medium.com/media/2cb891f0006779e520da76456efb68b5/href</a></iframe><p>New RootReducer</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/8dba33da5c25ef1d40400d0d2e9abde0/href">https://medium.com/media/8dba33da5c25ef1d40400d0d2e9abde0/href</a></iframe><p>Old Container</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/75c55238b74576406c6c705f81493141/href">https://medium.com/media/75c55238b74576406c6c705f81493141/href</a></iframe><p>New Container</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/89a33d4900fb427be48168f7480b62d5/href">https://medium.com/media/89a33d4900fb427be48168f7480b62d5/href</a></iframe><p>If you have any questions, please comment.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eacdffc17041" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[This is How We Do It — The (best) practices that We at ShoutOUT Labs Follow for Front-end…]]></title>
            <link>https://medium.com/shoutout-blog/this-is-how-we-do-it-the-best-practices-we-are-following-for-frontend-developments-4bb36102e29b?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/4bb36102e29b</guid>
            <category><![CDATA[react]]></category>
            <category><![CDATA[front-end-development]]></category>
            <category><![CDATA[shoutout-engineering]]></category>
            <category><![CDATA[best-practices]]></category>
            <category><![CDATA[how-we-work]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Mon, 29 Jan 2018 11:54:45 GMT</pubDate>
            <atom:updated>2018-02-14T19:01:38.375Z</atom:updated>
            <content:encoded><![CDATA[<h3>This is How We Do It — The (best) practices that We at ShoutOUT Labs Follow for Front-end Developments</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GMM-lTgZVtpmCcYvIv40Ug.png" /></figure><p>Before getting into the details, get to know technologies and framework we use in our dashboard.</p><ul><li>React JS</li><li>Bootstrap framework</li><li>React Redux</li></ul><p>Front-end initial skeleton code is generated using <a href="https://github.com/facebook/create-react-app">create react app plugin</a>. We are using the <a href="http://www.ecma-international.org/ecma-262/6.0">ES6</a> syntax.</p><p>Below are some of the practices we follow at our company for front-end developments.</p><h4>Naming Conventions</h4><ul><li>Folders — snake case. All letters are in lower case &amp; words are separated by an underscore (‘_’).<br>Eg: — admin, user_purchase</li><li>Files — pascal case (upper camel case). All words start with a capital letter and the other characters are in lower case.<br>Eg: — HomeComponents, AdminComponents</li><li>Javascript classes — pascal case.</li><li>Javascript class methods — camel case. There are no private, public access modifiers in Javascript. So, as a practice, we start method name with an underscore for private methods.</li><li>Eg: _privateMethod()<br> publicMethod()</li><li>CSS class names — kebab case. All letters are in lower case. Words are separated by a hyphen (‘-’).<br>Eg: — home-content, admin-content</li><li>Constants — All capital. Words are separated by an underscore (‘_’). <br>Eg:- BASE_URL</li></ul><h4><strong>Folder structure</strong></h4><p>ShoutOUT is an SPA (Single Page Application) and both back-end and front-end codes are under the same project in different folders.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/178/0*og9DfAiWuduVehnw." /><figcaption>High-level folder structure inside project</figcaption></figure><p>As you can see in the above screenshot, we have separated codes as the back-end, front-end, table_schemas etc.. As the focus of this article is the front-end, given below is the screenshot of the front-end folder structure.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/286/0*LcOpcn_E7LwlPjPN." /><figcaption>Front-end folder structure</figcaption></figure><p>As you can see in the screenshot,</p><ul><li>Public directory — index.html file and other assets like images, favicon etc.. Images stored under public/assets/images.</li><li>Src — source files</li><li>Index.js — entry point</li><li>App.js — Higher order component wrapper</li><li>Constants.js — All the global constants</li><li>Components directory — All react components</li><li>Redux directory — Redux data store files. All the containers are under containers sub-directory, Reducers are under reducers sub-directory, and Actions are inside actions sub-directory.</li><li>Services directory — 3rd party API connections, utility services, and other service connectors.</li></ul><h4><strong>Component repository</strong></h4><p>All the components are exported through Components.js file. This acts as the component repository. If any component needs to refer to another component, it has to refer through this file.</p><p>The inside of Components.js will look like this:</p><blockquote>import Home from ‘./home/Home’;</blockquote><blockquote>import Header from ‘./header/Header’;</blockquote><blockquote>export {</blockquote><blockquote>Home,</blockquote><blockquote>Header</blockquote><blockquote>}</blockquote><p>If Home.js needs to import Header.js, it has to refer to Components.js, not Header.js directly.</p><blockquote>import { Header } from ‘./../Components’;</blockquote><p>This has several advantages.</p><ol><li>If we want to change the name or the location of Header.js file, it’s just a matter of updating the ‘export’ of Component.js.</li></ol><blockquote>Eg: export {</blockquote><blockquote>Header: HeaderNew</blockquote><blockquote>}</blockquote><p>2. When it is required to refer to multiple components, we only have to import Components.js.</p><blockquote>Eg: import { Header, Home } from ‘./../Components’;</blockquote><p>3. You can easily see all the imports and exports in a single file.</p><h4><strong>Constants</strong></h4><p>All the global constants are stored in Constants.js file. This way we can easily manage all the constants.</p><blockquote>Eg:</blockquote><blockquote>const DEFAULTS = {</blockquote><blockquote>BASE_URL: ‘https://api.getshoutout.com/v1/&#39;,</blockquote><blockquote>DEFAULT_NAME: ‘Newbie’,</blockquote><blockquote>}</blockquote><blockquote>export default DEFAULTS;</blockquote><h4><strong>Services</strong></h4><p>All the services which connect front-end to back-end, 3rd party services, and common utility services are inside this directory. And we name the services after the service name.</p><p>Eg: Utilities — UtilServices.js<br> ShoutOUT API services (connections) — ShoutOUTServices.js<br> Google Services — GoogleServices.js</p><p>All these services are exported via a single file called Services.js which act as service repository (similar to the component repository).</p><p>Service is wrapped as a class and all the methods are static. So there’s no need to create a new object of the service when referring a method.</p><blockquote>Eg:</blockquote><blockquote>class ShoutOUTService {</blockquote><blockquote>static submitForm(formId, formData) {</blockquote><blockquote>return //API call promise</blockquote><blockquote>}</blockquote><blockquote>}</blockquote><blockquote>export default ShoutOUTService;</blockquote><p>We can just call the method like ShoutOUTService.submitForm().</p><p>I will stop with this for now. The second part of this post will cover the following topics</p><p>(I will only write part two of this article if I get maximum claps for this post. 😉).</p><ul><li>What to store in Local states</li><li>Manage initial state</li><li>Functions</li></ul><blockquote>Common function for form on change events</blockquote><blockquote>Using form onsubmit event</blockquote><ul><li>Form validation</li></ul><blockquote>Use default validation as possible</blockquote><ul><li>React Component &amp; Pure Component</li><li>Redux</li></ul><blockquote>Common Actions</blockquote><blockquote>Action split</blockquote><ul><li>CSS classes</li></ul><blockquote>Component wise styles</blockquote><p>If you have any thoughts or if you think there are things to be changed, please do let me know. Together, we can make it right. 🙂</p><p>Keep clapping till we meet with the 2nd part of this post. 🙂</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4bb36102e29b" width="1" height="1" alt=""><hr><p><a href="https://medium.com/shoutout-blog/this-is-how-we-do-it-the-best-practices-we-are-following-for-frontend-developments-4bb36102e29b">This is How We Do It — The (best) practices that We at ShoutOUT Labs Follow for Front-end…</a> was originally published in <a href="https://medium.com/shoutout-blog">ShoutOUT Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Google Firebase Functions vs AWS Lambda, A shallow comparison]]></title>
            <link>https://medium.com/shoutout-blog/google-firebase-functions-vs-aws-lambda-a-shallow-comparison-303ab7a4759?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/303ab7a4759</guid>
            <category><![CDATA[firebase]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[firebase-cloud-functions]]></category>
            <category><![CDATA[shoutout-engineering]]></category>
            <category><![CDATA[lambda-function]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Tue, 19 Dec 2017 04:55:52 GMT</pubDate>
            <atom:updated>2017-12-19T16:32:50.451Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/898/1*x3PoimJ8DB5GR0imuE92Xw.jpeg" /></figure><p>A few days back, I got the chance to get hands-on experience on Firebase functions and I thought of sharing with you all what I learned. I hope to compare it with AWS Lambda as I am familiar with that ☺️ Also note that Firebase functions is still in beta.</p><p>First of all, it wasn’t that hard to learn and deploy Firebase function as it’s <a href="https://firebase.google.com/docs/functions/get-started">documentation</a> (We know how hard it is to read AWS documentation ☺️) is pretty much okay for me. So kudos for the Firebase documentation.</p><p>Before doing anything else, you have to install <a href="https://www.npmjs.com/package/firebase-tools">firebase tools</a>. Without that, you can’t upload your function into Firebase. On the other hand, in AWS Lambda, you don’t need any additional tools to install and can directly upload and test your function in their console itself. Therefore, the initial learning curve is minimum in Lambda.</p><p>After going through the initial learning curve, it’s really convenient to use Firebase tools to manage the project — easy to create and deploy. For Lambda too, you can experience the same (or higher) level of convenience by installing tools like <a href="https://www.npmjs.com/package/node-lambda">Node Lambda</a>, <a href="https://www.npmjs.com/package/lambda-local">Lambda Local</a> or a toolkit like <a href="https://serverless.com/">Serverless</a>.</p><p>For writing Firebase function, you have to import their library first and implement the methods as required. Given below is how you can write a simple HTTP endpoint in Firebase. The disadvantage I came across here is that Firebase function library itself is about 2.1MB in size. It’s quite heavy and I have to check how that effect the loading time of the function.</p><blockquote><strong>Eg: Firebase functions creating a HTTP endpoint</strong></blockquote><blockquote>const functions = require(‘firebase-functions’);</blockquote><blockquote>exports.addMessage = functions.https.onRequest((req, res) =&gt; {</blockquote><blockquote>res.send(“ok”);</blockquote><blockquote>});</blockquote><p>Once you deploy the function, you will get an HTTP endpoint to call that.</p><p>On the other hand, you can simply create a function and create an AWS API Gateway endpoint to expose HTTP endpoint for the function in Lambda. You can do all of this from the Lambda console itself.</p><blockquote><strong>Eg: Lambda function</strong></blockquote><blockquote>exports.handler = (event, context, callback) =&gt; {</blockquote><blockquote>callback(null,“send”);</blockquote><blockquote>};</blockquote><p>You can see function execution logs in the dashboard in both Firebase and Lambda.</p><p>If you are using Firebase as your database, then it’s really easy to access your database if your function is also under the same project. It’s just a matter of importing the Firebase Admin library. You don’t have to configure any security rules or anything for accessing the database (Of course you can limit it if you need).</p><blockquote><strong>Eg: Access Firebase Firestore from Firebase functions</strong></blockquote><blockquote>const admin = require(‘firebase-admin’);</blockquote><blockquote>let db = admin.firestore();</blockquote><blockquote>let docRef = db.collection(“users”);</blockquote><p>Lambda also provides the same convenience if you are using a Database like DynamoDB, except that you have to create an IAM role to allow access for Lambda function to DynamoDB. BTW it’s not that hard. You can do it by creating a function from Lambda console by choosing a blue-print or using a toolkit like Serverless.</p><p>The other thing Lambda lovers like most is execution types and triggers it provides. You can execute Lambda function as an event asynchronously so that the function executor can exit without waiting. Don’t worry, you can do the same by using pub-sub trigger functions in Firebase.</p><p>You can subscribe a function to a topic, and that function will execute when any function publishes a message to that topic.</p><blockquote><strong>Eg: Firebase sample pubsub function</strong><br>module.exports = functions.pubsub.topic(‘Say_Hello’).onPublish(event =&gt; {</blockquote><blockquote>});</blockquote><p>Firebase provides following triggers to trigger a function.</p><ul><li><a href="https://firebase.google.com/docs/functions/firestore-events">Cloud Firestore Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/database-events">Realtime Database Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/auth-events">Firebase Authentication Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/analytics-events">Google Analytics for Firebase Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/crashlytics-events">Crashlytics Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/gcp-storage-events">Cloud Storage Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/pubsub-events">Cloud Pub/Sub Triggers</a></li><li><a href="https://firebase.google.com/docs/functions/http-events">HTTP Triggers</a></li></ul><p>Regarding the pricing, as I could find on some blogs, AWS Lambda is the winner. But if you use HTTP endpoints in Lambda, you have to use API Gateway and the pricing of API gateway also will come into the picture.</p><p>For the final thoughts, Firebase functions is still in the beta whereas Lambda has played quite long in the market. So, obviously the resources and maturity level of Lambda will be higher, compared to the Firebase Functions. Also, Lambda supports a number of different programming languages as well. What will match to your project is depend on what is your project and how the project is going to deploy.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=303ab7a4759" width="1" height="1" alt=""><hr><p><a href="https://medium.com/shoutout-blog/google-firebase-functions-vs-aws-lambda-a-shallow-comparison-303ab7a4759">Google Firebase Functions vs AWS Lambda, A shallow comparison</a> was originally published in <a href="https://medium.com/shoutout-blog">ShoutOUT Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why are We Using ReactJS for Our Front-end?]]></title>
            <link>https://medium.com/shoutout-blog/why-in-the-hell-we-are-using-reactjs-for-our-frontend-f244286b2468?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/f244286b2468</guid>
            <category><![CDATA[angularjs]]></category>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[shoutout-engineering]]></category>
            <category><![CDATA[front-end-development]]></category>
            <category><![CDATA[frontend]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Wed, 08 Nov 2017 10:54:00 GMT</pubDate>
            <atom:updated>2017-11-27T05:49:34.037Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*JS9bmhYa1qr4hGj_QEXPTA.png" /></figure><blockquote>“Why we migrated our front-end to ReactJS from AngularJS”</blockquote><p>ReactJs has become a super hot topic these days. Yes, it has, because it should be! ☺️</p><p>Earlier we used AngularJS (1.x) and for a large amount of DOM related updates, it sucked.</p><p>In our application, ShoutOUT, before we switched into ReactJS, we used AngularJS for generating the contact list. In AngularJS, when the number of contacts increases, it takes like 5 seconds just to render the list. All together with the network delay and back-end delays, it takes like 10 seconds totally.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/989/0*ws3JvR38zfK9ywbI." /></figure><p>We tried different ways to fix this performance issue. We tried limiting the number of contacts getting from the back-end, improving the back-end performance to return the list fast, reducing the payload size, and also minimizing the front end DOM update element size. None of these worked up to the expected level because the problem is in the DOM rendering time. We were looking for a solution and found out that ReactJS solved this performance issue with the help of its Virtual DOM. ☺️</p><p>Well, with ReactJS, now it’s just a matter of loading the contacts from the back-end.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/315/0*LO-3q531RaNVZfuR." /></figure><p>As you can see now the total Rendering + Painting time is less than 200 ms. Forget the IDLE time as it’s the time gap between starting the recording and refreshing the loading. So the total time for loading and rendering the list is 889 milliseconds 😮 which is an awesome performance increase.</p><p>Okay. The next question is how to migrate our existing code base into ReactJS. Believe me, it’s just a matter of putting ReactJS libraries and a little bit of tweaking of the existing code which will take less than an hour.</p><p>Ex: Converting static HTML component into React component.</p><p>Original code:</p><h4>&lt;div class=”commentBox”&gt;<br> Hello, world! <br> &lt;/div&gt;</h4><p>Equal React component:</p><h4>var CommentBox = React.createClass({<br> render: function() {<br> return (<br> &lt;div className=”commentBox”&gt;<br> Hello, world! <br> &lt;/div&gt;<br> );<br> }<br>});</h4><ul><li>Wrap the content with render method</li><li>Change the class into className as class is a javascript reserved word</li></ul><p>Let’s check why the ReactJS is awesome.</p><p>The following comparison will answer most of your questions regarding why ReactJS is better in the performance aspect. By the way, one correction in the comparison, in ReactJS you can render in both client side and server side.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/681/0*TQWwcWAnFi9u3AEX." /><figcaption>Source: <a href="https://hackernoon.com/reactjs-vs-angular-comparison-which-is-better-805c0b8091b1">https://hackernoon.com/reactjs-vs-angular-comparison-which-is-better-805c0b8091b1</a></figcaption></figure><p>So, What is this Virtual DOM? Given below is the best explanation I’ve found so far.</p><p>“The Virtual DOM is an abstraction of the HTML DOM. It is lightweight and detached from the browser-specific implementation details. Since the DOM itself was already an abstraction, the virtual DOM is, in fact, an abstraction of an abstraction.” 😮</p><p>In a nutshell, Virtual DOM is an almost similar HTML DOM tree which doesn’t have browser specific implementation. And whenever you need to change the view, ReactJS will,</p><ul><li>recalculate its Virtual DOM</li><li>get the difference between previous Virtual DOM and the new one</li><li>update the actual DOM only at the node where there is an actual change along with its children.</li></ul><p>You can find more in detail <a href="https://medium.com/@gethylgeorge/how-virtual-dom-and-diffing-works-in-react-6fc805f9f84e">here</a>.</p><p>Don’t migrate your application to ReactJS just because I say 😉. It always depends on what your application is and what kind of functionalities it has. Sometimes Angular JS (1.x or 2.x) will perform better than ReactJS in your application. And of course you don’t have to migrate the whole application. What you can do is just migrate the components which have the performance issues. That will minimize your migration.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f244286b2468" width="1" height="1" alt=""><hr><p><a href="https://medium.com/shoutout-blog/why-in-the-hell-we-are-using-reactjs-for-our-frontend-f244286b2468">Why are We Using ReactJS for Our Front-end?</a> was originally published in <a href="https://medium.com/shoutout-blog">ShoutOUT Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Know the Unknown- Discover more from the Data at hand with Machine Learning]]></title>
            <link>https://medium.com/shoutout-blog/know-the-unknown-discover-more-from-the-data-at-hand-f9de8e95298?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/f9de8e95298</guid>
            <category><![CDATA[shoutout-engineering]]></category>
            <category><![CDATA[data-enrichment]]></category>
            <category><![CDATA[sms-and-email-campaigns]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[recurrent-neural-network]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Tue, 12 Sep 2017 16:50:38 GMT</pubDate>
            <atom:updated>2017-12-05T07:27:37.075Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Q3Kg0W1Tik1KCrcigoQvJw.jpeg" /></figure><blockquote>A machine-learning approach to derive new attributes from already existing attributes of people</blockquote><p>Let’s start this way. Take a look at the following names and see what you can guess about them.</p><p><strong>Disclaimer:</strong> If you are seeing these names for the first time in your life, don’t worry, because I have included names that are bound to my context. Just think about any name that comes to your mind and try the exercise.</p><ul><li>Adriana</li><li>Ashen</li><li>Gunapala</li><li>Aishwarya</li><li>Jibbran</li></ul><p>⏳ ⏳ ⌛ ⌛ ⏰ ⏰ 😃 😃</p><p>Okay. Time’s up. Following are my guesses.</p><ul><li>Adriana — Spanish, Female</li><li>Ashen — Sri Lankan, Male, Age 16–30, Christian</li><li>Gunapala — Sri Lankan, Male, Age above 45, Buddhist</li><li>Aishwarya — Indian, Female, Hindu</li><li>Jibbran — Arabian, Male, Muslim</li></ul><p>Just by looking at the name, we now know pretty much about them. Moreover, if you are familiar with the context, then you will be able to guess even better, just like how I (being a Sri Lankan familiar with those names ☺️) guessed the age group of “Ashen” and “Gunapala” . So, it’s clear that we can easily guess and find patterns with our general knowledge. However, it is not an easy task at all for computers. To teach these dumb machines, you need Machine Learning techniques.</p><p>I’m sure that you know the importance of such details as above for marketers. We, at ShoutOUT, continuously research about how we can make our tools more intelligent and user friendly in order to serve our customers better. And this is one such research that is currently being carried out at ShoutOUT Labs.</p><p>Okay, Let’s dive in. This part will be a little boring for the non-techies, but don’t you worry, you can still read and get the idea ☺️.</p><p>Initially in our research, what we looked at was finding the country of a person when the mobile number is present. Now that sounds like a really really easy task as you can extract the country code from the mobile number within a second.</p><p>But, no! It’s not as easy as it sounds.</p><p>People provide mobile numbers in different formats, for example, 94778123456, 0778123456, 778123456, +940778123456 and 94–0778123456. All the five numbers are the same mobile number, from Sri Lanka, but in different formats. At first, we wanted to write simple rule sets with data cleanup for this classification. Yes, we can, but we will end up with around 40 to 50 rules for Sri Lanka only. And it means, to cover all the formats in all the countries, we probably will need more than 10000 or 100000 rules. Who will volunteer to write such a large number of rules? (Not me, because 🎶 I am lazy and I know it 🎶😉 ).</p><p>So, we tried out several classification techniques and ended up with a feature based classifier. The features we considered were the first few digits and the length of the mobile number. We trained our classifier for Sri Lankan and Nigerian mobile numbers as we have data sets for those countries and it resulted in more than 90% of accuracy. If we use Recurrent Neural Network(RNN), may be we can achieve more accuracy than this (BTW, we need to find that out. ☺️ ). Furthermore, if we combine the results from the mobile number classification with the results of the name based classification, we may be able to achieve an accuracy close to 100%.</p><p>Name based classification is something we are working on right now, and as a clue, I’ll say that we will use a Recurrent Neural Network based classification initially (who knows. 😄).</p><p>The next major aspect we will be focusing on is the possibility of finding out the name or age from the email address of the customer (Wait what? 😮 Yes you heard me correct). As we all know, many people create their email addresses by combining their name and birth year. So, by extracting those details from a particular email address, we can get the customer name and also calculate the age.</p><p>You might be wondering now, that as a customer of ShoutOUT, how these researches will benefit your business.</p><p><strong>Data enrichment of your contacts!</strong> You can create more segments and target them better even if you have only a few details about your customers initially.</p><p>You will be able to create a campaign specifically for men, even if you have only the name and the mobile number/email address of your customers when you import the contacts, <strong>because we will find out the gender from the customer name.</strong></p><p>Sounds awesome, right? (Yep, it does!. I know! 😄)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f9de8e95298" width="1" height="1" alt=""><hr><p><a href="https://medium.com/shoutout-blog/know-the-unknown-discover-more-from-the-data-at-hand-f9de8e95298">Know the Unknown- Discover more from the Data at hand with Machine Learning</a> was originally published in <a href="https://medium.com/shoutout-blog">ShoutOUT Blog</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 Create a React Module — an Actual Example]]></title>
            <link>https://medium.com/shoutout-blog/how-to-create-a-react-module-an-actual-example-b6e53a7ec073?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/b6e53a7ec073</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[npm]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[shoutout-engineering]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Wed, 14 Jun 2017 13:19:19 GMT</pubDate>
            <atom:updated>2017-06-15T04:10:19.166Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vHHBwcUFUaHWXntSnqKdCA.png" /></figure><p>Hello to everyone out there who wants to know all about creating a React module. The React component module I created was for<a href="https://material.io/icons"> Google Material Icons</a>. (<a href="https://www.npmjs.com/package/react-google-material-icons">https://www.npmjs.com/package/react-google-material-icons</a>) .</p><p>To create this module, I followed the below post which worked fine for me. In case you feel like reading more on it, I would suggest you to read this post.</p><p><a href="https://medium.com/@jbscript/developing-react-components-and-libraries-with-nwb-2018059ea25a">https://medium.com/@jbscript/developing-react-components-and-libraries-with-nwb-2018059ea25a</a></p><p>Let’s get started peeps!</p><p><a href="https://medium.com/@jbscript/developing-react-components-and-libraries-with-nwb-2018059ea25a">Developing React Components and Libraries with nwb</a></p><h4>Prerequisites</h4><p>Of course, you need to have Nodejs and npm installed. 😎</p><p><strong>Install nwb globally</strong></p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7f42203583d989a13eceab76c11a32d6/href">https://medium.com/media/7f42203583d989a13eceab76c11a32d6/href</a></iframe><p><strong>Create the project</strong></p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1b3288f6752c5ea20da710e886ca8c8e/href">https://medium.com/media/1b3288f6752c5ea20da710e886ca8c8e/href</a></iframe><p>Here, the last argument is the project name and it will create a directory name with the above project name and all the required files under it. This will then generate some questions and what I did was to respond with ‘yes’ for ‘Es6 bundles’ and ‘UMD build for global usage’. If you enable UMD build, it will allow you to use the module with the global variable which will ask the next question. I added ‘ReactGoogleMaterialIcons’ as my UMD build set.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/954/1*FG2MAj76V4RYoIjgJc2_yg.jpeg" /></figure><p>Now the project is almost ready. It’s just a matter of doing your codes. :) If you want to confirm the setup before start coding, just run <strong>npm install</strong> &amp; then <strong>npm start . </strong>It will open up the application in the browser.</p><h4>The code</h4><p>I added the main.css file under src. Then I imported the Google Material font from their CDN in the css file itself.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/51df34de1c7cf64453901b0d2cb6e983/href">https://medium.com/media/51df34de1c7cf64453901b0d2cb6e983/href</a></iframe><p>Next, import it in the index.js and put the jsx code as below.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1ff0f3fe4182d3cbabce6f1f4be82c88/href">https://medium.com/media/1ff0f3fe4182d3cbabce6f1f4be82c88/href</a></iframe><p>The user can provide 2 properties to the module: the icon and its size. However, the size is an optional parameter (default is 24).</p><p><strong><em>Note</em></strong></p><p>I added ‘ — copy-files’ flag into build script in the package.json file because otherwise, the final build will not work since the default configuration does not copy the css file into ‘es’ and ‘lib’ directories.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/518/1*7GlBZfYndaZVsTbRLMfjoQ.jpeg" /></figure><p>In order to check the module, we have to write a test, under the directory called ‘demo’. In the index.js file, which is under the directory ‘demo’, I imported my module (index.js file which is under the directory ‘src’) and wrote few test cases.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/972cd641a7da4a589c55a50746574db6/href">https://medium.com/media/972cd641a7da4a589c55a50746574db6/href</a></iframe><p>That’s it. Let’s run the code.</p><p>First, run the command <strong>npm install </strong>if you haven’t run that before. Then run <strong>npm start </strong>. If everything is okay, you will get the following result.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/617/1*ypfW2E8CwKHKr6kccl8Bgw.jpeg" /></figure><h4>Publishing to npm</h4><p>Run <strong>npm run build</strong> command to build the package. Then run the command <strong>npm publish .</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b6e53a7ec073" width="1" height="1" alt=""><hr><p><a href="https://medium.com/shoutout-blog/how-to-create-a-react-module-an-actual-example-b6e53a7ec073">How to Create a React Module — an Actual Example</a> was originally published in <a href="https://medium.com/shoutout-blog">ShoutOUT Blog</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 Create SMS Enabled NodeJS App Within 5 Minutes]]></title>
            <link>https://medium.com/shoutout-blog/how-to-create-sms-enabled-nodejs-app-within-5min-4e145ee6a3e3?source=rss-d57dfc6f94e9------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e145ee6a3e3</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[sms-api]]></category>
            <category><![CDATA[shoutout-engineering]]></category>
            <category><![CDATA[shoutout]]></category>
            <category><![CDATA[nodejs]]></category>
            <dc:creator><![CDATA[Madura Pradeep]]></dc:creator>
            <pubDate>Fri, 27 Jan 2017 06:23:03 GMT</pubDate>
            <atom:updated>2017-07-06T09:42:13.801Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*TK0FeNnDtZTcApQYEmIaIQ.jpeg" /></figure><p>What can you do within 5 minutes? Make a cup of coffee? Now you can create an SMS enabled application using ShoutOUT Lite SDK for Node JS, in less than 5 minutes.</p><p>Don’t believe me? Okay then, set your clock now. :) ( 0 min 0 second)</p><p>Create a folder for your nodejs app and go to that directory. Open a terminal.</p><ol><li>Create an App (0 min 30 seconds)</li></ol><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4bbe4516c00f3a76333f163da920bbd6/href">https://medium.com/media/4bbe4516c00f3a76333f163da920bbd6/href</a></iframe><p>Give the application name and other details like version, author etc. (just press enter for default settings). In my case, the application name is mysmsclient.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/617/0*rtUGlUWhZnHA289y." /></figure><p>2. Install ShoutOUT SDK (1 min 15 seconds)</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/cc9450d408fd3cf2e85c66ba1334b51e/href">https://medium.com/media/cc9450d408fd3cf2e85c66ba1334b51e/href</a></iframe><p>This will download ShoutOUT SDK from npm (Node package manager. This will take some time to complete depending on your computer’s performance and network bandwidth).</p><p>3. Create a file name index.js in the directory (1 min 25 seconds)</p><p>4. Configure SDK (2 min 5 seconds)</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/650d4255020ea9a827458bb071a9d7a6/href">https://medium.com/media/650d4255020ea9a827458bb071a9d7a6/href</a></iframe><p>Configure SDK in your index.js as follows. Paste your API key on the 3rd line, instead of ‘API_KEY’ (Check step 5 to obtain your API Key).</p><p>5. Get your API Key from your ShoutOUT Lite profile (3 min 50 seconds)</p><p>a. Go to tools</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/225/0*J963NtF7nnQZDplu." /></figure><p>b. Click on Copy to Clipboard in API Keys section</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*tqGM5bDAGCewfy2e." /></figure><p>6. Configure your SMS (4 min 35 seconds)</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/375ae4c157c1b56119884bd4ee525c02/href">https://medium.com/media/375ae4c157c1b56119884bd4ee525c02/href</a></iframe><p>Change content, destination and source as required (Default source is “ShoutDEMO”. If you need to change that, you have to send a sender ID request from ShoutOUT Lite dashboard. In this 5 min tutorial, I will skip that step and use the default source)</p><p>7. Run the application (4 min 45 seconds)</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4bbc138c26544ebba3cb03a66f8bb520/href">https://medium.com/media/4bbc138c26544ebba3cb03a66f8bb520/href</a></iframe><p>Run the application. If everything is right, a message will be received to the destination number.</p><p>You have 15 seconds to like and share this post.. :D</p><p>Create your ShoutOUT account (Try it for free :))</p><p><a href="https://lite.getshoutout.com/">https://lite.getshoutout.com</a></p><p>Resources:</p><p><a href="http://docs.getshoutout.com/">http://docs.getshoutout.com</a></p><p><a href="https://github.com/shoutout-labs/shoutout-sdk-nodejs">https://github.com/shoutout-labs/shoutout-sdk-nodejs</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e145ee6a3e3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/shoutout-blog/how-to-create-sms-enabled-nodejs-app-within-5min-4e145ee6a3e3">How to Create SMS Enabled NodeJS App Within 5 Minutes</a> was originally published in <a href="https://medium.com/shoutout-blog">ShoutOUT Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>