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

@vaadin/vaadin-development-mode-detector

Package Overview
Dependencies
Maintainers
8
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vaadin/vaadin-development-mode-detector - npm Package Compare versions

Comparing version 1.0.3-pre.4 to 1.0.3-pre.5

9

package.json

@@ -5,3 +5,3 @@ {

"name": "@vaadin/vaadin-development-mode-detector",
"version": "1.0.3-pre.4",
"version": "1.0.3-pre.5",
"author": "Vaadin Ltd",

@@ -13,11 +13,12 @@ "license": "Apache-2.0",

"supports-color": "3.1.2",
"type-detect": "1.0.0"
"type-detect": "1.0.0",
"@webcomponents/webcomponentsjs": "2.0.0-beta.2"
},
"main": "vaadin-development-mode-detector.js",
"dependencies": {
"@polymer/polymer": "^3.0.0-pre.12"
"@polymer/polymer": "^3.0.0-pre.13"
},
"devDependencies": {
"@webcomponents/webcomponentsjs": "^1.0.0"
"@webcomponents/webcomponentsjs": "^2.0.0-beta.2"
}
}
import { importHref } from '@polymer/polymer/lib/utils/import-href.js';
import { DomModule } from '@polymer/polymer/lib/elements/dom-module.js';
const $_documentContainer = document.createElement('div');
const $_documentContainer = document.createElement('template');
$_documentContainer.setAttribute('style', 'display: none;');

@@ -9,3 +9,3 @@

document.head.appendChild($_documentContainer);
document.head.appendChild($_documentContainer.content);
const version = window['Polymer'] && window['Polymer'].version;

@@ -37,12 +37,2 @@

function getEsModules() {
// native ES modules
const modules = document.querySelectorAll("script[type=module]");
// require.js modules
const require = document.querySelectorAll("script[data-requiremodule]");
return Array.from(modules).concat(Array.from(require));
}
function isUnbundled() {

@@ -54,4 +44,7 @@ if (useHtmlImports) {

} else {
const modules = getEsModules();
return modules.filter(function (m) { return m.src.indexOf("vaadin-") > -1 }).length > 0;
const scripts = Array.from(document.querySelectorAll("script"));
// TODO(web-padawan): this is not expected to work for applications using native ES modules,
// since the index.html is unlikely to contain any direct imports of Vaadin components.
// It works with the AMD transform of CLI, as the <script> tags are being added to <head>.
return scripts.filter(script => script.src.indexOf("@vaadin") > -1).length > 0;
}

@@ -58,0 +51,0 @@ }

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