<?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 Hamed Taheri on Medium]]></title>
        <description><![CDATA[Stories by Hamed Taheri on Medium]]></description>
        <link>https://medium.com/@hamed-taheri?source=rss-a6c6df8a2612------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*rzanhK2BJ_BwAgKAloyQkw.jpeg</url>
            <title>Stories by Hamed Taheri on Medium</title>
            <link>https://medium.com/@hamed-taheri?source=rss-a6c6df8a2612------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 29 Nov 2026 04:05:02 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@hamed-taheri/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[Add RTLCSS compiler in react-create-app]]></title>
            <link>https://hamed-taheri.medium.com/add-rtlcss-compiler-in-react-create-app-aa7a946a41e3?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/aa7a946a41e3</guid>
            <category><![CDATA[rtlcss]]></category>
            <category><![CDATA[style]]></category>
            <category><![CDATA[concurrently]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[css]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Thu, 03 Jun 2021 12:26:49 GMT</pubDate>
            <atom:updated>2021-06-03T12:26:49.501Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/316/1*v15TttYm_XDwVSoufOlg6A.png" /></figure><p>If you want to transform your LTR CSS into RTL style, one way is using the RTLCSS library. Now without any overhead, we will add the pipeline in the package.json without any ejecting script.</p><h3>1- Add these libraries</h3><pre>yarn add rtlcss nodemon concurrently</pre><h3>2- Add these scripts into the script section of your package.json file.</h3><pre>&quot;scripts&quot;: {<br>    &quot;less-rtl&quot;: &quot;rtlcss src/main.css src/main.rtl.css&quot;,<br>    &quot;less-rtl-watch&quot;: &quot;nodemon --quiet --watch src/main.css -x \&quot;npm run less-rtl\&quot;&quot;,<br>    &quot;prestart&quot;: &quot;npm run less-rtl&quot;,<br>    &quot;prebuild&quot;: &quot;npm run less-rtl&quot;,<br>    &quot;start&quot;: &quot;concurrently --kill-others \&quot;npm run less-rtl-watch\&quot; \&quot;react-scripts start\&quot;&quot;,<br>    &quot;build&quot;: &quot;react-scripts build&quot;,<br>    &quot;test&quot;: &quot;react-scripts test&quot;,<br>    &quot;eject&quot;: &quot;react-scripts eject&quot;<br>  },</pre><p>Note: the ‘src/main.css’ is the default source style file, and the ‘src/main.rtl.css’ the compiled RTL file. You can change it based on your needs.</p><p>Note: the concurrently npm will run multiple commands in different treads. And ‘kill-others’ parameter will kill the processes if one of them has been terminated.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=aa7a946a41e3" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Create LESS style compiler pipeline in React without ejecting command]]></title>
            <link>https://hamed-taheri.medium.com/create-less-style-compiler-pipeline-in-react-without-ejecting-command-60160bca1928?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/60160bca1928</guid>
            <category><![CDATA[create-react-app]]></category>
            <category><![CDATA[postcss]]></category>
            <category><![CDATA[less]]></category>
            <category><![CDATA[compilers]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Thu, 03 Jun 2021 11:43:11 GMT</pubDate>
            <atom:updated>2021-06-03T11:59:15.918Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/552/1*owMF-cyqgBD93Z3elqpxHA.png" /></figure><p>If you want to add a LESS compiler into your Create-react-app project without ejecting and painless just with some package.json scripts, follow me.</p><h3>1- Install these libs</h3><pre>yarn add less less-watch-compiler concurrently</pre><h3>2- Create these files in the root directory of your project</h3><pre>// This will be used with &quot;less&quot; script in package.json<br>less-watch-compiler.config.json</pre><pre>{<br>  &quot;watchFolder&quot;: &quot;src/assets/less/src&quot;,<br>  &quot;outputFolder&quot;: &quot;src/assets/less/dist&quot;,<br>  &quot;mainFile&quot;: &quot;main.less&quot;,<br>  &quot;runOnce&quot;: true,<br>  &quot;enableJs&quot;: true<br>}</pre><pre>//------------------------------------------------------<br>// The below will be used with &quot;less-watch&quot; script in package.json</pre><pre>less-watch-compiler.dev.config.json</pre><pre>{<br>  &quot;watchFolder&quot;: &quot;src/assets/less/src&quot;,<br>  &quot;outputFolder&quot;: &quot;src/assets/less/dist&quot;,<br>  &quot;mainFile&quot;: &quot;main.less&quot;,<br>  &quot;runOnce&quot;: false,<br>  &quot;enableJs&quot;: true<br>}</pre><p>Note: the main file in the src folder has the main.less file. You can change it based on your desire.</p><h3>3- Create the below directories and set your .less files into src/assets/less/src directory</h3><pre>src/assets/less/src<br>src/assets/less/dist</pre><h3>4- Add these line of codes in a script section of your package.json file.</h3><pre>&quot;scripts&quot;: {<br>    &quot;less&quot;: &quot;less-watch-compiler&quot;,<br>    &quot;less-watch&quot;: &quot;less-watch-compiler --config less-watch-compiler.dev.config.json&quot;,<br>    &quot;prestart&quot;: &quot;npm run less&quot;,<br>    &quot;prebuild&quot;: &quot;npm run less&quot;,<br>    &quot;run-server&quot;: &quot;npx serve -s build&quot;,<br>    &quot;start&quot;: &quot;concurrently --kill-others \&quot;npm run less-watch\&quot; \&quot;react-scripts start\&quot;&quot;,<br>    &quot;build&quot;: &quot;react-scripts build&quot;,<br>    &quot;test&quot;: &quot;react-scripts test&quot;,<br>    &quot;eject&quot;: &quot;react-scripts eject&quot;<br>  },</pre><p>Note:<br>in the start script, we have used the ‘concurrently’ library to start 2 commands in a different thread. So the ‘less-watch’ and ‘react-script start’ will run concurrently.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=60160bca1928" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Integrate Tailwind v2 in React project without using CRACO]]></title>
            <link>https://hamed-taheri.medium.com/integrate-tailwind-v2-in-react-project-without-using-craco-facf3560aa39?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/facf3560aa39</guid>
            <category><![CDATA[create-react-app]]></category>
            <category><![CDATA[tailwind]]></category>
            <category><![CDATA[tailwind-css]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[reactjs]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Mon, 17 May 2021 12:27:19 GMT</pubDate>
            <atom:updated>2021-06-13T10:40:45.471Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/805/1*zI8zuTAc0czV7oyMlgmBxg.png" /></figure><p>What is the problem?</p><p>If you want to add Tailwindcss V2 in React project (CRA), you have to use compatibility mode and use CRACO npm instead of react-scripts. I&#39;m not too fond of this method, and I prefer to use it another way without altering the ‘react-scripts’ script.</p><p>1- install these libs</p><pre>yarn add tailwindcss@npm:<a href="http://twitter.com/tailwindcss/postcss7-compat">@tailwindcss/postcss7-compat</a> postcss-cli@⁷ autoprefixer@⁹ cross-env</pre><p>2- Add these scripts into the package.json file under the scripts section, at the top of all other scripts</p><pre>&quot;css&quot;: &quot;postcss ./src/assets/tailwind/tailwind.css -o ./src/assets/tailwind/tailwind.generated.css&quot;,<br>&quot;prestart&quot;: &quot;npm run css&quot;,<br>&quot;prebuild&quot;: &quot;cross-env NODE_ENV=production npm run css&quot;,<br>&quot;run-server&quot;: &quot;npx serve -s build&quot;,</pre><p><em>After that, the file should like this:</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/969/1*fnfonq22ZVTiBtgVRWN-rw.png" /></figure><p>Note: all scripts with the ‘pre’ prefix will automatically be run in yarn and npm when you call the main script. e.g., when you call ‘<strong>yarn start’, </strong>the <strong>prestart</strong> script automatically will be run before executing the <strong>start</strong> script.</p><p>3- Under the src directory, create these directories and paths:</p><pre>./src/assets/tailwind/tailwind.css</pre><pre>./src/assets/tailwind/tailwind.generated.css</pre><p>4- Put these codes inside the <strong>tailwind.css </strong>and leave<strong> tailwind.generated.css</strong> empty</p><pre>@tailwind base;</pre><pre>@tailwind components;</pre><pre>@tailwind utilities;</pre><p>5- inside the project&#39;s root directory, create a <strong>postcss.config.js</strong> file and put this code inside it.</p><pre>const tailwindcss = require(&quot;tailwindcss&quot;);</pre><pre>module.exports = {</pre><pre>plugins: [tailwindcss(&quot;./tailwind.config.js&quot;), require(&quot;autoprefixer&quot;)],</pre><pre>};</pre><p>6- Next, generate your tailwind.config.js file. This will create a minimal tailwind.config.js file at the root of your project:</p><pre>npx tailwindcss init</pre><p>In your tailwind.config.js file, configure the purge option with the paths to all of your components so Tailwind can tree-shake unused styles in production builds. Alter the purge section by adding the below code to it:</p><pre>module.exports = {<br>  purge: [&quot;./src/**/*.{js,jsx,ts,tsx,html}&quot;, &quot;./public/index.html&quot;],<br>  <br>...<br>...</pre><pre>};</pre><p>Finally, it must be like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/711/1*e27iiYq9rgpItZUMk1AmMQ.png" /></figure><p>Congratulations, All steps have been done. Now just run <strong>yarn start</strong> or <strong>yarn build</strong>.</p><h3>In your Tailwind config file, set !important to true.</h3><pre>javascript<br>// tailwind.config.js<br>module.exports = {<br>  important: true,<br>};</pre><p>Now, all of Tailwind’s utility classes will be generated as !important:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/298/1*jffAZb-v6kVgyu78g3TH8A.png" /></figure><h3>Bonus :</h3><p>After you build the project with ‘<strong>yarn build</strong>’, if you want to test the production build, use this command at the root of your project:</p><pre>yarn run-server</pre><h3>Plugins:</h3><p>1- The <a href="https://github.com/jorenvanhee/tailwindcss-debug-screens">TailwindCSS Debug Screens</a> plugin will let you display the currently active screen in development mode. It does not take more than a few seconds to set up, and it will probably save you a lot of time in the long run. This is how you can install it:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/746/1*r5AD-XYysRoWKt5WEUYVsg.png" /></figure><pre>yarn add tailwindcss-debug-screens -D</pre><p>in tailwind.config.js file:</p><pre>javascript<br>// tailwind.config.js<br>module.exports = {<br>  plugins: [require(&quot;tailwindcss-debug-screens&quot;)],<br>};</pre><p>Add the class debug-screens to your &lt;body&gt; tag in public.index.html</p><pre>&lt;body class=&quot;debug-screens&quot;&gt;&lt;/body&gt;</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=facf3560aa39" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CSS Selector Tutorial]]></title>
            <link>https://hamed-taheri.medium.com/css-selector-tutorial-171f5b64f945?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/171f5b64f945</guid>
            <category><![CDATA[css3]]></category>
            <category><![CDATA[css]]></category>
            <category><![CDATA[learn-css]]></category>
            <category><![CDATA[css-selectors]]></category>
            <category><![CDATA[css-tutorial]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Tue, 24 Mar 2020 06:20:31 GMT</pubDate>
            <atom:updated>2020-03-24T06:20:31.080Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZEFdeen2C3LlCDKIhJhpcA.png" /></figure><blockquote>Do you want to become a master in CSS 3 Selectors?<br>Do not miss this tutorial. CSS selectors are used to selecting the content you want to style. Selectors are the part of the CSS ruleset. CSS selectors select HTML elements according to its id, class, type, attribute, etc. There are several different types of selectors in CSS:<br>CSS Element Selector<br>CSS Id Selector CSS <br>Class Selector CSS <br>Type Selector CSS <br>Attribute Selector and etc.</blockquote><h4>See this video :</h4><p><a href="https://youtu.be/rPhi5j19_50?sub_confirmation=1">https://youtu.be/rPhi5j19_50?sub_confirmation=1</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=171f5b64f945" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Should you learn jQuery in 2020]]></title>
            <link>https://hamed-taheri.medium.com/should-you-learn-jquery-in-2020-2a1a7ea4e66a?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/2a1a7ea4e66a</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[tutorial]]></category>
            <category><![CDATA[learn]]></category>
            <category><![CDATA[jquery]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Fri, 20 Mar 2020 21:10:17 GMT</pubDate>
            <atom:updated>2020-03-20T21:10:17.519Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/770/1*hTso1SS-jLsj6Iyo5kDqhQ.png" /></figure><p>Should we learn and use jquery in 2020? in this video you can see some examples of usage and new modern browsers feature to support and overlap jquery.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FYILp6ALWRss%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DYILp6ALWRss&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FYILp6ALWRss%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/73b4e9dc42d2934499aa554cb60aaef1/href">https://medium.com/media/73b4e9dc42d2934499aa554cb60aaef1/href</a></iframe><h4>Watch and subscribe on youtube:</h4><p><a href="https://youtu.be/YILp6ALWRss?sub_confirmation=1">https://youtu.be/YILp6ALWRss?sub_confirmation=1</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2a1a7ea4e66a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to speed up your windows 10]]></title>
            <link>https://hamed-taheri.medium.com/how-to-speed-up-your-windows-10-ed5fa46660dc?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/ed5fa46660dc</guid>
            <category><![CDATA[disable-startup-apps]]></category>
            <category><![CDATA[increase-speed-windows-10]]></category>
            <category><![CDATA[performance]]></category>
            <category><![CDATA[windows-10]]></category>
            <category><![CDATA[windows-10-tricks]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Mon, 16 Mar 2020 22:35:17 GMT</pubDate>
            <atom:updated>2020-03-16T22:35:17.584Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jm_lOX6OLQxhnfTrCcQbFw.png" /></figure><h3>Boost your Windows 10 operating system</h3><p>In this tutorial, I am going to teach you<strong> 8 tips </strong>to boost your computer performance.</p><p>If your PC is running slow, use these tips to speed up and increase the performance of Windows 10. This video is created based on the latest version of Windows 10.</p><p>However, if you’re dealing with a sluggish PC, it doesn’t necessarily mean that you need to replace it. just chase us and apply these tricks to your windows 10 OS.</p><p>These are the list of things that you will learn in this tutorial:</p><p><em>1- Disable start-up apps</em></p><p><em>2- Turn on fast start-up</em></p><p><em>3- No tipping</em></p><p><em>4- Disk clean up</em></p><p><em>5- No special effects</em></p><p><em>6- Disable background apps</em></p><p><em>7- uninstall non-essential apps</em></p><p><em>8- Reclaim Hard Drive Space</em></p><h3><strong>Watch my video about these steps:</strong></h3><p><a href="https://www.youtube.com/watch?v=4F3BDjmFgq0?sub_confirmation=1">https://www.youtube.com/watch?v=4F3BDjmFgq0?sub_confirmation=1</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ed5fa46660dc" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[React Redux Global State Manager]]></title>
            <link>https://hamed-taheri.medium.com/react-redux-global-state-manager-13653439dbae?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/13653439dbae</guid>
            <category><![CDATA[react-hook]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[redux]]></category>
            <category><![CDATA[state-management]]></category>
            <category><![CDATA[react-native]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Sun, 15 Dec 2019 13:48:51 GMT</pubDate>
            <atom:updated>2019-12-15T13:48:51.910Z</atom:updated>
            <content:encoded><![CDATA[<p>Fully native global state manager using react Hooks. You can use this library instead of Redux or Mobx. also, you can access state from all of your components and behavior with them using hooks.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/636/1*dKZbVN7Y7_frNy_YSbCA6Q.jpeg" /></figure><h3>Work on both React and React-Native</h3><p>Fully native global state manager using react Hooks (React &gt; 16.8). You can use this library instead of Redux or MobX. also, you can access state from all of your components and behavior with them using hooks.</p><p>A nice state management lib for React that uses the React’s useState hook. Which basically means no magic behind the curtains, only pure react APIs being used to share state across components.</p><h3>Example:</h3><h3>Installation</h3><h4>yarn</h4><blockquote><em>yarn add react-redux-global-state-manager</em></blockquote><h4>MPM</h4><blockquote><em>npm i react-redux-global-state-manager</em></blockquote><h3>Usage:</h3><p>Just in 4 simple steps, you can use this state manager in your app. to see the full details please visit the below GitHub repository:</p><p><a href="https://github.com/intellidev1991/react-redux-global-state-manager">intellidev1991/react-redux-global-state-manager</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=13653439dbae" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Useful Tips for React]]></title>
            <link>https://hamed-taheri.medium.com/useful-tips-for-react-17c378d9b515?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/17c378d9b515</guid>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[react-hook]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[hooks]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Tue, 29 Oct 2019 10:58:15 GMT</pubDate>
            <atom:updated>2019-10-29T10:58:15.281Z</atom:updated>
            <content:encoded><![CDATA[<p>Hi there, I try to collect some of the most important tricks, tips and snippets code for react developers to create an awesome react app.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*V7UIIU0G4pK15vtd8vSgiQ.jpeg" /></figure><h3>Create-React-App for support IE-11</h3><pre><strong>Step1:<br></strong>yarn add react-app-polyfill</pre><pre><strong>Step2:<br></strong>add these 2 lines at the very most top of index.js before import react.<br>// --- Support EI-11 for react app<br>import &#39;react-app-polyfill/ie11&#39;;<br>import &#39;react-app-polyfill/stable&#39;;<br>// ---</pre><pre><strong>Step3:</strong> <br>add <strong>&quot;ie 11&quot;</strong> into <strong>package.json</strong> for both sub section of browserslist:</pre><pre>&quot;browserslist&quot;: {<br>    &quot;production&quot;: [<br>      &quot;&gt;0.2%&quot;,<br>      &quot;not dead&quot;,<br>      &quot;not op_mini all&quot;,<br>      <strong><em>&quot;ie 11&quot;</em></strong><br>    ],<br>    &quot;development&quot;: [<br>      &quot;last 1 chrome version&quot;,<br>      &quot;last 1 firefox version&quot;,<br>      &quot;last 1 safari version&quot;,<br>      <strong><em>&quot;ie 11&quot;</em></strong><br>    ]<br>  }</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=17c378d9b515" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[React-Native Useful Tips]]></title>
            <link>https://hamed-taheri.medium.com/react-native-useful-tips-cffdb22d1991?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/cffdb22d1991</guid>
            <category><![CDATA[react-native-tips]]></category>
            <category><![CDATA[react-native-development]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[react-native-snippet]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Fri, 17 May 2019 12:08:06 GMT</pubDate>
            <atom:updated>2019-10-29T10:58:58.369Z</atom:updated>
            <content:encoded><![CDATA[<h3>Useful Tips For React-Native</h3><p>Hi there, I try to collect some of the most important tricks, tips and snippets code for react developers to create an awesome react-native app.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZJp3cbs1c6N02eQNynERAA.jpeg" /></figure><h3>package.json scripts</h3><pre>&quot;scripts&quot;: {<br>    &quot;shake&quot;: &quot;adb shell input keyevent 82&quot;,<br>    &quot;run-a&quot;: &quot;react-native run-android&quot;,<br>    &quot;run-i&quot;: &quot;react-native run-ios&quot;,<br>    &quot;clean&quot;: &quot;cd ./android &amp;&amp; ./gradlew clean&quot;,<br>    &quot;android&quot;: &quot;cd ./android &amp;&amp; ./gradlew app:assembleDebug &amp;&amp; ./gradlew installDebug&quot;,<br>    &quot;build:an&quot;: &quot;cd android &amp;&amp; gradlew assembleRelease&quot;<br>},</pre><p>Scripts description:[npm run ScriptName]<br>clean =&gt; clean old fetch libs and dependencies for android.<br>android =&gt; download and install new dependencies, run this after clear<br>build:an =&gt; build release APK (need to do signing process)<br>shake =&gt; shake emulator</p><h3>Update React-native-CLI</h3><pre>npm uninstall -g react-native-cli<br>npm install -g react-native-cli</pre><h3>Create-React-App for support IE-11</h3><pre><strong>Step1:<br></strong>yarn add react-app-polyfill</pre><pre><strong>Step2:<br></strong>add these 2 lines at the very most top of index.js before import react.</pre><pre>// --- Support EI-11 for react app<br>import &#39;react-app-polyfill/ie11&#39;;<br>import &#39;react-app-polyfill/stable&#39;;<br>// ---</pre><pre><strong>Step3:</strong> add <strong>&quot;ie 11&quot;</strong> into package.json for both sub section of browserslist:</pre><pre>&quot;browserslist&quot;: {<br>    &quot;production&quot;: [<br>      &quot;&gt;0.2%&quot;,<br>      &quot;not dead&quot;,<br>      &quot;not op_mini all&quot;,<br>      <strong><em>&quot;ie 11&quot;</em></strong><br>    ],<br>    &quot;development&quot;: [<br>      &quot;last 1 chrome version&quot;,<br>      &quot;last 1 firefox version&quot;,<br>      &quot;last 1 safari version&quot;,<br>      <strong><em>&quot;ie 11&quot;</em></strong><br>    ]<br>  }</pre><h3>ProjectName/android/app/debug.keystore’ not found for signing config ‘debug’ in react-native</h3><p>You can generate the debug keystore by running this command in the <strong>android/app/</strong> directory:</p><pre>keytool -genkey -v -keystore debug.keystore -storepass android -alias androiddebugkey -keypass android -keyalg RSA -keysize 2048 -validity 10000</pre><h3>Generating Signed APK</h3><p>1- Go to C:\Program Files\Java\jdkx.x.x_x\bin and then use keytool<br>2- Run below script in the terminal from the above address and answer to questions (password, names and…):</p><pre>keytool -genkeypair -v -keystore my-release-key.keystore -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000</pre><p>3-The, in current directory <strong>my-release-key.keystore</strong> will be available. Copy It<br>4-Place the my-release-key.keystore file under the android/app the directory in your project folder.<br>5-Edit the file ~/.gradle/gradle.properties or android/gradle.properties, and add the following (replace ***** with the correct keystore password, alias and key password),</p><pre>MYAPP_RELEASE_STORE_FILE=my-release-key.keystore MYAPP_RELEASE_KEY_ALIAS=my-key-alias MYAPP_RELEASE_STORE_PASSWORD=***** MYAPP_RELEASE_KEY_PASSWORD=*****</pre><p>6- Edit the file android/app/build.gradle in your project folder, and add the signing config, <strong>(Bold texts must be added)</strong></p><pre>... <br>android {<br> ...     <br>defaultConfig {<br> ... <br>}     </pre><pre><strong>signingConfigs <br>{         <br>  release {<br>   if (project.hasProperty(&#39;MYAPP_RELEASE_STORE_FILE&#39;)) {                     storeFile file(MYAPP_RELEASE_STORE_FILE)                 storePassword MYAPP_RELEASE_STORE_PASSWORD<br>keyAlias MYAPP_RELEASE_KEY_ALIAS<br>keyPassword MYAPP_RELEASE_KEY_PASSWORD<br>    }<br>  }<br>}</strong></pre><pre>buildTypes {         <br>     release {<br>         ...<br>        <strong> signingConfig signingConfigs.release</strong>         <br>     }     <br>} </pre><pre>}<br> ...</pre><p>7-Generating the release APK: Simply run the following in a terminal:<br><em>run ‘build:an’ script from above section(scripts) </em><br><strong><em>cd android &amp;&amp; gradlew assembleRelease</em></strong></p><pre>npm run build:an</pre><p>8- The generated APK can be found under android/app/build/outputs/apk/release/app-release.apk, and is ready to be distributed.</p><p>9- Go to the above address and run below script in Terminal from current location to install signed <strong>APK </strong>to the connected device (real device or emulator)</p><pre>adb install app-release.apk</pre><p>Reference:<br>https://facebook.github.io/react-native/docs/signed-apk-android</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cffdb22d1991" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[React Native Image Slider Box]]></title>
            <link>https://hamed-taheri.medium.com/react-native-image-slider-box-6f18462ab836?source=rss-a6c6df8a2612------2</link>
            <guid isPermaLink="false">https://medium.com/p/6f18462ab836</guid>
            <category><![CDATA[react-native-image]]></category>
            <category><![CDATA[react-native-image-slider]]></category>
            <category><![CDATA[react-native-slider-box]]></category>
            <category><![CDATA[react-native-component]]></category>
            <category><![CDATA[react-native]]></category>
            <dc:creator><![CDATA[Hamed Taheri]]></dc:creator>
            <pubDate>Tue, 09 Apr 2019 15:06:34 GMT</pubDate>
            <atom:updated>2019-12-15T13:33:28.608Z</atom:updated>
            <content:encoded><![CDATA[<p>A simple and fully customizable React Native component that implements an Image Slider UI.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*UNQHBlbHH0UdeNiMpPnUEg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/369/1*MBeIEqypQ4buEuAjEcD-8g.gif" /></figure><h3>Install</h3><ol><li>First, install our library | use below <em>npm</em> or <em>yarn </em>script</li></ol><blockquote><strong><em>npm i react-native-image-slider-box</em></strong></blockquote><blockquote><strong><em>yarn add react-native-image-slider-box</em></strong></blockquote><p>2. (Optional) : if you want to use third-party image library such as FastImage</p><blockquote><strong><em>npm i react-native-fast-image</em></strong></blockquote><blockquote><strong><em>yarn add react-native-fast-image</em></strong></blockquote><p>Well-done.</p><h3>Usage:</h3><h4>1- Add below import in your code :</h4><pre><strong>import</strong> { SliderBox } <strong>from</strong> &#39;react-native-image-slider-box&#39;;</pre><h4>2- Define your image array source, for below examples I create an array in the state.</h4><pre>export default class App extends Component {   <br>constructor(props) {     <br>super(props);     <br>this.state = {       <br>images: [         <br>&quot;https://source.unsplash.com/1024x768/?nature&quot;,                 &quot;https://source.unsplash.com/1024x768/?water&quot;,  &quot;https://source.unsplash.com/1024x768/?girl&quot;,         &quot;https://source.unsplash.com/1024x768/?tree&quot;, // Network image         require(&#39;./assets/images/girl.jpg&#39;),          // Local image       <br>]     <br>};   <br>}   // other component code ... }</pre><h4>Example 1: SliderBox without and handler or customization</h4><pre><strong>&lt;</strong>SliderBox images<strong>=</strong>{this.state.images} <strong>/&gt;</strong></pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*pieoD6Z3V7vXpR8YcsRMPQ.jpeg" /></figure><h4>Example 7: SliderBox with change paging box padding (Vertical height from the bottom of SliderBox) + add a circleLoop attribute for a jump to the first image after swipe the last image.</h4><pre>&lt;SliderBox   <br>images={this.state.images}   <br>sliderBoxHeight={200}   <br>onCurrentImagePressed={<br>  index =&gt; console.warn(`image ${index} pressed`)<br>}  <br>dotColor=&quot;#FFEE58&quot;   <br>inactiveDotColor=&quot;#90A4AE&quot;   <br>paginationBoxVerticalPadding={20}   <br>autoplay   <br>circleLoop /&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*u58OFR85TzsntNJYiZwVsA.jpeg" /></figure><h4>To see the full document and more examples please see the NPM page.</h4><p><a href="https://www.npmjs.com/package/react-native-image-slider-box">react-native-image-slider-box</a></p><p>Github repository:</p><p><a href="https://github.com/intellidev1991/react-native-image-slider-box">intellidev1991/react-native-image-slider-box</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6f18462ab836" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>