<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Kingsley onyelo</title>
    <description>The latest articles on DEV Community by Kingsley onyelo (@kingsoo123).</description>
    <link>https://dev.to/kingsoo123</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F562580%2Fb57e82c3-7b5f-4e97-b944-62af53b7aa19.jpeg</url>
      <title>DEV Community: Kingsley onyelo</title>
      <link>https://dev.to/kingsoo123</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/kingsoo123"/>
    <language>en</language>
    <item>
      <title>Understanding the useRef Hook in React A Comprehensive Guide</title>
      <dc:creator>Kingsley onyelo</dc:creator>
      <pubDate>Wed, 28 Jun 2023 16:01:20 +0000</pubDate>
      <link>https://dev.to/kingsoo123/understanding-the-useref-hook-in-react-a-comprehensive-guide-1l9h</link>
      <guid>https://dev.to/kingsoo123/understanding-the-useref-hook-in-react-a-comprehensive-guide-1l9h</guid>
      <description>&lt;p&gt;Hello again friends! In this article, I'm going to be explaining all you need to know about the useRef hooks. But before I go on, let me give a brief insight of what react hooks are. &lt;/p&gt;

&lt;p&gt;React Hooks are simple JavaScript functions that we can use to isolate the reusable part from a functional component. Hooks can be stateful and can manage side-effects. React provides a bunch of standard in-built hooks: useState : To manage states. Returns a stateful value and an updater function to update it.&lt;/p&gt;

&lt;p&gt;Alright now let's dive into the main topic, the useRef(initialValue) is a built-in React hook that accepts one argument as the starting value and returns a reference (aka ref). A reference is an object having a special property current .&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import { useRef } from 'react';

function MyComponent() {
  const startingValue = 0;
  const reference = useRef(startingValue);

  const someHandler = () =&amp;gt; {
    // Access reference value:
    const value = reference.current;

    // Update reference value:
    reference.current = newValue;
  };

  // ...
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;reference.current accesses the reference value, and reference.current = newValue updates the reference value. Pretty easy right?&lt;/p&gt;

&lt;p&gt;The two things to remember about references:&lt;/p&gt;

&lt;p&gt;1.The value of the reference is persisted (remains unchanged) between component re-renderings;&lt;/p&gt;

&lt;p&gt;2.Updating a reference doesn't trigger a component re-rendering.&lt;br&gt;
Now, let's see how to use useRef() in practice.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import { useRef } from 'react';

function LogButtonClicks() {
  const countRef = useRef(0);

  const handle = () =&amp;gt; {
    countRef.current++;
    console.log(`Clicked ${countRef.current} times`);
  };

  console.log('I rendered!');

  return(
&amp;lt;&amp;gt;
&amp;lt;input type="text" ref = {countRef}/&amp;gt;
&amp;lt;button onClick={handle}&amp;gt;Click me&amp;lt;/button&amp;gt;
&amp;lt;/&amp;gt;

);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Using const countRef = useRef(0), a reference with the initial value of 0 is created.&lt;/p&gt;

&lt;p&gt;At the point when the button is clicked, handle callback is summoned and the reference esteem is augmented: countRef.current++. After that, the console is logged with the reference value.&lt;/p&gt;

&lt;p&gt;Refreshing the reference esteem countRef.current++ doesn't set off part re-delivering. "I rendered!" shows that this is the case. is logged to the console only once during initial rendering, and when the reference is updated, there is no re-rendering.&lt;/p&gt;

&lt;p&gt;I hope this short explanation helps, thank you for reading&lt;/p&gt;

</description>
    </item>
    <item>
      <title>HOW THE PROVIDER DESIGN PATTERN</title>
      <dc:creator>Kingsley onyelo</dc:creator>
      <pubDate>Sun, 25 Jun 2023 17:03:48 +0000</pubDate>
      <link>https://dev.to/kingsoo123/how-the-provider-design-pattern-1dea</link>
      <guid>https://dev.to/kingsoo123/how-the-provider-design-pattern-1dea</guid>
      <description>&lt;p&gt;This article aims at showing you how to implement the provider design pattern. But first, you need to know what are the various design patterns used in building a react application.&lt;/p&gt;

&lt;p&gt;There are about six design patterns commonly used when building a react application and they are;&lt;br&gt;
1.Higher order component design pattern&lt;br&gt;
2.State reducer design pattern&lt;br&gt;
3.Render props component design pattern&lt;br&gt;
4.Provider design pattern&lt;br&gt;
5.Presentational and container component design pattern&lt;br&gt;
6.Hooks design pattern&lt;/p&gt;

&lt;p&gt;The most commonly used design pattern is Render props component, In some cases, we want to make data accessible to all or most application components. Even though we can use props to pass data to components, it can be hard if almost all of your application's components need access to the props' value.&lt;/p&gt;

&lt;p&gt;When props are passed far down the component tree, we frequently experience what is known as prop drilling. It becomes nearly impossible to refactor the props-dependent code, and it is difficult to determine where particular data originates.&lt;/p&gt;

&lt;p&gt;The Provider Pattern can be of assistance to us in this regard! We can make data available to multiple components using the Provider Pattern. We can wrap each component in a Provider rather than passing that data through props at each layer. The Context object gives us a Provider, a higher-order component. The createContext method that React provides allows us to create a Context object.&lt;/p&gt;

&lt;p&gt;The Provider receives a value prop, which contains the data that we want to pass down. All components that are wrapped within this provider have access to the value of the value prop.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const DataContext = React.createContext()

function App() {
  const data = { ... }

  return (
    &amp;lt;div&amp;gt;
      &amp;lt;DataContext.Provider value={data}&amp;gt;
        &amp;lt;SideBar /&amp;gt;
        &amp;lt;Content /&amp;gt;
      &amp;lt;/DataContext.Provider&amp;gt;
    &amp;lt;/div&amp;gt;
  )
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here, we have eliminated the problem of passing data down to each component using props.&lt;/p&gt;

&lt;p&gt;Each component can get access to the data, by using the useContext hook. This hook receives the context that data has a reference with, DataContext in this case. The useContext hook lets us read and write data to the context object.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function ListItem() {
  const { data } = React.useContext(DataContext);
  return &amp;lt;span&amp;gt;{data.listItem}&amp;lt;/span&amp;gt;;
}

function Text() {
  const { data } = React.useContext(DataContext);
  return &amp;lt;h1&amp;gt;{data.text}&amp;lt;/h1&amp;gt;;
}

function Header() {
  const { data } = React.useContext(DataContext);
  return &amp;lt;div&amp;gt;{data.title}&amp;lt;/div&amp;gt;;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The Provider pattern is very useful for sharing global data. A common use case for the provider pattern is sharing a theme UI state with many components.&lt;/p&gt;

&lt;p&gt;Thank you for reading.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>HOW TO IMPLEMENT GOOGLE MAPS API IN YOUR EXPO REACT NATIVE PROJECT EASILY</title>
      <dc:creator>Kingsley onyelo</dc:creator>
      <pubDate>Sat, 24 Jun 2023 10:07:37 +0000</pubDate>
      <link>https://dev.to/kingsoo123/how-to-implement-google-maps-api-in-your-expo-react-native-project-easily-nfi</link>
      <guid>https://dev.to/kingsoo123/how-to-implement-google-maps-api-in-your-expo-react-native-project-easily-nfi</guid>
      <description>&lt;p&gt;In this article I am going to show you how you can easily integrate google maps in your expo react native project with just 3 libraries from google nom package.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Google Map?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Google Maps is a web service that provides detailed information about geographical regions and sites worldwide. In addition to conventional road maps, Google Maps offers aerial and satellite views of many locations. In some cities, Google Maps offers street views comprising photographs taken from vehicles.&lt;/p&gt;

&lt;p&gt;If you're looking at building apps that are in the logistics, food delivery or ride hailing business, then having a google maps feature is highly needed for geolocation and tracking .&lt;/p&gt;

&lt;p&gt;Now that we grasped what Google map is, let's get into the code proper.&lt;/p&gt;

&lt;p&gt;First you want to start a new expo project using the command as follow;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npx create-expo-app GooglemapProject &amp;amp;&amp;amp; cd GooglemapProject
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once your expo project is created cd into the project folder and run the command to start the project on your emulator or physical device.&lt;/p&gt;

&lt;p&gt;Use the command to run your project on android emulator or physical device.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;yarn android
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This command will open the metro for the project, if you have a expo installed in your physical device, simply scan with your phone camera and viola! Your project will load in your device.&lt;/p&gt;

&lt;p&gt;For ios device, se the command to run your project on android emulator or physical device.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;yarn ios
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This command will open the metro for the project, if you have a expo installed in your physical device, simply scan with your phone camera and viola! Your project will load in your device.&lt;/p&gt;

&lt;p&gt;Okay! Now that we have our project running, let's begin implementing the google maps.&lt;/p&gt;

&lt;p&gt;So to begin, we are going to using just 3 libraries from google npm package. Which are;&lt;/p&gt;

&lt;p&gt;react-native-google-places-autocomplete&lt;br&gt;
react-native-maps-directions&lt;br&gt;
react-native-maps&lt;/p&gt;

&lt;p&gt;so install these packages using yarn or npm&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;yarn add react-native-google-places-autocomplete react-native-maps-directions
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now that we have installed these packages, import the 2 packages into your app.js file as follow&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import {
  StyleSheet,View,Dimensions,Text,TouchableOpacity,
} from "react-native";
import MapView, { Marker, PROVIDER_GOOGLE } from "react-native-maps";
import { GooglePlacesAutocomplete } from "react-native-google-places-autocomplete";
import MapViewDirections from "react-native-maps-directions";
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then are going to create a child component that will contain the GooglePlacesAutocomplete component. Let's the component InputAutoComplete&lt;/p&gt;

&lt;p&gt;Inside this component we are using the GooglePlacesAutocomplete we imported to auto complete places which user type in the input,&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function InputAutoComplete({ label, placeholder, onPlaceSelected }) {
  return (
    &amp;lt;&amp;gt;
      &amp;lt;Text&amp;gt;{label}&amp;lt;/Text&amp;gt;
      &amp;lt;GooglePlacesAutocomplete
        placeholder={placeholder || ""}
        fetchDetails
        onPress={(data, details = null) =&amp;gt; {

          onPlaceSelected(details);
        }}
        query={{
          key: "YOUR API KEY",
          language: "en",
        }}
      /&amp;gt;
    &amp;lt;/&amp;gt;
  );
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The InputAutoComplete component accepts 3 props from the parent and they are label, placeholder, onPlaceSelected.&lt;/p&gt;

&lt;p&gt;Alright!, now let's move over to the parent component and include the child component and also use the MapView import to show the UI for the map.&lt;/p&gt;

&lt;p&gt;We are go to declare some constant which the MapView will require as initial region.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const { width, height } = Dimensions.get("window");
const ASPECT_RATIO = width / height;
const LATITUDE_DELTA = 0.02;
const LONGITUDE_DELTA = LATITUDE_DELTA * ASPECT_RATIO;
const INITIAL_POSITION = {
  latitude: 40.76711,
  longitude: -73.979704,
  latitude_delta: LATITUDE_DELTA,
  longitude_delta: LONGITUDE_DELTA,
};

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;export default function App() {
  const [origin, setOrigin] = useState(null);
  const [destination, setDestination] = useState(null);
  const [showDirection, setShowDirection] = useState(false);
  const mapRef = useRef(null);

  const moveto = async (position) =&amp;gt; {
    const camera = await mapRef.current?.getCamera();
    if (camera) {
      camera.center = position;
      mapRef.current?.animateCamera(camera, { duration: 1000 });
    }
  };

  const edgePaddingValue = 120;

  const edgePadding = {
    top: edgePaddingValue,
    right: edgePaddingValue,
    bottom: edgePaddingValue,
    left: edgePaddingValue,
  };

  const traceRoute = () =&amp;gt; {
    if (origin &amp;amp;&amp;amp; destination) {
      setShowDirection(true);
      mapRef.current?.fitToCoordinates([origin, destination], { edgePadding });
    }
  };
  const onPlaceSelected = (details, flag) =&amp;gt; {
    const set = flag === "origin" ? setOrigin : setDestination;
    const position = {
      latitude: details?.geometry.location.lat || 0,
      longitude: details?.geometry.location.lng || 0,
    };
    set(position);
    moveto(position);
  };
  return (
    &amp;lt;View&amp;gt;
      &amp;lt;MapView
        ref={mapRef}
        provider={PROVIDER_GOOGLE}
        initialRegion={INITIAL_POSITION}
      &amp;gt;
        {origin &amp;amp;&amp;amp; &amp;lt;Marker coordinate={origin} /&amp;gt;}
        {destination &amp;amp;&amp;amp; &amp;lt;Marker coordinate={destination} /&amp;gt;}
        {origin &amp;amp;&amp;amp; destination &amp;amp;&amp;amp; showDirection &amp;amp;&amp;amp; (
          &amp;lt;MapViewDirections
            origin={origin}
            destination={destination}
            apikey={"YOUR API KEY"}
            strokeColor="red"
            strokeWidth={4}
          /&amp;gt;
        )}
      &amp;lt;/MapView&amp;gt;
      &amp;lt;View&amp;gt;
        &amp;lt;InputAutoComplete
          label="Origin"
          onPlaceSelected={(details) =&amp;gt; {
            onPlaceSelected(details, "origin");
          }}
        /&amp;gt;
        &amp;lt;InputAutoComplete
          label="Destination"
          onPlaceSelected={(details) =&amp;gt; {
            onPlaceSelected(details, "destination");
          }}
        /&amp;gt;
        &amp;lt;TouchableOpacity onPress={() =&amp;gt; traceRoute()}&amp;gt;
          &amp;lt;Text&amp;gt;Trace route&amp;lt;/Text&amp;gt;
        &amp;lt;/TouchableOpacity&amp;gt;
      &amp;lt;/View&amp;gt;
    &amp;lt;/View&amp;gt;
  );
}

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So we are wrapping all component with the MapView which takes 3 props.&lt;/p&gt;

&lt;p&gt;In closing we created 2 InputAutoComplete that accepts the origin and destination address,  which sets the input when onPress.&lt;/p&gt;

&lt;p&gt;A Marker is set when the origin or destination position is set using setOrigin and setDestination in the onPlaceSelect function.&lt;/p&gt;

&lt;p&gt;So let's run the project and see the result.&lt;/p&gt;

&lt;p&gt;I hope I'm able to help with this article. Thank you. &lt;/p&gt;

</description>
    </item>
    <item>
      <title>WHY TYPESCRIPT IS BETTER THAN THAN USING JAVASCRIPT.</title>
      <dc:creator>Kingsley onyelo</dc:creator>
      <pubDate>Sat, 24 Jun 2023 01:28:56 +0000</pubDate>
      <link>https://dev.to/kingsoo123/why-typescript-is-better-than-than-using-javascript-205h</link>
      <guid>https://dev.to/kingsoo123/why-typescript-is-better-than-than-using-javascript-205h</guid>
      <description>&lt;p&gt;In this article we will learn why Typescript is better and more efficient to use than Javascript. I am going to highlight 3 main advantage Typescript has over Javascript; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why TypeScript over JavaScript?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Due to its syntax, JavaScript code is not considered an error by TypeScript. This means that you don't need to worry about how the code is written because you can put any working JavaScript code into a TypeScript file.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Is JavaScript quicker than TypeScript?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;TypeScript is more efficient and faster than JavaScript when it comes to execution speed and device scaling. The primary reason it outperforms JavaScript in terms of performance is that it is able to detect errors and bugs at the compilation stage rather than the runtime.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What benefits does the TypeScript function provide?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;TypeScript's primary benefit is type checking. We will be able to identify many of these issues at build time if the language is given static typing. Before the code is shipped, they can be fixed.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>WAYS OF USING TAILWIND CSS IN A REACT NATIVE PROJECT</title>
      <dc:creator>Kingsley onyelo</dc:creator>
      <pubDate>Sat, 24 Jun 2023 01:22:38 +0000</pubDate>
      <link>https://dev.to/kingsoo123/ways-of-using-tailwind-css-in-a-react-native-project-6m3</link>
      <guid>https://dev.to/kingsoo123/ways-of-using-tailwind-css-in-a-react-native-project-6m3</guid>
      <description>&lt;p&gt;This article aims at showing you how to use Tailwind CSS in React Native applications. But first, you need to know what Tailwind CSS is and how it can be helpful in developing good user interfaces.&lt;/p&gt;

&lt;p&gt;What is Tailwind CSS?&lt;br&gt;
A utility-first CSS framework composed of classes that can be put together to build user interface, directly in your HTML file. The best part of this framework is it doesn't impose any design guidelines to follow , which means you're not restricted for creating any design of your choice.&lt;/p&gt;

&lt;p&gt;It is highly efficient and portable in size, Tailwind removes all unused CSS when building for production, it ships the smallest CSS bundle possible.&lt;/p&gt;

&lt;p&gt;Now that we grasped what Tailwind is, let dive in to see how we define classes in our React App using JSX.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;html
&amp;lt;button className="bg-blue-500 hover:bg-blue-700 
    text-white font-bold py-[5rem] px-4 rounded ml-4 mt-4"&amp;gt;
  Button
&amp;lt;/button&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Moving on, how can we use Tailwind CSS in React Native application?&lt;/p&gt;

&lt;p&gt;NativeWind&lt;br&gt;
It is a package that uses Tailwind CSS as scripting language to create a universal style system for React Native. NativeWind components can be shared between platforms and will output their styles as CSS Stylesheet on web and Stylesheet for native.&lt;/p&gt;

&lt;p&gt;React Native's Stylesheet system only provides static styles, with other features left for the user to implement. By using NativeWind you can focus on writing your system instead of building your own custom style system.&lt;/p&gt;

&lt;p&gt;Getting started&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Project setup&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;To set up our project, we'll scaffold a new react Native app using react-native init. If you have already done this, skip this process, otherwise, run the command below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;js
npx react-native init my-nativewind-app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Cd into the project's directory.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;js
cd my-nativewind-app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Install NativeWind&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Install nativewind and it's peer dependency tailwindcss, using yarn or npm, but in this example I'll be using yarn instead.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;js
yarn add nativewind
yarn add --dev tailwindcss
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Set up Tailwind&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Setup Tailwind CSS, run the command npx tailwindcss init to create a tailwind.config.js file&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;js
  // tailwind.config.js

  module.exports = {
  - content: [],
  + content: ["./App.{js,jsx,ts,tsx}", "./src/**/*.{js,jsx,ts,tsx}"],
    theme: {
      extend: {},
    },
    plugins: [],
  };

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Add Babel plugin&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Add the Babel plugin, modify your babel.config.js.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;js
  // babel.config.js
  module.exports = {
  - plugins: [],
  + plugins: ["nativewind/babel"],
  };

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And that does it! Hurray you have Tailwind css working in your react native project.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;js
  import { StatusBar } from 'expo-status-bar';
  import React from 'react';
  import { Text, View } from 'react-native';

  export default function App() {
    return (
    &amp;lt;View className="flex-1 items-center justify-center bg-white"&amp;gt;
        &amp;lt;Text className="text-gray-400 text-md font-bold mt-2"&amp;gt;
            Open up App.js to start working on your app!
        &amp;lt;/Text&amp;gt;
        &amp;lt;StatusBar style="auto" /&amp;gt;
      &amp;lt;/View&amp;gt;
    );
  }

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Thank you for taking the time read...&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
