Update eslint-plugin-unicorn to v53 (#16275)

This commit is contained in:
fisker Cheung authored and GitHub committed 2024-06-04 09:39:19 +08:00
1 parent 80bdbfe312
commit b26f56bd31
21 files changed
+91 -68

No files matched your search

+2 -2
View File
@@ -10,12 +10,12 @@ export default function getCodeSamples(parser) {
" if(!greeting){return null};",
"",
" // TODO: Don't use random in render",
' let num = Math.floor (Math.random() * 1E+7).toString().replace(/\\.\\d+/ig, "")',
String.raw` let num = Math.floor (Math.random() * 1E+7).toString().replace(/\.\d+/ig, "")`,
"",
" return <div className='HelloWorld' title={`You are visitor number ${ num }`} onMouseOver={onMouseOver}>",
"",
" <strong>{ greeting.slice( 0, 1 ).toUpperCase() + greeting.slice(1).toLowerCase() }</strong>",
' {greeting.endsWith(",") ? " " : <span style={{color: \'\\grey\'}}>", "</span> }',
String.raw` {greeting.endsWith(",") ? " " : <span style={{color: '\grey'}}>", "</span> }`,
" <em>",
"\t{ greeted }",
"\t</em>",
+1
View File
@@ -67,6 +67,7 @@ async function handleMetaMessage() {
return {
type: "meta",
// eslint-disable-next-line unicorn/prefer-structured-clone
supportInfo: JSON.parse(JSON.stringify(supportInfo)),
version: prettier.version,
};