environment

Experimental Feature

This configuration entry is related to an Experimental (Optional) feature called Virtual Environment. Before you start to configure this section, make sure to read the page specific for this feature (accessible here) and this page that explains how to enable Experimental Features.

Type: Promise<void>

Versioning History

API Version v2.0.0 - Introduced environment configuration option.

Configure the environment that Prisma is going to use. In this function, you can mutate the environment however you want: import files using useEnv, change the environment using process.env or run other logic. To configure your virtual environment, add these lines to your configuration object:

prisma-util.config.mjs
export default {
    // Other configuration lines
    environment: async () => {
        // Your environment logic
    }
};

Last updated