@minko-fe/vite-config
Version:
22 lines (20 loc) • 512 B
JavaScript
// src/client/utils/env.ts
var Env = /* @__PURE__ */ ((Env2) => {
Env2["development"] = "development";
Env2["test"] = "test";
Env2["production"] = "production";
return Env2;
})(Env || {});
function getEnv() {
return import.meta.env.MODE;
}
function isDev() {
return getEnv() === "development" /* development */;
}
function isTest() {
return getEnv() === "test" /* test */;
}
function isProd() {
return getEnv() === "production" /* production */;
}
export { Env, getEnv, isDev, isProd, isTest };