chore: update core api#597
Conversation
|
commit: |
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the core API to use a consistent options object pattern across many functions, replacing multiple positional parameters with a single options object. The changes update function signatures and usages for variable declarations, object property handlers, import/export utilities, function calls, and array operations across the codebase and its tests, as well as align the addon integrations with the new API.
Reviewed Changes
Copilot reviewed 59 out of 63 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| packages/core/tooling/js/variables.ts | Refactored variable declaration and identifier creation functions to accept an options object. |
| packages/core/tooling/js/object.ts | Updated object property and override functions with options objects. |
| packages/core/tooling/js/kit.ts | Modified global interface and hooks functions to use the new options-based API. |
| packages/core/tooling/js/imports.ts | Consolidated import functions to accept options objects instead of discrete parameters. |
| packages/core/tooling/js/function.ts | Renamed and refactored call and arrow function helpers (to createCall/createArrow) with options. |
| packages/core/tooling/js/exports.ts | Updated export creation functions to match the options object pattern. |
| packages/core/tooling/js/common.ts | Revised utility helper functions for parsing and comment additions to align with the new API. |
| packages/core/tooling/js/array.ts | Replaced push/unshift with append/prepend functions using an options parameter. |
| Various test files and addon integrations | Adjusted tests and addon code to invoke the updated core API functions. |
Relates #24
Relates #85
Closes #557