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

bright

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bright - npm Package Compare versions

Comparing version 0.8.1 to 0.8.2

28

dist/index.js

@@ -551,5 +551,10 @@ "use strict";

} else {
let newLang = lang || "text";
if (!import_lighter2.LANG_NAMES.includes(newLang)) {
console.warn(`Bright warning: Unknown language ${JSON.stringify(lang)}`);
newLang = "text";
}
return {
code: children || code || "",
lang
lang: newLang
};

@@ -560,17 +565,18 @@ }

if (!className) {
return {
lang: "text"
};
return { lang: "text" };
}
const metastring = className.replace("language-", "");
const lang = metastring.split(".").pop();
if (!import_lighter2.LANG_NAMES.includes(lang)) {
console.warn(
`Bright warning: Unknown language ${JSON.stringify(
lang
)} in ${JSON.stringify(metastring)}`
);
return { lang: "text" };
}
if (lang !== metastring) {
return {
lang,
title: metastring
};
return { lang, title: metastring };
}
return {
lang
};
return { lang };
}

@@ -577,0 +583,0 @@ // Annotate the CommonJS export names for ESM import in node:

{
"name": "bright",
"version": "0.8.1",
"version": "0.8.2",
"main": "./dist/index.js",

@@ -5,0 +5,0 @@ "module": "./dist/index.mjs",

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