@octanest/commerce-next
v0.1.3
Published
Next.js storefront kit: the Octanest storefront runtime with Next's request cache, cache tags, Metadata, redirects and route handlers
Readme
@octanest/commerce-next
Next.js (App Router) kit for Octanest storefronts: renders the merchant's console-built pages on the server, wires cart, checkout handoff and shopper sign-in, and provides SEO metadata, sitemap/robots and analytics.
npx create-octanest-store my-store # recommended: everything below, pre-wired// app/[[...path]]/page.tsx
import { resolveStorefrontCached, StorefrontPage, storefrontMetadata } from "@octanest/commerce-next";
// app/api/checkout-handoff/route.ts
export { handleCheckoutHandoff as POST } from "@octanest/commerce-next/routes";Route handlers: handleCheckoutHandoff, handleOrders, handleEvents, handleOAuthStart,
handleOAuthCallback, handleOAuthToken, handleSitemap, handleRobots, previewMiddleware.
Pass your own JSX as <StorefrontPage> children to hand-code a page inside the store's header,
footer and theme. Pass origin (your public address) and product, breadcrumb and store pages
carry schema.org data for search engines; storefrontJsonLd gives the same data for your own pages.
Docs: https://docs.octanest.com/developers
License
Apache-2.0 — see LICENSE.
