more detail on index; move delete to recipe page
This commit is contained in:
parent
27ac9cd92d
commit
91439cbcfa
9 changed files with 95 additions and 75 deletions
|
@ -23,6 +23,9 @@ export const getRecipeIngredients = async () => {
|
|||
export const getRecipeById = async (id) => {
|
||||
const response = await fetch(`${baseUrl}backend/recipe/${id}`);
|
||||
const data = await response.json();
|
||||
if (!data || !data.details) {
|
||||
return { details: null };
|
||||
}
|
||||
return data;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue