@compiled/eslint-plugin
Advanced tools
Comparing version 0.10.0 to 0.10.1
@@ -11,3 +11,3 @@ "use strict"; | ||
messages: { | ||
unexpected: 'Unexpected `css` export declaration from @compiled/react', | ||
unexpected: "`css` can't be exported - this will cause unexpected behaviour at runtime. Instead, please move your `css(...)` code to the same file where these styles are being used.", | ||
}, | ||
@@ -14,0 +14,0 @@ type: 'problem', |
@@ -11,3 +11,3 @@ "use strict"; | ||
messages: { | ||
unexpected: 'Unexpected `keyframes` export declaration from @compiled/react', | ||
unexpected: "`keyframes` can't be exported - this will cause unexpected behaviour at runtime. Instead, please move your `keyframes(...)` code to the same file where these styles are being used.", | ||
}, | ||
@@ -14,0 +14,0 @@ type: 'problem', |
@@ -19,3 +19,3 @@ "use strict"; | ||
'JSXAttribute[name.name=/[xX]css$/]': (node) => { | ||
if (node.type === 'JSXAttribute' && !context.filename.endsWith('.tsx')) { | ||
if (node.type === 'JSXAttribute' && !context.getFilename().endsWith('.tsx')) { | ||
context.report({ | ||
@@ -22,0 +22,0 @@ node: node.name, |
@@ -8,3 +8,3 @@ "use strict"; | ||
} | ||
const comments = context.sourceCode.getAllComments(); | ||
const comments = context.getSourceCode().getAllComments(); | ||
for (const comment of comments) { | ||
@@ -11,0 +11,0 @@ if (!comment.loc) { |
{ | ||
"name": "@compiled/eslint-plugin", | ||
"version": "0.10.0", | ||
"version": "0.10.1", | ||
"description": "A familiar and performant compile time CSS-in-JS library for React.", | ||
@@ -5,0 +5,0 @@ "homepage": "https://compiledcssinjs.com/docs/pkg-eslint-plugin", |
@@ -11,3 +11,4 @@ import type { Rule } from 'eslint'; | ||
messages: { | ||
unexpected: 'Unexpected `css` export declaration from @compiled/react', | ||
unexpected: | ||
"`css` can't be exported - this will cause unexpected behaviour at runtime. Instead, please move your `css(...)` code to the same file where these styles are being used.", | ||
}, | ||
@@ -14,0 +15,0 @@ type: 'problem', |
@@ -11,3 +11,4 @@ import type { Rule } from 'eslint'; | ||
messages: { | ||
unexpected: 'Unexpected `keyframes` export declaration from @compiled/react', | ||
unexpected: | ||
"`keyframes` can't be exported - this will cause unexpected behaviour at runtime. Instead, please move your `keyframes(...)` code to the same file where these styles are being used.", | ||
}, | ||
@@ -14,0 +15,0 @@ type: 'problem', |
@@ -20,3 +20,3 @@ import type { Rule } from 'eslint'; | ||
'JSXAttribute[name.name=/[xX]css$/]': (node: Rule.Node) => { | ||
if (node.type === 'JSXAttribute' && !context.filename.endsWith('.tsx')) { | ||
if (node.type === 'JSXAttribute' && !context.getFilename().endsWith('.tsx')) { | ||
context.report({ | ||
@@ -23,0 +23,0 @@ node: node.name, |
@@ -8,3 +8,3 @@ import type { Rule } from 'eslint'; | ||
const comments = context.sourceCode.getAllComments(); | ||
const comments = context.getSourceCode().getAllComments(); | ||
@@ -11,0 +11,0 @@ for (const comment of comments) { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
379924
9215