First of all, thanks for this amazing plugin which I really find useful. I'm just running an issue where I'd like to run some stuff on just development server phase. To facilitate I'll paste here some of the code:
Sorry I lack of the context to give more useful information on why it may happen. For now what I've made to solve it is by creating a simple plugin.
A generic example:
const myPlugin = (nextConfig = {}, nextComposePlugins) => {
if (
PHASE_DEVELOPMENT_SERVER &&
[PHASE_DEVELOPMENT_SERVER].includes(
nextComposePlugins && nextComposePlugins.phase,
)
)
// Do some stuff just on development
return nextConfig
}
Hi there,
First of all, thanks for this amazing plugin which I really find useful. I'm just running an issue where I'd like to run some stuff on just development server phase. To facilitate I'll paste here some of the code:
To avoid the type error the solution would be some safe key checking on
updatedConfig
https://github.com/cyrilwanner/next-compose-plugins/blob/master/src/compose.js#L102Sorry I lack of the context to give more useful information on why it may happen. For now what I've made to solve it is by creating a simple plugin.
A generic example:
Then: