1.3.4 • Published 4 months ago

@dotenv-run/rollup v1.3.4

Weekly downloads
-
License
ISC
Repository
-
Last release
4 months ago

@dotenv-run/rollup

  • ✅ Load environment variables from the command line API_BASE=/v1/ rollup
  • ✅ Load environment variables from .env files
  • ✅ Expand environment variables API_URL=$API_BASE/users
  • ✅ Define environment variables for a specific environment (e.g. .env.production)
  • ✅ Load priorities of .env.* files (e.g. .env.production > .env)
  • ✅ Hierarchical cascading configuration in monorepo projects (Nx, Turbo, etc.) apps/next-app/.env > apps/.env > .env

Install

npm add @dotenv-run/rollup --save-dev

Usage

Create a rollup.config.js configuration file and import the plugin:

import env from "@dotenv-run/rollup";

export default {
  input: "src/index.js",
  output: {
    file: "dist/index.js",
  },
  plugins: [env({ prefix: "API", verbose: true, root: "../../.." })],
};

Then call rollup either via the CLI or the API.

1.3.4

4 months ago

1.3.3

4 months ago

1.3.2

4 months ago

1.3.1

4 months ago

1.3.0

4 months ago

1.2.3

6 months ago

1.2.2

6 months ago

1.2.1

6 months ago

1.2.0

7 months ago

1.1.1

9 months ago

1.1.0

9 months ago

1.0.1

10 months ago

1.0.0

10 months ago

0.5.0

10 months ago