Merged in chore/eslint-curly-braces (pull request #3304)

Chore/eslint curly braces

* Add eslint rule for curly braces

* run eslint --fix for all files


Approved-by: Linus Flood
This commit is contained in:
Joakim Jäderberg
2025-12-08 07:56:21 +00:00
parent 5986828580
commit de4b3c1c3c
54 changed files with 139 additions and 104 deletions

View File

@@ -2,6 +2,7 @@ import { defineConfig, globalIgnores } from 'eslint/config'
import globals from 'globals'
import tsParser from '@typescript-eslint/parser'
import reactRefresh from 'eslint-plugin-react-refresh'
import react from 'eslint-plugin-react'
import { FlatCompat } from '@eslint/eslintrc'
import js from '@eslint/js'
import importPlugin from 'eslint-plugin-import'
@@ -35,6 +36,7 @@ export default defineConfig([
'react-refresh': reactRefresh,
import: importPlugin,
formatjs,
react,
},
settings: {
// Ensure the plugin can resolve workspace packages and TS path aliases
@@ -64,6 +66,14 @@ export default defineConfig([
allowConstantExport: true,
},
],
'react/jsx-curly-brace-presence': [
'error',
{
props: 'never',
children: 'never',
propElementValues: 'always',
},
],
'formatjs/enforce-default-message': ['error', 'literal'],
'formatjs/enforce-placeholders': ['error'],