Move API to new Node architecture

Signed-off-by: Loan Laux <loan@outgrow.io>
This commit is contained in:
Loan Laux
2021-07-06 15:43:38 +03:00
parent 8dc6881cd9
commit 23e0d57cf5
32 changed files with 459 additions and 141 deletions

View File

@@ -0,0 +1,23 @@
import { OperationContext } from '@commerce/api/operations'
import { Provider, VendureConfig } from '../'
export default function getCustomerWishlistOperation({
commerce,
}: OperationContext<Provider>) {
async function getCustomerWishlist({
config: cfg,
variables,
includeProducts,
}: {
url?: string
variables: any
config?: Partial<VendureConfig>
includeProducts?: boolean
}): Promise<any> {
// Not implemented as Vendure does not ship with wishlist functionality at present
const config = commerce.getConfig(cfg)
return { wishlist: {} }
}
return getCustomerWishlist
}