New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

globalseo

Package Overview
Dependencies
Maintainers
0
Versions
130
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

globalseo - npm Package Compare versions

Comparing version 2.1.51 to 2.1.52

2

package.json
{
"name": "globalseo",
"version": "2.1.51",
"version": "2.1.52",
"description": "Translate your React.js or Next.js app with AI",

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

@@ -5,6 +5,12 @@ const { getGlobalseoOptions, shouldTranslateInlineText, CONTEXT_LIMIT, MAX_WORDS_LENGTH_FOR_CONTEXT, OLD_EXCLUDE_CLASS, MERGE_PREFIX } = require("../configs");

function isIgnoredTagInContext(tagName) {
return tagName && ["HTML", "HEAD", "SCRIPT", "STYLE", "SVG", "PATH", "CIRCLE", "TEXTAREA", "INPUT", "SELECT", "OPTION", "NOSCRIPT"].includes(tagName.toUpperCase())
}
function collectAllTextContentInsideNode(node, shouldExclude = false) {
const globalseoOptions = getGlobalseoOptions();
const textNodes = [];
if (isIgnoredTagInContext(node.tagName)) {
return textNodes
}
node.childNodes.forEach((child) => {

@@ -26,2 +32,5 @@ if (shouldExclude && child && child.className && typeof child.className == "string" && (child.className.includes(OLD_EXCLUDE_CLASS) || child.className.includes("globalseo-exclude"))) return;

// if script tag or style tag skip
if (isIgnoredTagInContext(child.tagName)) return;
if (child.nodeType === Node.TEXT_NODE && child.textContent.trim()) {

@@ -28,0 +37,0 @@ textNodes.push(child);

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

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

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