(function(n,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(n=typeof globalThis<"u"?globalThis:n||self,n.MetaEnv=t())})(this,function(){"use strict";function n(e,i){if(!e)throw new Error("vite-plugin-meta-env: configuration is required.");if(toString.call(e)!=="[object Object]")throw new Error("vite-plugin-meta-env: configuration must be an object.");if(Object.keys(e).length===0)throw new Error("vite-plugin-meta-env: configuration can not be empty.");const o={};for(const r in e)o[`${i}.${r}`]=JSON.stringify(e[r]);return o}function t(e,i){return{name:"vite-plugin-meta-env",config(){return{define:n(e,i)}}}}return t});