Skip to content

Commit

Permalink
Merge branch 'main' into dynamo-simulation
Browse files Browse the repository at this point in the history
  • Loading branch information
Chriscbr authored Aug 16, 2023
2 parents 42a638f + 558fa3b commit 753f913
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 6 deletions.
39 changes: 34 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,45 @@
An application that allows users to choose between different options and vote for their favorite one. Items that get more votes will get ranked higher.
The idea is to make something like https://eloeverything.co/.
# Battle of the Bites!

***Get ready to indulge your taste buds and crown the ultimate culinary champion in Battle of the Bites!*** 🍔🍕🍣
Swipe, vote, and savor the showdown as iconic dishes from around the world go head-to-head in a gastronomic clash like no other.
Will pizza outflavor sushi?
Can burgers grill their way to victory over tacos?
Join the epic feast and help your favorite bites seize their rightful spot on the podium of delicious dominance.
Welcome to the ultimate flavor face-off!

Check out the app's demo at https://d150bm8l5c4qqp.cloudfront.net/.

![Battle of the Bites screenshot](screenshot.png)

Inspired by https://eloeverything.co/.

## Development

To test the website, you must first deploy an instance of the application through `wing compile -t tf-aws main.w`, and then deploy the artifacts in `target/main.tfaws` using `terraform init` and `terraform apply`.
> **Note**
> This project can't be tested using the Wing simulator yet.
After, login to AWS to get the API Gateway URL, and add a `config.json` file to `website/public` that contains the following:
### Deployment

To deploy your own copy of the app, first make sure you have AWS credentials configured in your terminal for the account and region you want to deploy to.
Then:
1. Clone this git repository.
2. Compile the project to AWS (with Terraform) using `wing compile -t tf-aws main.w`.
3. Run `cd target/main.tfaws` to find your deployment artifacts.
4. Run `terraform init` and `terraform apply`.

### Website

1. Clone this git repository.
2. Run `cd website`.
3. Run `npm install`.
4. Create a file at `website/public/config.json` that contains the following:

```json
{
"apiUrl": "<API GATEWAY URL>",
}
```

Finally you can `cd` into `website` and run `npm run start` to start the development server.
Replace <API GATEWAY URL> with the URL of the API Gateway that was created when you deployed the app.

5. Run `npm run start` from `website` to start the development server. Any changes you make to the website will be automatically reflected in the browser.
Binary file added screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion website/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function App() {
<div className="App absolute inset-0">
<div className="w-full h-full flex flex-col items-center justify-center">
<h1 className="title text-7xl pb-7 font-medium">
Battle of the Bites!
🌮 Battle of the Bites! 🍪
</h1>
<div className="text-2xl w-[30rem] min-h-[35rem] px-8 pt-8 pb-4 bg-sky-200 rounded-lg shadow-xl flex flex-col">
<div className="text-slate-700 text-4xl text-center">
Expand Down

0 comments on commit 753f913

Please sign in to comment.