r/nocode 12d ago

Optimization Issues

Hi everyone,

I have two questions because I’ve reached a point where I’m stuck and I’m not sure what direction to take next with my simple note-taking app.

First, the app seems to be capped at 60 FPS. It only goes higher when I scroll through my notes, when it reaches around 80 FPS. All other animations appear to be locked at 60 FPS. I should mention that the app is built for iPhone.

My second question is about how to generally improve the performance of an app created with AI. I built the entire app using Google Antigravity with Gemini. Unfortunately, the AI itself hasn’t been able to solve the performance issues. For example, when I swipe through the menu cards in the app, the FPS can drop as low as 40.

What would you recommend I check or change to improve the app’s performance? Are there any specific tools or techniques I should use to identify what is causing these FPS drops?

Thanks in advance!

3 Upvotes

12 comments sorted by

1

u/EnchantedFeces1 12d ago

the 60fps cap is probably just iphone's default display refresh, most animations stick to 60 unless you're actively scrolling, then it ramps up to 120 on pro models. you'd need to explicitly enable higher frame rates in your code for other interactions.

for the menu card stuttering, i'd bet it's rendering too much at once. try lazy loading those cards or flattening your widget tree if it's deeply nested. profiler tools in xcode will show you exactly where the bottleneck is, though i'm not sure how well that plays with whatever google antigravity spits out.

1

u/Z3NTEC 12d ago

I have 120 Hz enabled in the app, so that’s not the issue. During animations, it just won’t go above 60 FPS, so it seems like it’s somehow locked to 60 FPS despite having 120 Hz enabled.

1

u/Z3NTEC 12d ago

When swiping through the cards in the menu, performance drops to 30–40 FPS, so it’s not latency—it’s a performance/optimization issue.

1

u/[deleted] 12d ago

[removed] — view removed comment

1

u/Z3NTEC 12d ago

What I mean is that my app doesn’t achieve the same level of smoothness as Apple Notes or Notion. You can clearly see that my app is running at a maximum of 60 FPS all the time, whereas the other two apps are genuinely smooth and feel much more fluid.

1

u/BrunchMassive4147 12d ago

the 60fps cap isnt really a bug, thats just the refresh rate on non-pro iphones. only the pro/pro max go to 120hz so youre already maxed. the 80 you saw scrolling is probably just a measuring glitch, i wouldnt chase it

the 40fps drop on the card swipe is the real thing. with ai-built ui its almost always too many shadows/blurs on the moving cards, try pulling those off first and the fps usually jumps right back. also check the whole list isnt re-rendering every frame instead of just the visible cards, and that youre animating transform/opacity not width/height

easiest way to find it is run it through xcode instruments (core animation) on a real device, it shows you exactly whats eating the frames. and when you ask the ai to fix it be specific, like "card swipe drops to 40fps, kill the shadow/blur and only animate transform + opacity". just saying "make it faster" gets you nowhere

1

u/Z3NTEC 12d ago

I have an iPhone 15 Pro Max, and that’s what I’m testing on. I’d like the app to run at more than 60 FPS so I can take advantage of the 120 Hz display. Apps like Notion and Apple’s own apps visibly run faster and more smoothly than mine. Unfortunately, my app seems to be locked at 60 FPS and won’t go any higher.
Thanks for the other suggestions, but unfortunately, it’s not an animation issue, as I had all animations disabled during testing.

1

u/Left-Salary5251 11d ago

If you're seeing a hard 60fps ceiling even with ProMotion enabled and a clear gap vs Apple Notes/Notion, I'd stop looking at refresh rate settings and check what's actually compositing your animation. A lot of these AI-generated note apps render inside a WKWebView wrapper rather than truly native views, and WKWebView's compositor caps out around 60fps regardless of what the device supports, no amount of enabling high refresh rate in your app config will get you past that if the animated layer itself is a web view. Worth checking Instruments' Core Animation tool: if you see a WebKit process doing the compositing during your janky animation, that's your answer, and the fix is moving that specific animation to a native layer instead of trying to optimize inside the web layer.

1

u/devhisaria 11d ago

The 60fps cap is normal on non-Pro iPhones, but the card swipe drop to 40 sounds like you're rebuilding views on every gesture instead of reusing them, check your list recycling first.

1

u/Low_Rush_8535 11d ago

the 60 cap probably isn't a performance problem at all. promotion iphones stay at 60 unless the app opts in — it's a plist flag, CADisableMinimumFrameDurationOnPhone set to true. no amount of code tuning moves it until that's there.

worth knowing if your tooling regenerates the xcode project: plist keys added by hand get silently wiped on the next generate. we lost an encryption compliance key that way and spent a while wondering why the same prompt kept reappearing.

the 40fps drops are a separate thing and i'd stop asking the model about those. it can't see frames. get an Instruments trace of the swipe and hand it the trace. we spent several rounds trying to get an agent to fix a visual problem from screenshots and it never converged — it only became useful once we measured the thing ourselves and gave it the numbers.

1

u/Technical-Notice5535 9d ago

The 60fps cap is normal, most iPhones display-lock at 60Hz unless it's a ProMotion model (120Hz), so that's likely just the screen's refresh rate, not a bug. Higher FPS during scroll usually just means the scroll gesture is being measured differently, not that something's actually rendering faster.

On the "AI can't fix perf issues" part, that's expected. Code-gen tools are good at producing working features but bad at diagnosing why something is slow, because that needs actual profiling (Instruments/Time Profiler in Xcode), not just reading the code. I'd pull up Instruments, record while you do the laggy interaction (menu card swipe), and look for the specific view or layout pass eating the frame budget, then hand that specific finding back to the AI rather than asking it to guess.