env

lihbr utils for Nuxt.js

@lihbr/utils-nuxt.env configures an object from available environment variables to quickly setup a Nuxt.js application.

Out of current packages, this one is probably the less agnostic one, I definitely need to figure out a way to make it more agnostic and actually usable.

Quickly get all the info you need to kickstart your Nuxt.js application

Installation

Add @lihbr/utils-nuxt.env dependency to your project:

yarn add --dev @lihbr/utils-nuxt.env
npm install --save-dev @lihbr/utils-nuxt.env

Usage

Inside your nuxt.config.js file:

nuxt.config.js
const envConfig = require("@lihbr/utils-nuxt.env");
const pkg = require("./package.json");

const env = envConfig(pkg, settings, GLOBAL_CONTENT);

export default {
  /* your Nuxt.js configuration */
  /* you can used parsed values from `env` in it */
};
Edit this page on GitHub Updated at Tue, Apr 13, 2021