Closed as not planned
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Self-hosted/on-premise
Which SDK are you using?
@sentry/nextjs
SDK Version
7.80.1
Framework Version
Nextjs 14.0.1, nx 17.0.3
Link to Sentry event
No response
SDK Setup
I've followed the manual setup, because I'm using nx. The only difference was the Next.js configuration file. I tried to setup Sentry using nx composePlugins
, like this:
const { composePlugins, withNx } = require('@nx/next');
const { withSentryConfig } = require('@sentry/nextjs');
const sentryWebpackPluginOptions = { /* my sentry configs */ };
const withSentry = (config) => withSentryConfig(config, sentryWebpackPluginOptions);
const plugins = [withNx, withSentry];
module.exports = composePlugins(...plugins)(nextConfig);
The plugin type, as expected by composePlugins
, should implement this interface:
export interface NextPlugin {
(config: NextConfig): NextConfig;
}
But withSentryConfig
uses its own types, like ExportedNextConfig and NextConfigFunction, instead of NextConfig from Next.js.
Steps to Reproduce
Apply the configs from SDK Setup
above.
Expected Result
It should work with the above config.
Actual Result
This type error:
Parameter 'config' implicitly has an 'any' type.ts(7006)
Metadata
Metadata
Assignees
Type
Projects
Status
Waiting for: Product Owner