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

update(examples): Update with-sentry example #47855

Merged
merged 18 commits into from
Jun 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 8 additions & 3 deletions examples/with-sentry-simple/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,18 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
# Sentry
.sentryclirc

# Sentry
next.config.original.js
sentry.properties

11 changes: 8 additions & 3 deletions examples/with-sentry/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,18 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
# Sentry
.sentryclirc

# Sentry
next.config.original.js
sentry.properties

2 changes: 1 addition & 1 deletion examples/with-sentry/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Preview the example live on [StackBlitz](http://stackblitz.com/):

## Deploy your own

It only takes a few steps to create and deploy your own version of this example app. Before you begin, make sure you have [linked your Vercel account to GitHub](https://vercel.com/docs/personal-accounts/login-connections), and [set up a project in Sentry](https://docs.sentry.io/product/sentry-basics/guides/integrate-frontend/create-new-project/).
It only takes a few steps to create and deploy your own version of this example app. Before you begin, make sure you have [linked your Vercel account to GitHub](https://vercel.com/docs/teams-and-accounts#existing-login-connection), and [set up a project in Sentry](https://docs.sentry.io/product/sentry-basics/guides/integrate-frontend/create-new-project/).

### Option 1: Deploy directly to Vercel

Expand Down
5 changes: 5 additions & 0 deletions examples/with-sentry/next-env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
1 change: 1 addition & 0 deletions examples/with-sentry/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ const { withSentryConfig } = require('@sentry/nextjs')

const moduleExports = {
// Your existing module.exports
reactStrictMode: true,

sentry: {
// Use `hidden-source-map` rather than `source-map` as the Webpack `devtool`
Expand Down
10 changes: 8 additions & 2 deletions examples/with-sentry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,18 @@
"scripts": {
"dev": "next",
"build": "next build",
"start": "next start"
"start": "next start",
"lint": "next lint"
},
"dependencies": {
"@sentry/nextjs": "^7.30.0",
"@sentry/nextjs": "^7.46.0",
"next": "latest",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"@types/node": "^18.15.11",
"@types/react": "^18.0.32",
"typescript": "^4.8.2"
}
}
4 changes: 0 additions & 4 deletions examples/with-sentry/pages/_app.js

This file was deleted.

5 changes: 5 additions & 0 deletions examples/with-sentry/pages/_app.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import '../styles/globals.css'

export default function App({ Component, pageProps }) {
return <Component {...pageProps} />
}
13 changes: 13 additions & 0 deletions examples/with-sentry/pages/_document.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { Html, Head, Main, NextScript } from 'next/document'

export default function Document() {
return (
<Html lang="en">
<Head />
<body>
<Main />
<NextScript />
</body>
</Html>
)
}
163 changes: 0 additions & 163 deletions examples/with-sentry/pages/index.js

This file was deleted.