Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
🟡 Changes recommended
The newly introduced ESLint stylistic formatting rules are incompatible with the repo’s enforced Prettier configuration/workflow, which will cause non-idempotent formatting and likely CI lint failures.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR introduces stricter, ESLint-enforced formatting rules (mandatory control-flow braces, multiline block bodies, multiline non-empty object literals, and padding between consecutive block-like statements) across the Exceptionless JavaScript SDK monorepo, and reformats existing source/tests accordingly without intended behavioral or public API changes.
Changes:
- Add
@stylistic/eslint-pluginand new ESLint rules to enforce consistent block/object formatting. - Add a new Vitest project plus a
scripts/test that validates the ESLint rule behavior. - Reformat SDK source and test files across packages (core/browser/node/react/react-native/angularjs) to comply with the new rules.
File summaries
| File | Description |
|---|---|
| vitest.config.ts | Adds a dedicated Vitest “scripts” project to discover .mjs tests under scripts/. |
| scripts/eslint-rules.test.mjs | Adds rule-level tests that lint fixture snippets and assert expected ESLint rule IDs. |
| eslint.config.mjs | Adds @stylistic plugin plus formatting rules; adds a scripts/**/*.mjs config block. |
| package.json | Adds @stylistic/eslint-plugin devDependency. |
| package-lock.json | Locks @stylistic/eslint-plugin and its transitive dev dependencies. |
| packages/react/src/ExceptionlessErrorBoundary.tsx | Formatting-only updates to object literals. |
| packages/react-native/src/ExceptionlessErrorBoundary.tsx | Formatting-only updates to object literals. |
| packages/react-native/src/logging/CallbackLog.ts | Formatting-only updates to object literal construction. |
| packages/node/src/storage/NodeDirectoryStorage.ts | Formatting-only updates to mkdirSync options object literal. |
| packages/core/src/ExceptionlessClient.ts | Formatting-only updates to object literal construction/arguments. |
| packages/core/src/EventBuilder.ts | Formatting-only updates to inline object literal creation. |
| packages/core/src/Utils.ts | Formatting-only updates to type guards, casts, and wrapped expressions. |
| packages/core/src/storage/InMemoryStorage.ts | Formatting-only updates to control-flow braces. |
| packages/core/src/queue/DefaultEventQueue.ts | Formatting-only updates to block braces and object literal construction. |
| packages/core/src/plugins/EventPluginContext.ts | Formatting-only updates to control-flow braces. |
| packages/core/src/plugins/default/DuplicateCheckerPlugin.ts | Formatting-only updates (including padding line insertion). |
| packages/browser/src/plugins/BrowserGlobalHandlerPlugin.ts | Formatting-only updates to function/type formatting and callback shape. |
| packages/browser/src/plugins/BrowserErrorPlugin.ts | Formatting-only updates to object literal push. |
| packages/angularjs/src/index.ts | Formatting-only updates to function signature wrapping and casts. |
| packages/react-native/test/storage/AsyncStorageProvider.test.ts | Formatting-only updates to inline type/object formatting. |
| packages/react-native/test/ReactNativeExceptionlessClient.test.ts | Formatting-only updates to defineProperty options objects. |
| packages/react-native/test/plugins/ReactNativeLifeCyclePlugin.test.ts | Formatting-only updates to startup call objects and defineProperty options. |
| packages/react-native/test/plugins/ReactNativeGlobalHandlerPlugin.test.ts | Formatting-only updates to startup call objects, errors, and defineProperty options. |
| packages/react-native/test/plugins/ReactNativeErrorPlugin.test.ts | Formatting-only updates to EventPluginContext construction formatting. |
| packages/react-native/test/plugins/ReactNativeEnvironmentInfoPlugin.test.ts | Formatting-only updates to defineProperty options and object literals. |
| packages/react-native/test/plugins/NativeCrashPlugin.test.ts | Formatting-only updates to startup call objects and defineProperty options. |
| packages/react-native/test/logging/CallbackLog.test.ts | Formatting-only updates to inline mocked logger object literals. |
| packages/node/test/storage/NodeDirectoryStorage.test.ts | Formatting-only updates to fs call options objects. |
| packages/core/test/Utils.test.ts | Formatting-only updates to many test literals/arrays/maps and wrapped calls. |
| packages/core/test/submission/TestSubmissionClient.test.ts | Formatting-only updates to event arrays and request option objects. |
| packages/core/test/queue/DefaultEventQueue.test.ts | Formatting-only updates to event object literals and wrapped assertions. |
| packages/core/test/plugins/default/EventExclusionPlugin.test.ts | Formatting-only updates to event/context object construction and settings objects. |
| packages/core/test/plugins/default/ConfigurationDefaultsPlugin.test.ts | Formatting-only updates to event and expected object literals. |
| packages/core/test/DocumentationExamples.test.ts | Formatting-only updates to expected object literals. |
| packages/core/test/configuration/Configuration.test.ts | Formatting-only updates to server settings object literal. |
| packages/browser/test/plugins/BrowserIgnoreExtensionErrorsPlugin.test.ts | Formatting-only updates to EventPluginContext construction formatting. |
| packages/browser/test/plugins/BrowserErrorPlugin.test.ts | Formatting-only updates to Error options object literal. |
Review details
- Files reviewed: 37/38 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b6d9e8db23
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Enforces braces around control-flow bodies, multiline non-empty object literals and blocks, and a blank line before control statements following a block.
npm run formatnow runs ESLint fixes before Prettier so it produces compliant code. Existing SDK behavior and public APIs are preserved; unnecessary type-formatting churn was removed.Validation: build, lint and all 363 tests pass locally, including 17 formatting tests. All 10 GitHub checks pass on
38e1b363, including Linux/macOS/Windows builds and CodeQL. Reviewer approval is required.Existing dependency audit findings remain: 37 total, including two critical. None affect the newly added formatter dependencies; dependency remediation is outside this formatting change.
Verification and implementation details
{ always: true }option is not a supported rule schema.if,while, all threeforforms anddo, required spacing, and ESLint autofix → Prettier → ESLint stability using the repository configuration.1tbsintentionally keepselseon the closing-brace line.npm run formatcommand also corrected a fresh inline-object fixture, and the result passed ESLint.Utils.test.tsgrows from 855 to 1,240 lines because existing object fixtures expand. Its grouped test structure and assertions are unchanged; splitting it would add unrelated refactoring to this formatting-only migration.npm ci,npm run build,npm run lint,npm test. Run just the policy tests withnpx vitest run --project scripts.