From 314c84e2ced101e04594ff41ae41651530970781 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ABl=20Brunet?= Date: Mon, 17 May 2021 22:59:39 +0200 Subject: [PATCH] Setup netlify cms --- README.md | 2 +- src/admin/config.yml | 19 +++++++++++++++++++ src/admin/index.html | 15 +++++++++++++++ 3 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 src/admin/config.yml create mode 100644 src/admin/index.html diff --git a/README.md b/README.md index f8d029b..1a47f9f 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ My Online Cookbook is a starter kit to create your own website of recipes, using [Eleventy](https://11ty.io) and [Netlify CMS](https://www.netlifycms.org/). It is meant to be both highly accessible (including to non-developers), as well as fully customisable should you want to use it as a starting off point. -Demo (this is what you get out of the box) : [myonlinecookbook.netlify.app](myonlinecookbook.netlify.app) +Demo (this is what you get out of the box) : [https://myonlinecookbook.netlify.app/](https://myonlinecookbook.netlify.app/) ## Features diff --git a/src/admin/config.yml b/src/admin/config.yml new file mode 100644 index 0000000..9b462eb --- /dev/null +++ b/src/admin/config.yml @@ -0,0 +1,19 @@ +backend: + name: git-gateway + branch: main +media_folder: "src/recipe-images" +public_folder: "/recipe-images" + +collections: + - name: "recipes" + label: "Recipes" + folder: "src/recipes" + create: true + fields: + - {label: "Title", name: "title", widget: "string"} + - {label: "Tags", name: "tags", widget: "list"} + - {label: "Preparation time", name: "time", widget: "string"} + - {label: "Number of servings", name: "servings", widget: "number"} + - {label: "Source of the recipe", name: "sourceLabel", widget: "string"} + - {label: "URL of the source of the recipe", name: "sourceURL", widget: "string"} + - {label: "Ingredients", name: "ingredients", widget: "list"} \ No newline at end of file diff --git a/src/admin/index.html b/src/admin/index.html new file mode 100644 index 0000000..be4da52 --- /dev/null +++ b/src/admin/index.html @@ -0,0 +1,15 @@ + + + + + + Content Manager + + + + + + + + + \ No newline at end of file