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

tslint-plugin-emotion

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tslint-plugin-emotion - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

2

package.json
{
"name": "tslint-plugin-emotion",
"version": "1.0.1",
"version": "1.0.2",
"main": "tslint-emotion.json",

@@ -5,0 +5,0 @@ "repository": "git@github.com:Werter12/tslint-plugin-emotion.git",

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

var literalExpressionFixed = false;
var cssAttribute = {
var cssAttributes = {
has: false,
nodes: [],
};

@@ -69,5 +70,6 @@ var cb = function (node) {

if (node.name.escapedText === "css") {
if (!cssAttribute.has) {
cssAttribute.has = true;
if (!cssAttributes.has) {
cssAttributes.has = true;
}
cssAttributes.nodes.push(node.name);
var initializer = node.initializer;

@@ -84,3 +86,3 @@ if (initializer && tsutils_1.isJsxExpression(initializer) && initializer.expression

ts.forEachChild(sourceFile, cb);
if (!cssAttribute.has) {
if (!cssAttributes.has) {
return;

@@ -120,3 +122,8 @@ }

}
return this.addFailure(0, 1, Rule.FAILURE_STRING, Lint.Replacement.appendText(0, "" + pragmaCommentString + importString + "\n"));
if (cssAttributes.nodes.length) {
cssAttributes.nodes.forEach(function (cssAttribute) {
_this.addFailureAtNode(cssAttribute, Rule.FAILURE_STRING, Lint.Replacement.appendText(0, "" + pragmaCommentString + importString + "\n"));
});
return;
}
}

@@ -123,0 +130,0 @@ };

@@ -38,3 +38,3 @@ "use strict";

type: "functionality",
hasFix: false,
hasFix: true,
typescriptOnly: true,

@@ -41,0 +41,0 @@ };

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

"import-from-emotion": true,
"no-vanilla": true,
"no-vanilla": false,
"syntax-preference": false,

@@ -8,0 +8,0 @@ "jsx-import": true

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