Next.js Discord

Discord Forum

Next 14 mongoose

Unanswered
Briquet Griffon Vendéen posted this in #help-forum
Open in Discord
Briquet Griffon VendéenOP
hi is
experimental: {
       esmExternals: "loose", // <-- add this
        serverComponentsExternalPackages: ["mongoose"] // <-- and this
    },
    // and the following to enable top-level await support for Webpack
    webpack: (config) => {
        config.experiments = {
            topLevelAwait: true
        };
        return config;
    },


still required with next 14.2.1?

i get stuck on compiliing with esmExternals: "loose", enabled

0 Replies