Rasengan Logo
Rasengan Logo
  • Docs
  • Blog
  • Showcase
  • Support us
Using stable versionv1.2.0
Documentation
Packages
Templates
Rasengan UI Kit
Using stable versionv1.2.0
Documentation
Packages
Templates
Rasengan UI Kit

CORE CONCEPTS

Environment Variables

Rasengan.js comes with built-in support for environment variables, which allows you to do the following:

  • Use .env to load environment variables
  • Bundle environment variables for the browser by prefixing with RASENGAN_

Load Environment Variables

Rasengan.js has built-in support for loading environment variables from .env into import.meta.env.

.env
txtRASENGAN_API_URL=https://api.example.com RASENGAN_API_KEY=abc123 RASENGAN_PORT=3000

Access to Environment Variables

Using environment variables in your application is easy. You can access them like follow:

src/app/home.page.js
jsimport.meta.env.RASENGAN_API_URL; // 'https://api.example.com' import.meta.env.RASENGAN_API_KEY; // 'abc123' import.meta.env.RASENGAN_PORT; // '3000'
TypeScript
Modules Aliases

ON THIS PAGE

Load Environment Variables
Access to Environment Variables
Rasengan Logo
Rasengan Logo

Resources

  • Docs
  • Packages
  • Blog
  • Showcase
  • Support us

Community

  • Github
  • X (Twitter)

Subscribe to the Newsletter

Stay informed to the news about rasengan.js including new releases, events, etc...

© 2024-2026 Rasengan Labs, All rights reserved.