Socket
Socket
Sign inDemoInstall

@sveltejs/vite-plugin-svelte

Package Overview
Dependencies
Maintainers
4
Versions
107
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sveltejs/vite-plugin-svelte - npm Package Compare versions

Comparing version 2.0.1 to 2.0.2

4

package.json
{
"name": "@sveltejs/vite-plugin-svelte",
"version": "2.0.1",
"version": "2.0.2",
"license": "MIT",

@@ -53,3 +53,3 @@ "author": "dominikg",

"@types/debug": "^4.1.7",
"esbuild": "^0.16.3",
"esbuild": "^0.16.4",
"rollup": "^2.79.1",

@@ -56,0 +56,0 @@ "svelte": "^3.54.0",

@@ -38,18 +38,19 @@ import { Plugin, normalizePath } from 'vite';

const vps = config.plugins.find((p) => p.name === 'vite-plugin-svelte');
if (vps?.api?.options?.experimental?.inspector) {
inspectorOptions = {
...defaultInspectorOptions,
...vps.api.options.experimental.inspector
};
}
if (!vps || !inspectorOptions) {
const options = vps?.api?.options?.experimental?.inspector;
if (!vps || !options) {
log.debug('inspector disabled, could not find config');
disabled = true;
} else {
if (vps.api.options.kit && !inspectorOptions.appendTo) {
const out_dir = path.basename(vps.api.options.kit.outDir || '.svelte-kit');
inspectorOptions.appendTo = `${out_dir}/generated/root.svelte`;
}
appendTo = inspectorOptions.appendTo;
return;
}
inspectorOptions = {
...defaultInspectorOptions,
...options
};
const isSvelteKit = config.plugins.some((p) => p.name.startsWith('vite-plugin-sveltekit'));
if (isSvelteKit && !inspectorOptions.appendTo) {
// this could append twice if a user had a file that ends with /generated/root.svelte
// but that should be rare and inspector doesn't execute twice
inspectorOptions.appendTo = `/generated/root.svelte`;
}
appendTo = inspectorOptions.appendTo;
},

@@ -56,0 +57,0 @@

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

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