Socket
Socket
Sign inDemoInstall

less-vars-to-js

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

less-vars-to-js - npm Package Compare versions

Comparing version 1.1.1 to 1.1.2

3

dist/index.js

@@ -9,4 +9,5 @@ "use strict";

var lessVars = {};
var matches = sheet.match(/@(.*:[^;]*)/g) || [];
sheet.match(/@(.*:[^;]*)/g).forEach(function (variable) {
matches.forEach(function (variable) {
var definition = variable.split(/:\s*/);

@@ -13,0 +14,0 @@ lessVars[definition[0]] = definition[1];

{
"name": "less-vars-to-js",
"version": "1.1.1",
"version": "1.1.2",
"description": "Read LESS variables from the contents of a file and returning them as a javascript object.",

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

@@ -104,2 +104,13 @@ import lessVarsToJS from '../src';

}
},
{
should: 'should not break in file with no variables',
input: `
@import (reference) 'theme';
.element {
color: black;
}
`,
output: {}
}

@@ -106,0 +117,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