diff --git a/client/src/pages/products/index.tsx b/client/src/pages/products/index.tsx index 0ae101a..952abde 100644 --- a/client/src/pages/products/index.tsx +++ b/client/src/pages/products/index.tsx @@ -1,12 +1,13 @@ import { Component, For, Show, createResource } from "solid-js"; import Cards from "../../components/cards/Cards"; -const fetchData = async () => { - const res = await fetch("https://cptdb.koompi.com/CoreProducts"); - return res.json(); -}; const Products: Component<{}> = () => { - const [AllCoreProducts] = createResource(fetchData); + const fetchData = async () => { + const res = await fetch("https://cptdb.koompi.com/CoreProducts"); + return res.json(); + }; + + const [allProducts] = createResource(fetchData); return (
@@ -686,8 +687,8 @@ const Products: Component<{}> = () => {
- Loading...

}> - + Loading...

}> + {(CoreProducts) => { return ; }}