@varlock/nuxt-integration

Nuxt module to use varlock for .env file loading - adds validation, type-safety, and extra security features
2,422 4,814
Install
npm install @varlock/nuxt-integration
Latest Version:0.1.4
Vue:3
License:MIT
Last Updated:Oct 22, 2026
Links: GitHub  ·  npm
Maintainer: philmillman

@varlock/nuxt-integration

npm version GitHub stars license

This package helps you integrate varlock into a Nuxt project.

See our docs site for complete installation and usage instructions.

It is designed as a Nuxt module that adds varlock to both the Vite config and the Nitro server build, so .env files are loaded and validated by varlock across dev, build, and the production server.

Compared to the default Nuxt behavior, this package provides:

  • Validation of your env vars against your .env.schema
  • Type-generation and type-safe env var access with built-in docs
  • Redaction of sensitive values from logs during build and dev time
  • Automatic leak prevention of sensitive items at build and runtime
  • More flexible multi-env handling

Installation

npm install @varlock/nuxt-integration varlock
# or
bun add @varlock/nuxt-integration varlock

Setup

Add the module to your nuxt.config.ts:

export default defineNuxtConfig({
  modules: ['@varlock/nuxt-integration'],
})

Then run varlock init to set up your .env.schema file based on your existing .env files.

Related Packages

nuxt-yup

yup implementation for nuxt

2,981 4
nuxt-auther

Authentication module for Nuxt.JS

1,609 1
@luewell/nuxt-alt-auth

An alternative module to @nuxtjs/auth

709 113

Version History

Version Released License
0.1.4 MIT
0.1.3 MIT
0.1.2 MIT
0.1.1 MIT
0.1.0 MIT