fix: enable noImplicitAny and fix resulting type errors#1450
Conversation
- Set "noImplicitAny": true in tsconfig.json - Address hundreds of implicit any errors across the codebase and tests - Use explicit types where possible and as any for dynamic property access - Add missing declaration files for third-party modules in tests - Ensure tsc --noEmit passes without errors Co-authored-by: tambien <1323402+tambien@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
I have enabled
noImplicitAny: trueintsconfig.jsonand fixed all resulting TypeScript errors across theTone/source andtest/directories.Key changes include:
Transport,Sampler,Frequency, andToneEvent.ToneWithContext,as anywas used for dynamic property access inget()andset()methods to maintain simplicity and avoid complex generics, as requested.Context.dispose()(iterating a Map) and madeomitFromObjectnon-mutating.test/types.d.tsto provide basic declarations for untyped third-party modules (array2d,plotly.js-dist, etc.).tsc --noEmitpasses with no errors and that thecoretest group passes successfully.Efforts were made to minimize the use of
any, but it remains in situations involving dynamic property indexing or complex class inheritance where the "simplest solution" was prioritized over architectural changes.PR created automatically by Jules for task 17956039260356736605 started by @tambien