Add svg testing screen to Benchmark#1321
Open
jonathanmos wants to merge 3 commits into
Open
Conversation
🎉 All green!🧪 All tests passed 🔗 Commit SHA: 4580336 | Docs | Datadog PR Page | Give us feedback! |
1be6678 to
9bb5849
Compare
9bb5849 to
0f89ace
Compare
There was a problem hiding this comment.
Pull request overview
Adds an SVG-focused benchmark screen to the Session Replay UI catalog in the benchmarks app, along with the build/config plumbing to import .svg files as React components and an iOS/Xcode 26 build workaround.
Changes:
- Added a new Session Replay “SVG Test Screen” with a broad set of SVG rendering/privacy test cases plus local SVG assets and a TS
*.svgmodule declaration. - Enabled SVG imports in Metro via
react-native-svg-transformerand enabled Datadog Session Replay SVG tracking via the benchmark Babel config. - Added
react-native-svg(and transformer deps) to the benchmarks app and introduced a Podfile post-install patch to mitigate Xcode 26+fmtconsteval build failures.
Reviewed changes
Copilot reviewed 8 out of 14 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| yarn.lock | Locks new dependencies for SVG rendering/transformer and related transitive packages. |
| benchmarks/svg.d.ts | Adds TS module typings for *.svg imports as React.FC<SvgProps>. |
| benchmarks/src/scenario/SessionReplay/UIDetailView.tsx | Wires the new SVG screen into the detail view switch. |
| benchmarks/src/scenario/SessionReplay/types.ts | Adds UIElement.Svg to the UI catalog enum. |
| benchmarks/src/scenario/SessionReplay/component/Svg.tsx | New SVG test screen exercising static shapes, transforms, dynamic props, file imports, privacy wrappers, and an unsupported-element repro. |
| benchmarks/src/scenario/SessionReplay/component/assets/star.svg | Adds local SVG asset used by import test cases. |
| benchmarks/src/scenario/SessionReplay/component/assets/shield.svg | Adds local SVG asset used by import test cases. |
| benchmarks/src/scenario/SessionReplay/component/assets/heart.svg | Adds local SVG asset used by import test cases. |
| benchmarks/src/scenario/SessionReplay/component/assets/icons.ts | Adds a barrel export to validate named-export SVG import behavior. |
| benchmarks/package.json | Adds react-native-svg dependency and transformer + Datadog babel plugin devDependencies. |
| benchmarks/metro.config.js | Configures Metro to treat .svg as source and transform via react-native-svg-transformer. |
| benchmarks/ios/Podfile.lock | Updates pods to include RNSVG and reflects dependency graph checksum changes. |
| benchmarks/ios/Podfile | Adds a post_install patch to disable fmt consteval under Xcode 26+ Apple Clang. |
| benchmarks/babel.config.js | Enables @datadog/mobile-react-native-babel-plugin with sessionReplay.svgTracking. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
sbarrio
reviewed
Jul 8, 2026
| # Workaround for fmt consteval errors with Xcode 26+ Clang: | ||
| # The fmt library's consteval usage is incompatible with newer Apple Clang. | ||
| # Patch base.h to disable consteval by adding a guard for the current Xcode. | ||
| fmt_base_header = File.join(installer.sandbox.pod_dir('fmt'), 'include', 'fmt', 'base.h') |
Contributor
There was a problem hiding this comment.
Thanks for fixing this, I hadn't tested this with XCode 26.6 until now 😅
sbarrio
approved these changes
Jul 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Adds screen to
benchmarkto test svgs.In addition, fixes an issue with running on ios 26.
Motivation
What inspired you to submit this pull request?
Additional Notes
Anything else we should know when reviewing?
Review checklist (to be filled by reviewers)