Align Flow lib defs for Node.js v8 module with v24 #55225
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.
Summary:
This is an AI-assisted change to align the Flow definitions for the
v8module with the Node.js docs as at v24.New v18+ Features:
Heap Snapshot Near Limit (v18.10.0) - Automatic snapshot generation
setHeapSnapshotNearHeapLimit(limit: number): voidfunctionGCProfiler Class (v19.6.0, v18.15.0) - Garbage collection profiling
GCProfilerclass for detailed GC statistics collectionstart()method begins profiling sessionstop()method returnsGCProfilerResultwith detailed statisticsNew v20+ Features:
queryObjects(ctor, options?)function with two overloads'count'(returns number) or'summary'(returns string array)New v22+ Features:
C++ Heap Statistics (v22.15.0) - cppgc heap monitoring
getCppHeapStatistics(detailLevel?)function'brief'(top-level stats) or'detailed'(includes space/page breakdown)String Representation Check (v23.10.0, backported to v22.15.0)
isStringOneByteRepresentation(content: string): booleanfunctionType System Improvements:
Complete Type Definitions - Added missing fields and proper types:
DoesZapCodeSpaceFlagtype alias (0 | 1) fordoes_zap_garbageHeapCodeStatistics- Addedcpu_profiler_metadata_sizefieldHeapInfo(renamed fromHeapStatistics) - Added 3 missing fields:total_global_handles_size(v13.3.0)used_global_handles_size(v13.3.0)external_memory(v13.3.0)HeapSpaceInfo(renamed fromHeapSpaceStatistics) - Removed spread operatorHeapSnapshotOptions(new) - Options for heap snapshot generation:exposeInternals?: boolean- Expose internals in snapshotexposeNumericValues?: boolean- Expose numeric valuesHeapStatistics(camelCase) - For GCProfiler, complete with all 11 fieldsHeapSpaceStatistics(camelCase) - For GCProfiler, complete with all 5 fieldsGCProfilerResult- Complete result type with version, timing, and statistics arrayEnhanced Function Signatures:
getHeapSnapshot(options?)- Added optionalHeapSnapshotOptionsparameterwriteHeapSnapshot(fileName?, options?)- Added optionalHeapSnapshotOptionsparametergetHeapStatistics()- Changed return type fromHeapStatisticstoHeapInfogetHeapSpaceStatistics()- Changed return type toArray<HeapSpaceInfo>Coverage Functions - For type profile analysis:
takeCoverage(): void(v15.1.0) - Starts capturing V8 type profilestopCoverage(): void(v15.1.0) - Stops capturing V8 type profileSerialization Documentation:
since v8.0.0tags to all serialization classes and functionsSerializer,Deserializer,DefaultSerializer,DefaultDeserializerReferences:
Changelog: [Internal]
Differential Revision: D90762740