From 56f2137f5ec434abf32155dff8b77e70ebcbf745 Mon Sep 17 00:00:00 2001 From: Don Morrison Date: Wed, 16 Mar 2022 19:58:02 -0700 Subject: [PATCH 1/2] fix(examples/with-segment-analytics): Update README Update the README for `examples/with-segment-analytics`: - Update reference from `_document.js` (removed in https://github.com/vercel/next.js/commit/92d87870af07c453a3a105c26f17914e081ba1f2) to `_app.js`. - Update reference links - Make small language tweaks --- examples/with-segment-analytics/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/with-segment-analytics/README.md b/examples/with-segment-analytics/README.md index 481f3981474ce..fba705378bb0d 100644 --- a/examples/with-segment-analytics/README.md +++ b/examples/with-segment-analytics/README.md @@ -1,6 +1,6 @@ # Example app with analytics -This example shows how to use Next.js along with [Segment Analytics](https://segment.com). A custom document is used in inject the [Segment snippet](https://github.com/segmentio/snippet) into the ``. Page views are tracked on both the server and client side and components fire ["track"](https://segment.com/docs/spec/track/) events based on user actions (see `contact.js` for example). +This example shows how to use [Next.js](https://github.com/vercel/next.js) along with [Segment Analytics](https://segment.com). A custom [\app](https://nextjs.org/docs/advanced-features/custom-app) is used to inject the [Segment Analytics.js snippet](https://github.com/segmentio/snippet). The server and client-side call the [Page API](https://segment.com/docs/connections/spec/page/), while components call the [Track API](https://segment.com/docs/connections/spec/track/) on user actions (Refer to [`contact.js`](https://github.com/vercel/next.js/blob/canary/examples/with-segment-analytics/pages/contact.js)). ## Deploy your own From e28c4fd5d9c8bd2bfb9d5296c6010b743198f8ac Mon Sep 17 00:00:00 2001 From: JJ Kasper Date: Sat, 21 May 2022 23:17:26 -0500 Subject: [PATCH 2/2] Apply suggestions from code review --- examples/with-segment-analytics/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/with-segment-analytics/README.md b/examples/with-segment-analytics/README.md index fba705378bb0d..535eeeb6f8b9b 100644 --- a/examples/with-segment-analytics/README.md +++ b/examples/with-segment-analytics/README.md @@ -1,6 +1,6 @@ # Example app with analytics -This example shows how to use [Next.js](https://github.com/vercel/next.js) along with [Segment Analytics](https://segment.com). A custom [\app](https://nextjs.org/docs/advanced-features/custom-app) is used to inject the [Segment Analytics.js snippet](https://github.com/segmentio/snippet). The server and client-side call the [Page API](https://segment.com/docs/connections/spec/page/), while components call the [Track API](https://segment.com/docs/connections/spec/track/) on user actions (Refer to [`contact.js`](https://github.com/vercel/next.js/blob/canary/examples/with-segment-analytics/pages/contact.js)). +This example shows how to use Next.js along with [Segment Analytics](https://segment.com). A [custom app](https://nextjs.org/docs/advanced-features/custom-app) is used to inject the [Segment Analytics.js snippet](https://github.com/segmentio/snippet). The server and client-side call the [Page API](https://segment.com/docs/connections/spec/page/), while components call the [Track API](https://segment.com/docs/connections/spec/track/) on user actions (Refer to [`contact.js`](https://github.com/vercel/next.js/blob/canary/examples/with-segment-analytics/pages/contact.js)). ## Deploy your own