This is a React Native application that renders three squares, each with a message in the center and a custom background color.
The app utilizes a component called Square
that accepts two properties:
message
: A string representing the message displayed in the center of the square.color
: A string that sets the background color of the square.
Before getting started, you should have the React Native development environment set up on your machine. You can follow the official React Native environment setup guide to do this.
-
Clone this repository to your local machine:
git clone https://github.com/SauloCav/Squares-With-Messages-React-Native/tree/main
-
Install the dependencies using npm or yarn:
With npm:
npm install
With yarn:
yarn install
After installing the dependencies, you can start the application on an emulator or real device. Make sure your emulator is running or your device is connected via USB.
Command to start the application:
npx react-native run-android # For Android
# or
npx react-native run-ios # For iOS (macOS environment only)
This will start the application on your emulator or device. You will see three squares with custom messages and colors on the screen.
If you'd like to contribute to this project, feel free to create a pull request. I'll be happy to review and incorporate improvements.
This project is licensed under the MIT License.