-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
feat(js): Add Documentation for Sentry Astro SDK #8267
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Hey @Lms24 - Is there a date you'd like to get this out by? It might take me a bit longer to review it since it's a bigger PR and this week is a bit busier than usual! |
Hi @shanamatthews ideally until the beginning of next week. I'm currently working on the getting started pages in |
Sounds good, thanks @Lms24 ! I'm going to start on this today and hopefully finish up by tomorrow. Good to know that the SDK is still in alpha! |
src/platform-includes/getting-started-primer/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/getting-started-primer/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/getting-started-primer/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/getting-started-install/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/getting-started-config/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/session-replay/install/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/session-replay/install/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/session-replay/install/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/session-replay/setup/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
src/platform-includes/session-replay/setup/javascript.astro.mdx
Outdated
Show resolved
Hide resolved
Co-authored-by: Shana Matthews <shana.l.matthews@gmail.com>
@@ -38,7 +38,7 @@ export function OrgAuthTokenNote() { | |||
<ExternalLink href={`https://sentry.io/auth/login/?next=${url}`}> | |||
sign in | |||
</ExternalLink>{' '} | |||
to create a token directly from the docs. | |||
to create a token directly from this page. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good change
integrations: [new BrowserTracing()], | ||
tracePropagationTargets: [ | ||
"https://myproject.org", | ||
"https://.*.otherservice.org/.*", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
h: Do we actually support globbing here? I thought we only do regexp.match() or naive string.contains().
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm probably not the best example, let me come up with a better one (copy 🍝 so maybe also relevant for other pages)
scratch that, I see the problem now 😅.*
is valid regex syntax though 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed this for Astro in 7d18a09 but we have the same invalid string in a bunch of places. Will open a separate PR to fix there. Also asked mobile folks because the same string is used in flutter and apple docs.
We recommend installing the SDK by using the `astro` CLI: | ||
|
||
```bash | ||
npx astro add @sentry/astro | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
l: Wondering, is there a chance that astro will change some API and this will break? If so, will it make sense to build and recommend a wizard of some sort that will work independently of the astro CLI? (no action required right now, just sharing my thoughts)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Afaict, this is pretty stable for now (but the current approach has its limitations). We should keep an eye open for if they change things (I need to finally write up that RFC for Astro I've mentioned some time ago).
We could build a wizard because right now, folks still need to manually add their DSN, source maps config, etc. Ideally, the Astro CLI would invoke it for us, so we could retain the "Astro native" approach. But I guess that's just wishful thinking at this point 😅
|
||
### Working With Old Authentication Tokens | ||
|
||
Source maps work best with [organization-scoped auth tokens](/product/accounts/auth-tokens/#organization-auth-tokens). If you are using a different type of Sentry auth token, you'll need to additionally specify your `org` slug in your `sourceMapsUploadOptions`: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would add here when people might want to follow this step, ie. when they're on an old self-hosted version that doesn't have org auth tokens.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pre-merge checklist
If you work at Sentry, you're able to merge your own PR without review, but please don't unless there's a good reason.
Description of changes
This PR adds SDK docs for the new Sentry Astro SDK. It's still in Alpha which we clearly point out in the new docs.
This PR includes adjustments for Astro in the following pages:
astro
CLIref: getsentry/sentry-javascript#9182