- 📖 About the Project
- 🛠 Built With
- 💻 Getting Started
- 👥 Authors
- 🔭 Future Features
- 🤝 Contributing
- ⭐️ Show your support
- 🙏 Acknowledgements
- 📝 License
This is a simple Rails and React application that displays a random greeting message using redux-toolkit and react-router.
Programming Language
- Ruby 3.2.2
- JavaScript
Web Application Framework
- Rails 7.1.3
Database
- PostgreSQL (pg gem)
Web Server
- Puma
JavaScript Modules
- Webpack (jsbundling-rails gem, webpack and webpack-cli in package.json)
UI Library
- React (react and react-dom in package.json)
Hotwire
- Turbo (turbo-rails gem, @hotwired/turbo-rails in package.json)
- Stimulus (@hotwired/stimulus in package.json)
APIs
- Jbuilder
Performance Optimization
- Bootsnap
Testing
- Debug
- Capybara
- Selenium Webdriver
Development Tools
- Web Console (web-console gem)
- Babel (@babel/core, @babel/preset-env, @babel/preset-react, babel-loader in package.json)
- Random Greeting: Displays a random greeting message from a selection of 5 different greetings stored in the database.
- React Components: Uses React to create dynamic UI components.
- API Endpoint: Includes an API endpoint that selects a random greeting from the database.
- Redux Store: A store, an action, and a reducer are created that connect to the API endpoint to get the random greeting.
To get started with the project, follow the steps below.
To run this project, ensure you have the following installed:
Clone the repository to your local machine:
git clone https://github.com/fmanimashaun/hello-rails-react.git
cd hello-rails-react
bundle install
yarn install
This application uses PostgreSQL as the database. Here are the steps to set it up:
-
Ensure PostgreSQL is installed on your machine and running.
-
Update the config/database.yml file with your PostgreSQL username and password in the default section.
-
Create the database:
rails db:create
- Run migrations to set up the database schema:
rails db:migrate
- Load sample data into database:
rails db:seed
To run the program, you can use a Ruby interpreter. For example, to interact with the code, use the following:
- Start the server
bin/dev
- Access the Blog app in your web browser at
http://localhost:3000
.
👤 Fisayo Michael Animashaun
- GitHub: @fmanimashaun
- Twitter: @fmanimashaun
- LinkedIn: Fisayo Michael Animashaun
- Add more functionality...
Contributions, issues, and feature requests are welcome!
Feel free to check the issues page.
If you like this project leave a start for it.
- I'd like to thank Microverse for helping us in the journey to become a Fullstack developer.
This project is MIT licensed.