Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

vite-plugin-env-compatible

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vite-plugin-env-compatible - npm Package Compare versions

Comparing version 0.1.0 to 0.2.0

12

dist/index.js

@@ -1,2 +0,2 @@

"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var __create = Object.create;
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }var __create = Object.create;
var __defProp = Object.defineProperty;

@@ -24,5 +24,3 @@ var __getProtoOf = Object.getPrototypeOf;

var __toModule = (module) => {
if (module && module.__esModule)
return module;
return __exportStar(__markAsModule(__defProp(module != null ? __create(__getProtoOf(module)) : {}, "default", {value: module, enumerable: true})), module);
return __exportStar(__markAsModule(__defProp(module != null ? __create(__getProtoOf(module)) : {}, "default", module && module.__esModule && "default" in module ? {get: () => module.default, enumerable: true} : {value: module, enumerable: true})), module);
};

@@ -175,3 +173,3 @@

});
import_dotenv_expand.default({
(0, import_dotenv_expand.default)({
parsed,

@@ -213,6 +211,8 @@ ignoreProcessEnv

const myDefine = {};
if (_optionalChain([options, 'access', _ => _.mountedPath, 'optionalAccess', _2 => _2.startsWith, 'call', _3 => _3("process.env")])) {
myDefine["process.env.VITE"] = JSON.stringify(true);
}
Object.keys(env).map((key) => {
const value = env[key];
myDefine[`${options.mountedPath}.${key}`] = JSON.stringify(value);
myDefine[`${options.mountedPath}`] = {};
});

@@ -219,0 +219,0 @@ config.define = {

{
"name": "vite-plugin-env-compatible",
"version": "0.1.0",
"version": "0.2.0",
"description": "Environment Variables Compatible",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc