Wok To Walk Iceland



Overview
Wok To Walk Iceland is the customer-facing ordering and marketing website for the Icelandic franchise of Wok To Walk, the international wok-to-order chain. The site lets visitors browse the menu, build their own wok from base, protein, vegetables, and sauce, check the nutritional breakdown of every combination, and place an order for pickup or delivery — all in Icelandic or English.
As with every VISKA customer site, this is a marketing/ordering shell: Prismic manages all marketing content and the menu, while the product catalog, pricing, cart, and checkout are driven by the shared Upsell platform via @upsell/kit and the public-api.upsell.is/v2 API. There is no local database — Prismic is the content source and SWR handles client-side data fetching.
Tech Stack & Rationale
Layer | Technology | Why |
|---|---|---|
Framework | Next.js 14 (App Router), React 18 | Server-first rendering with locale-based route groups ((main), (clean), (prismic)) |
Language | TypeScript | Strict typing across slices, kit types, and API responses |
Styling | Tailwind CSS 3.4 | Rapid, consistent brand styling without custom CSS files |
CMS | Prismic + Slice Machine | Content editors manage pages, layout, and slices without code changes |
Client data fetching | SWR 2.2 | Revalidation, focus sync, and caching for cart/checkout/client state |
Business logic | @upsell/kit + public-api.upsell.is/v2 (Axios) | Shared cart, checkout, and Apple Pay logic with a MobileApp-authenticated store ID |
i18n | LinguiJS (is, en) + Crowdin | Compile-time message catalogs, Icelandic-first locale redirect |
Maps | Mapbox GL + react-map-gl | "Take me there" store locator |
Animation | GSAP, Swiper, Lottie | Hero motion and carousels |
Forms & email | @react-email + SendGrid | Career and company-account form submissions |
Monitoring | Sentry | Error tracking in production |
Hosting | Cloudflare Workers via OpenNext (migrated from Vercel) | Edge deployment of the Next.js standalone build |
Architecture
A request flows from the locale middleware through server-rendered pages, then hands off to SWR-backed client components that talk to the Upsell API. Prismic content is fetched server-side with tag-based caching and preview support.
The flow runs: Browser request (/is/menu) → middleware.ts (locale redirect → is) → Server Components (RSC + generateMetadata) → SWR hooks (client revalidation) → public-api (upsell.is/v2) → Cloudflare (Workers edge); Browser request (/is/menu) → middleware.ts (locale redirect → is) → Prismic client (tag cache + preview) → @upsell/kit (cart · checkout).
- Locale routing — middleware.ts reads the request pathname and, when no locale prefix is present, redirects to /is/... (Icelandic default). API and well-known paths are exempt.
- Server rendering — (main) pages are React Server Components that fetch Prismic pages documents (with their linked layouts document) through a tag-cached client, then render the slice zone.
- Client interactivity — interactive features (cart, customizer, checkout) hydrate into client components that read the product catalog through @upsell/kit, with SWR managing revalidation and optimistic cart state.
- Checkout — the (clean) route group renders checkout steps (shipping, summary, verification) without the site chrome; payment goes through the Upsell API with Apple Pay support via the useApplePay hook and OTP verification via react18-input-otp.
- Edge serving — the standalone Next.js build is deployed to Cloudflare Workers through OpenNext, with next/image in unoptimized mode and Sentry wired in production.
Folder Structure
customers/wok-to-walk-web/
├── app/
│ ├── [locale]/
│ │ ├── (main)/ # public pages with navbar + footer
│ │ │ ├── (customization)/ # build-your-own-wok: products/[productID], deals/[dealID]
│ │ │ ├── nutrition-calculator/# per-ingredient nutrition totals
│ │ │ ├── store/ # store locator (Mapbox)
│ │ │ └── profile/ # orders, edit profile
│ │ ├── (clean)/checkout/ # shipping · summary · verification
│ │ ├── (plain)/ # login, checkout/success
│ │ └── (prismic)/[[...slug]]/ # CMS-driven pages + slice-simulator
│ ├── api/ # preview, exit-preview, revalidate
│ └── sitemap.ts · robots.ts · manifest.ts
├── components/ # auth, cart, calculator, checkout, menu, product, store…
├── slices/ # 18 slices (Hero, Menu, CustomWok, PopularWok, …)
├── customtypes/ # pages, layouts, top_banner, nutrition_information
├── constants/ # products, order, shipping, franchises
├── lib/ # prismic.ts, api.ts, generateMetaData.ts, hooks/
├── locales/translations/ # en.po, is.po (Crowdin)
├── middleware.ts · appRouterI18n.ts · prismicio.ts
└── next.config.js · tailwind.config.ts · wrangler.tomlContent Model
Prismic is the single content source. Four custom types drive the site:
Custom type | Kind | Purpose |
|---|---|---|
pages | Repeatable | Marketing pages — uid, page_title, a layout link, a slice zone, and SEO metadata (meta_title, meta_description, meta_image) |
layouts | Repeatable | Site chrome composed of navbar, children, and footer slices; linked from each pages document |
top_banner | Singleton | An optional promo bar (paragraph, cta_text, cta_url, active) surfaced by the useTopBanner hook |
nutrition_information | Repeatable | Nutrition records — an ingredients Group with per-item macros (calories, carbs, protein, fats, serving_size) and dietary flags (vegan, gluten_free, dairy_free, soy_free, wheat_free), fetched by UID for the calculator |
The pages slice zone exposes 14 slices, notably custom_wok (build-your-own-wok builder), popular_wok, menu, nutrition-adjacent description_grid, take_me_there (Mapbox locator), gallery, and form slices (career_form, company_account_form, contact).
Impact & Results
- In production for the Wok To Walk franchise in Iceland (pickup/delivery ordering, Icelandic and English).
- One of 16+ customer sites served by the shared VISKA monorepo platform.
My Contributions
Worked on the Wok To Walk site as part of the VISKA monorepo team:
- Migrated the deployment from Vercel to Cloudflare Workers via OpenNext.
- Built the build-your-own-wok customizer and the nutrition calculator experience against the nutrition_information content type.
- Refactored the pricing section to the granular pricing structure and migrated it to the usePriceSummaryV2 pricing API.
- Improved Icelandic translations across the storefront and checkout.
- Fixed the Apple Pay loading screen, the shipping-page crash, and the empty-cart redirect on checkout summary pages.
- Added the Wok To Walk "Darts" QR flow and updated the ordering hostname to skor.woktokwalk.is.
References
[1] Wok To Walk Iceland, "Wok To Walk — Iceland," woktowalk.is, 2024. [Online]. Available: https://woktowalk.is/is/
[2] Vercel, "Next.js Documentation," nextjs.org. [Online]. Available: https://nextjs.org/docs
[3] Prismic, "Prismic Documentation," prismic.io. [Online]. Available: https://prismic.io/docs
[4] Vercel, "SWR — React Hooks for Data Fetching," swr.vercel.app. [Online]. Available: https://swr.vercel.app
[5] LinguiJS, "LinguiJS — Internationalization," lingui.dev. [Online]. Available: https://lingui.dev
Comments
Leave a Comment
You must be signed in to comment
0 Comments
No comments yet. Be the first to comment!