Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add e-commerce test page to nextjs playground #1725

Merged
merged 3 commits into from
Feb 10, 2025

Conversation

robbie-c
Copy link
Member

@robbie-c robbie-c commented Feb 10, 2025

Changes

I wanted to add a page to test out these specific events manually, may as well commit it

Checklist

  • Tests for new code (see advice on the tests we use)
  • Accounted for the impact of any changes across different browsers
  • Accounted for backwards compatibility of any changes (no breaking changes in posthog-js!)

Copy link

vercel bot commented Feb 10, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
posthog-js ✅ Ready (Inspect) Visit Preview Feb 10, 2025 1:56pm

@robbie-c robbie-c requested a review from MarconLP February 10, 2025 13:09
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Summary

Added a new e-commerce test page to the Next.js playground that enables manual testing of various e-commerce events like product additions, searches, wishlists, and order completions.

  • Component in /playground/nextjs/pages/ecommerce.tsx has mismatched name SurveyForm despite handling e-commerce functionality
  • Added Reddit domains (*.redditstatic.com, *.reddit.com) to CSP directives in /playground/nextjs/pages/_app.tsx without clear justification
  • Added __preview_experimental_cookieless_mode: false configuration in /playground/nextjs/src/posthog.ts
  • Implemented standardized e-commerce event properties following a consistent pattern for product data structure

4 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

@robbie-c robbie-c changed the title Add e-commerce test page to nextjs playground feat: Add e-commerce test page to nextjs playground Feb 10, 2025
Copy link

github-actions bot commented Feb 10, 2025

Size Change: 0 B

Total Size: 3.3 MB

ℹ️ View Unchanged
Filename Size
dist/all-external-dependencies.js 215 kB
dist/array.full.es5.js 267 kB
dist/array.full.js 370 kB
dist/array.full.no-external.js 369 kB
dist/array.js 183 kB
dist/array.no-external.js 181 kB
dist/customizations.full.js 13.8 kB
dist/dead-clicks-autocapture.js 14.5 kB
dist/exception-autocapture.js 9.48 kB
dist/external-scripts-loader.js 2.64 kB
dist/main.js 183 kB
dist/module.full.js 370 kB
dist/module.full.no-external.js 369 kB
dist/module.js 183 kB
dist/module.no-external.js 181 kB
dist/recorder-v2.js 115 kB
dist/recorder.js 115 kB
dist/surveys-preview.js 69.4 kB
dist/surveys.js 72.4 kB
dist/tracing-headers.js 1.76 kB
dist/web-vitals.js 10.4 kB

compressed-size-action

@@ -25,6 +25,7 @@ export const PageHeader = () => {
<Link href="/replay-examples/canvas">Canvas</Link>
<Link href="/replay-examples/media">Media</Link>
<Link href="/replay-examples/long">Long</Link>
<Link href="/EcommerceTester">E-commerce</Link>
Copy link
Member

@rafaeelaudibert rafaeelaudibert Feb 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursed capitalization of ecommerce ☠️

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah I think my IDE did this when I renamed the react component, yeah agreed that this is cursed

@robbie-c robbie-c merged commit 9401d2d into main Feb 10, 2025
25 checks passed
@robbie-c robbie-c deleted the feat/add-ecommerce-test-page branch February 10, 2025 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants