build changes

This commit is contained in:
Belen Curcio
2020-10-02 12:59:50 -03:00
parent c5e5cbaa68
commit f536dab1a2
13 changed files with 63 additions and 97 deletions

View File

@@ -3,6 +3,7 @@ import {
Connector,
useCommerce as useCoreCommerce,
} from 'lib/commerce'
import { ReactNode } from 'react'
async function getText(res: Response) {
try {
@@ -35,8 +36,12 @@ export const bigcommerce: Connector = {
fetcher,
}
interface Props {
children?: ReactNode | any
}
// TODO: The connector should be extendable when a developer is using it
export function CommerceProvider({ children }) {
export function CommerceProvider({ children }: Props) {
return (
<CoreCommerceProvider connector={bigcommerce}>
{children}