SigNoz is an open-source, OpenTelemetry-native observability platform for your team and their AI agents. Get logs, metrics, and traces in one tool with features like APM, distributed tracing, log management, infra monitoring, etc. Combined with SigNoz MCP and a native AI teammate (in SigNoz Cloud) it helps you build more resilient apps.
TypeScript apmapplication-monitoringdistributed-tracinggogood-first-issuejaegerloglogsmetricsmonitoringnextjsobservabilityopen-sourceopentelemetryprometheusreactreactjsself-hostedtracingtypescript
chore: add max-params eslint rule and update contribution guidelines (#10200)
Ashwin Bhatkal66f4c3d6ec01
diff --git a/frontend/.eslintrc.js b/frontend/.eslintrc.jsindex bc3899fe91..2d10b6c2ac 100644--- a/frontend/.eslintrc.js+++ b/frontend/.eslintrc.js@@ -61,6 +61,8 @@ module.exports = {curly: 'error', // Requires curly braces for all control statementseqeqeq: ['error', 'always', { null: 'ignore' }], // Enforces === and !== (allows == null for null/undefined check)'no-console': ['error', { allow: ['warn', 'error'] }], // Warns on console.log, allows console.warn/error+ // TODO: Change this to error in May 2026+ 'max-params': ['warn', 3], // a function can have max 3 params after which it should become an object// TypeScript rules'@typescript-eslint/explicit-function-return-type': 'error', // Requires explicit return types on functions@@ -116,7 +118,7 @@ module.exports = {},],'import/no-extraneous-dependencies': ['error', { devDependencies: true }], // Prevents importing packages not in package.json- // 'import/no-cycle': 'warn', // TODO: Enable later to detect circular dependencies+ 'import/no-cycle': 'warn', // Warns about circular dependencies// Import sorting rules'simple-import-sort/imports': [@@ -146,6 +148,19 @@ module.exports = {'sonarjs/no-duplicate-string': 'off', // Disabled - can be noisy (enable periodically to check)},overrides: [+ {+ files: [+ '**/*.test.{js,jsx,ts,tsx}',+ '**/*.spec.{js,jsx,ts,tsx}',+ '**/__tests__/**/*.{js,jsx,ts,tsx}',+ ],+ rules: {+ // Tests often have intentional duplication and complexity - disable SonarJS rules+ 'sonarjs/cognitive-complexity': 'off', // Tests can be complex+ 'sonarjs/no-identical-functions': 'off', // Similar test patterns are OK+ 'sonarjs/no-small-switch': 'off', // Small switches are OK in tests+ },+ },{files: ['src/api/generated/**/*.ts'],rules: {@@ -153,7 +168,6 @@ module.exports = {'@typescript-eslint/explicit-module-boundary-types': 'off','no-nested-ternary': 'off','@typescript-eslint/no-unused-vars': 'warn',- 'sonarjs/no-duplicate-string': 'off',},},],diff --git a/frontend/CONTRIBUTIONS.md b/frontend/CONTRIBUTIONS.mdindex f5574c8d9b..5afae1f527 100644--- a/frontend/CONTRIBUTIONS.md+++ b/frontend/CONTRIBUTIONS.md@@ -2,6 +2,11 @@Embrace the spirit of collaboration and contribute to the success of our open-source project by adhering to these frontend development guidelines with precision and passion.+### Export Style++- **React components** (`src/components/`, `src/container/`, `src/pages/`): Prefer **default exports** for the main component in each file+- **Utilities, hooks, APIs, types, constants** (`src/utils/`, `src/hooks/`, `src/api/`, `src/lib/`, `src/types/`, `src/constants/`): Prefer **named exports** for better tree-shaking and explicit imports+### React and Components- Strive to create small and modular components, ensuring they are divided into individual pieces for improved maintainability and reusability.