From b75a30720f3f31c6684d35a6182586486ae1541f Mon Sep 17 00:00:00 2001 From: nelsonic Date: Wed, 20 Sep 2023 10:59:40 +0100 Subject: [PATCH] #2 add outline of plan for the repo ref: https://github.com/dwyl/fields-demo/issues/2#issuecomment-1722699757 --- README.md | 59 +++++++++++++++++-- .../controllers/page_html/home.html.heex | 34 +++++++++++ 2 files changed, 88 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index dfdeff2..98155cf 100644 --- a/README.md +++ b/README.md @@ -29,9 +29,39 @@ both `@dwyl` and the wider `Elixir` community. # How? +Run the demo on your computer! +## 1. Clone from `GitHub` -## Build Log +Clone the project from `GitHub`: + +```sh +git clone git@github.com:dwyl/fields-demo.git +``` + +## 2. Setup Dependencies & Database + +Setup the project on `localhost`: + +```sh +mix setup +``` + +## 3. Run the App + +Run the app: + +```sh +mix s +``` + +Open the app in your browser, +you should expect to see: + +# TODO: add GIF of inputting data. + + +# Build Log This is a comprehensive step-by-step log of everything we did when creating this demo app. @@ -41,7 +71,7 @@ please [open an issue](https://github.com/dwyl/fields-demo/issues) -### 1. Create a New Phoenix App +## 1. Create a New Phoenix App Create a New Phoenix App: @@ -52,7 +82,7 @@ mix phx.new fields_demo --no-mailer --no-dashboard --no-gettext > **Note**: We don't need to send email, have a fancy dashboard or translation. -### 2. Setup Coverage +## 2. Setup Coverage So we know which files are covered by tests, we setup coverage following the steps outlined in: @@ -105,7 +135,7 @@ But most of the untested code is in: `lib/fields_demo_web/components/core_components.ex` which we aren't going to _use_ in this project ... -#### 2.1 Ignore Unused "System" Files +### 2.1 Ignore Unused "System" Files Create a file with called `coveralls.json` and add the following contents: @@ -159,7 +189,7 @@ COV FILE LINES RELEVANT MISSED Now we can move on! -## 3. Run the Phoenix App! +# 3. Run the Phoenix App! Before we start adding features, let's run the default `Phoenix` App. @@ -183,6 +213,25 @@ you should see something similar to the following: That completes 2 minutes of "setup". Let's add a schema! +
+ +# Register for _Awesome_ Conf! + +awesome smiley + +
+ +In this demo App +we're going to create +a registration form +for our fictitious +**_Awesome_ Conference**. + + + + + + # FieldsDemo To start your Phoenix server: diff --git a/lib/fields_demo_web/controllers/page_html/home.html.heex b/lib/fields_demo_web/controllers/page_html/home.html.heex index e9fc48d..b86450d 100644 --- a/lib/fields_demo_web/controllers/page_html/home.html.heex +++ b/lib/fields_demo_web/controllers/page_html/home.html.heex @@ -1,4 +1,38 @@ <.flash_group flash={@flash} /> + +
+ Plan +
+
+
+ +
+
+ +

Inclui lanche saudável | Includes healthy snacks

+
+
+
+
+ +
+
+ +

Inclui lanche saudável | Includes healthy snacks

+
+
+
+
+ +
+
+ +

Inclui almoço e lanche saudável | Includes lunch and healthy snacks

+
+
+
+
+