Socket
Socket
Sign inDemoInstall

vite-plugin-externals

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vite-plugin-externals - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

README.zh-CN.md

2

package.json
{
"name": "vite-plugin-externals",
"version": "0.1.1",
"version": "0.1.2",
"description": "externals plugin for vite",

@@ -5,0 +5,0 @@ "author": "crcong",

# vite-plugin-externals
English | [简体中文](README.zh-CN.md)
use to external resources, like webpack externals, but only use in browser now.

@@ -43,3 +45,3 @@

// transformed
const Vue = window.Vue
const Vue = window['Vue']

@@ -49,4 +51,4 @@ // source code

// transformed
const reactive = window.Vue.reactive
const r = window.Vue.ref
const reactive = window['Vue'].reactive
const r = window['Vue'].ref
```

@@ -94,2 +96,4 @@

**Warning**: If your module name has special characters, such as `/`, set useWindow option `false`, will throw error.
```js

@@ -102,4 +106,4 @@ viteExternalsPlugin({

import Vue from 'vue'
// transformed, no `const Vue = window.Vue`
// transformed, no `const Vue = window['Vue']`
const Vue = Vue
```
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