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(nuxt): Use --import as the default installation method #12070

Merged
merged 3 commits into from
Dec 10, 2024

Conversation

s1gr1d
Copy link
Member

@s1gr1d s1gr1d commented Dec 6, 2024

Merge after release of @sentry/nuxt v8.43.0

DESCRIBE YOUR PR

Documenting based on this PR: getsentry/sentry-javascript#14553

Dynamic import() is not the default anymore. Docs are changed accordingly

IS YOUR CHANGE URGENT?

Help us prioritize incoming PRs by letting us know when the change needs to go live.

  • Urgent deadline (GA date, etc.): 10. Dez 24
  • Other deadline:
  • None: Not urgent, can wait up to 1 week+

SLA

  • Teamwork makes the dream work, so please add a reviewer to your PRs.
  • Please give the docs team up to 1 week to review your PR unless you've added an urgent due date to it.
    Thanks in advance for your help!

PRE-MERGE CHECKLIST

Make sure you've checked the following before merging your changes:

  • Checked Vercel preview for correctness, including links
  • PR was reviewed and approved by any necessary SMEs (subject matter experts)
  • PR was reviewed and approved by a member of the Sentry docs team

Copy link

vercel bot commented Dec 6, 2024

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

Name Status Preview Comments Updated (UTC)
sentry-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 10, 2024 11:54am
2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
changelog ⬜️ Ignored (Inspect) Visit Preview Dec 10, 2024 11:54am
develop-docs ⬜️ Ignored (Inspect) Visit Preview Dec 10, 2024 11:54am

Copy link

codecov bot commented Dec 6, 2024

Bundle Report

Changes will increase total bundle size by 228 bytes (0.0%) ⬆️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
sentry-docs-server-cjs 10.34MB 234 bytes (0.0%) ⬆️
sentry-docs-client-array-push 9.27MB 6 bytes (-0.0%) ⬇️

})
```

After setting this, the Sentry Nuxt SDK adds a Rollup plugin which wraps the server entry file with a dynamic `import()`.
Copy link
Member

Choose a reason for hiding this comment

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

l: This feels like a bit too much detail. Even the concept of server entry file is confusing, it sounds a bit like our server config file.

Maybe just saying that the build system will take care of ensuring import order using dynamic imports?

Copy link
Contributor

@lizokm lizokm left a comment

Choose a reason for hiding this comment

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

Thanks for adding this! I left some wording suggestions.

docs/platforms/javascript/guides/nuxt/manual-setup.mdx Outdated Show resolved Hide resolved

We recommend using this only if the `--import` flag is not an option for you.
Copy link
Member

Choose a reason for hiding this comment

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

l: should we link to the --import guide? I know we reference it above but users might not have read it and jumped directly to the alert

@@ -20,10 +20,12 @@ supported:
When running your application in ESM mode, you will most likely want to <PlatformLink to="/install/esm">follow the ESM instructions</PlatformLink>. However, if you want to avoid using the `--import` command line option, for example if you have no way of configuring a CLI flag, you can also follow an alternative setup that involves importing the `instrument.mjs` file directly in your application.
Copy link
Member

Choose a reason for hiding this comment

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

does this link exist? I think the link should point to the --import page, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

Those are the node docs, I just edited those as well as I copied the Alert content from there and I thought I add the suggestions I got in this PR in the Node docs as well.

Or should I rather open a new PR for this?

@s1gr1d s1gr1d merged commit 33685cc into master Dec 10, 2024
11 checks passed
@s1gr1d s1gr1d deleted the sig/nuxt-installation-methods-import branch December 10, 2024 14:26
Lms24 pushed a commit that referenced this pull request Dec 13, 2024
* feat(nuxt): Use --import as the default installation method

* change to experimental_entrypointWrappedFunctions

* review suggestions
@github-actions github-actions bot locked and limited conversation to collaborators Dec 26, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants