Transform $ReadOnly to Readonly 38/n (#55067)

Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/55067

Differential Revision: D90146229

fbshipit-source-id: 62733ba51fd0c318140b7a76b499b1a7ac1f7853
This commit is contained in:
Marco Wang authored and meta-codesync[bot] committed 2026-01-06 20:23:03 -08:00
1 parent 1cc30dc1ad
commit 41efc3b588
156 files changed
+344 -344

No files matched your search

+3 -3
View File
@@ -12,7 +12,7 @@ import type {BabelCoreOptions} from '@babel/core';
const {ModuleResolutionKind} = require('typescript');
export type BuildOptions = $ReadOnly<{
export type BuildOptions = Readonly<{
// The target runtime to compile for.
target: 'node',
@@ -23,9 +23,9 @@ export type BuildOptions = $ReadOnly<{
emitTypeScriptDefs?: boolean,
}>;
export type BuildConfig = $ReadOnly<{
export type BuildConfig = Readonly<{
// The packages to include for build and their build options.
packages: $ReadOnly<{[packageName: string]: BuildOptions}>,
packages: Readonly<{[packageName: string]: BuildOptions}>,
}>;
/**
@@ -48,7 +48,7 @@ const postTransforms = (
),
];
type BuildApiSnapshotOptions = $ReadOnly<{
type BuildApiSnapshotOptions = Readonly<{
validate: boolean,
debugVersionAnnotations: boolean,
}>;
@@ -13,7 +13,7 @@ const {getPackages} = require('../../../shared/monorepoUtils');
const {existsSync} = require('fs');
const path = require('path');
export type DependencyContext = $ReadOnly<{
export type DependencyContext = Readonly<{
reportUnresolvedDependency(importPath: string): void,
}>;
+4 -4
View File
@@ -13,9 +13,9 @@
// An interface shaped like a subset of the Octokit class from `@octokit/rest`.
// Used to allow mocking in tests.
export interface IOctokit {
+repos: $ReadOnly<{
+repos: Readonly<{
listReleaseAssets: (
params: $ReadOnly<{
params: Readonly<{
owner: string,
repo: string,
release_id: string,
@@ -29,13 +29,13 @@ export interface IOctokit {
...
}>,
uploadReleaseAsset: (
params: $ReadOnly<{
params: Readonly<{
owner: string,
repo: string,
release_id: string,
name: string,
data: Buffer,
headers: $ReadOnly<{
headers: Readonly<{
'content-type': string,
...
}>,