Skip to content

Commit effc1bd

Browse files
committed
Clean up compat docgen script
1 parent aac4880 commit effc1bd

File tree

17 files changed

+54
-352
lines changed

17 files changed

+54
-352
lines changed

package.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,7 @@
3939
"test:setup": "node tools/config.js",
4040
"test:saucelabs": "node scripts/run_saucelabs.js",
4141
"docgen": "ts-node-script scripts/docgen/docgen.ts",
42-
"docgen:compat": "yarn docgen:compat:js; yarn docgen:compat:node",
43-
"docgen:compat:js": "node scripts/docgen-compat/generate-docs.js --api js",
44-
"docgen:compat:node": "node scripts/docgen-compat/generate-docs.js --api node",
42+
"docgen:compat": "node scripts/docgen-compat/generate-docs.js --api js",
4543
"lint": "lerna run --scope @firebase/* lint",
4644
"lint:fix": "lerna run --scope @firebase/* lint:fix",
4745
"size-report": "ts-node-script scripts/size_report/report_binary_size.ts",

packages/app-check/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* The Firebase App Check Web SDK.
3-
*
3+
*
44
* @remarks
55
* Firebase App Check does not work in Node.js using `ReCaptchaV3Provider` or
66
* `ReCaptchaEnterpriseProvider`, but can be used in Node.js if you use

packages/auth/src/model/public_types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ export interface Auth {
193193
* This makes it easy for a user signing in to specify whether their session should be
194194
* remembered or not. It also makes it easier to never persist the Auth state for applications
195195
* that are shared by other users or have sensitive data.
196-
*
196+
*
197197
* This method has no effect in Node.js.
198198
*
199199
* @example

packages/auth/src/platform_browser/mfa/assertions/phone.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ export class PhoneMultiFactorGenerator {
8383

8484
/**
8585
* Provides a {@link PhoneMultiFactorAssertion} to confirm ownership of the phone second factor.
86-
*
86+
*
8787
* @remarks
8888
* This method is not available in Node.js.
8989
*

packages/auth/src/platform_browser/popup_redirect.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ class BrowserPopupRedirectResolver implements PopupRedirectResolverInternal {
189189
/**
190190
* An implementation of {@link PopupRedirectResolver} suitable for browser
191191
* based applications.
192-
*
192+
*
193193
* @remarks
194194
* This method is not available in Node.js.
195195
*

packages/auth/src/platform_browser/providers/phone.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ import { ProviderId, SignInMethod } from '../../model/enums';
5050
* const phoneCredential = PhoneAuthProvider.credential(verificationId, verificationCode);
5151
* const userCredential = await signInWithCredential(auth, phoneCredential);
5252
* ```
53-
*
53+
*
5454
* @public
5555
*/
5656
export class PhoneAuthProvider {

packages/auth/src/platform_browser/recaptcha/recaptcha_verifier.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ type TokenCallback = (token: string) => void;
4343

4444
/**
4545
* An {@link https://www.google.com/recaptcha/ | reCAPTCHA}-based application verifier.
46-
*
46+
*
4747
* @remarks
4848
* `RecaptchaVerifier` is not available in Node.js.
4949
*

packages/auth/src/platform_browser/strategies/phone.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ class ConfirmationResultImpl implements ConfirmationResult {
8181
* This function can work on other platforms that do not support the
8282
* {@link RecaptchaVerifier} (like React Native), but you need to use a
8383
* third-party {@link ApplicationVerifier} implementation.
84-
*
84+
*
8585
* This method is not available in Node.js.
8686
*
8787
* @example
@@ -117,7 +117,7 @@ export async function signInWithPhoneNumber(
117117

118118
/**
119119
* Links the user account with the given phone number.
120-
*
120+
*
121121
* @remarks
122122
* This method is not available in Node.js.
123123
*
@@ -149,7 +149,7 @@ export async function linkWithPhoneNumber(
149149
*
150150
* @remarks
151151
* Use before operations such as {@link updatePassword} that require tokens from recent sign-in attempts.
152-
*
152+
*
153153
* This method is not available in Node.js.
154154
*
155155
* @param user - The user.
@@ -257,7 +257,7 @@ export async function _verifyPhoneNumber(
257257

258258
/**
259259
* Updates the user's phone number.
260-
*
260+
*
261261
* @remarks
262262
* This method is not available in Node.js.
263263
*

packages/auth/src/platform_browser/strategies/popup.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export const _POLL_WINDOW_CLOSE_TIMEOUT = new Delay(2000, 10000);
6262
* @remarks
6363
* If succeeds, returns the signed in user along with the provider's credential. If sign in was
6464
* unsuccessful, returns an error object containing additional information about the error.
65-
*
65+
*
6666
* This method is not available in Node.js.
6767
*
6868
* @example
@@ -110,7 +110,7 @@ export async function signInWithPopup(
110110
* @remarks
111111
* If the reauthentication is successful, the returned result will contain the user and the
112112
* provider's credential.
113-
*
113+
*
114114
* This method is not available in Node.js.
115115
*
116116
* @example
@@ -153,7 +153,7 @@ export async function reauthenticateWithPopup(
153153
*
154154
* @remarks
155155
* If the linking is successful, the returned result will contain the user and the provider's credential.
156-
*
156+
*
157157
* This method is not available in Node.js.
158158
*
159159
* @example

packages/auth/src/platform_browser/strategies/redirect.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ import { getModularInstance } from '@firebase/util';
4444
* To handle the results and errors for this operation, refer to {@link getRedirectResult}.
4545
* Follow the {@link https://firebase.google.com/docs/auth/web/redirect-best-practices
4646
* | best practices} when using {@link signInWithRedirect}.
47-
*
47+
*
4848
* This method is not available in Node.js.
4949
*
5050
* @example
@@ -115,7 +115,7 @@ export async function _signInWithRedirect(
115115
* To handle the results and errors for this operation, refer to {@link getRedirectResult}.
116116
* Follow the {@link https://firebase.google.com/docs/auth/web/redirect-best-practices
117117
* | best practices} when using {@link reauthenticateWithRedirect}.
118-
*
118+
*
119119
* This method is not available in Node.js.
120120
*
121121
* @example
@@ -246,7 +246,7 @@ export async function _linkWithRedirect(
246246
* @remarks
247247
* If sign-in succeeded, returns the signed in user. If sign-in was unsuccessful, fails with an
248248
* error. If no redirect operation was called, returns `null`.
249-
*
249+
*
250250
* This method is not available in Node.js.
251251
*
252252
* @example

packages/firebase/compat/index.d.ts

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -8047,30 +8047,6 @@ declare namespace firebase.storage {
80478047
UNSUPPORTED_ENVIRONMENT = 'unsupported-environment'
80488048
}
80498049

8050-
/**
8051-
* An error returned by the Firebase Storage SDK.
8052-
*/
8053-
export interface FirebaseStorageError extends FirebaseError {
8054-
/**
8055-
* Stores custom error data unique to the `StorageError`.
8056-
*/
8057-
customData: {
8058-
serverResponse: string | null;
8059-
};
8060-
8061-
get status(): number;
8062-
set status(status: number);
8063-
/**
8064-
* Compares a `StorageErrorCode` against this error's code, filtering out the prefix.
8065-
*/
8066-
_codeEquals(code: StorageErrorCode): boolean;
8067-
/**
8068-
* Optional response message that was added by the server.
8069-
*/
8070-
get serverResponse(): null | string;
8071-
set serverResponse(serverResponse: string | null);
8072-
}
8073-
80748050
interface StorageObserver<T> {
80758051
next?: NextFn<T> | null;
80768052
error?: (error: FirebaseStorageError) => void | null;
@@ -8268,6 +8244,30 @@ declare namespace firebase.storage {
82688244
*/
82698245
totalBytes: number;
82708246
}
8247+
8248+
/**
8249+
* An error returned by the Firebase Storage SDK.
8250+
*/
8251+
export interface FirebaseStorageError extends FirebaseError {
8252+
/**
8253+
* Stores custom error data unique to the `StorageError`.
8254+
*/
8255+
customData: {
8256+
serverResponse: string | null;
8257+
};
8258+
8259+
get status(): number;
8260+
set status(status: number);
8261+
/**
8262+
* Compares a `StorageErrorCode` against this error's code, filtering out the prefix.
8263+
*/
8264+
_codeEquals(code: StorageErrorCode): boolean;
8265+
/**
8266+
* Optional response message that was added by the server.
8267+
*/
8268+
get serverResponse(): null | string;
8269+
set serverResponse(serverResponse: string | null);
8270+
}
82718271
}
82728272

82738273
declare namespace firebase.firestore {

packages/firestore/src/api/settings.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ export interface FirestoreSettings extends LiteSettings {
8181
* may be removed in a future release. If you find yourself using it to
8282
* work around a specific network reliability issue, please tell us about
8383
* it in https://github.com/firebase/firebase-js-sdk/issues/1674.
84-
*
84+
*
8585
* This setting cannot be used in a Node.js environment.
8686
*/
8787
experimentalForceLongPolling?: boolean;
@@ -93,7 +93,7 @@ export interface FirestoreSettings extends LiteSettings {
9393
*
9494
* This setting will likely be enabled by default in future releases and
9595
* cannot be combined with `experimentalForceLongPolling`.
96-
*
96+
*
9797
* This setting cannot be used in a Node.js environment.
9898
*/
9999
experimentalAutoDetectLongPolling?: boolean;

scripts/docgen-compat/content-sources/js/toc.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,8 @@ toc:
282282
path: /docs/reference/js/v8/firebase.storage.SettableMetadata
283283
- title: "Storage"
284284
path: /docs/reference/js/v8/firebase.storage.Storage
285+
- title: "StorageErrorCode"
286+
path: /docs/reference/js/v8/firebase.storage.StorageErrorCode
285287
- title: "StorageObserver"
286288
path: /docs/reference/js/v8/firebase.storage.StorageObserver
287289
- title: "UploadMetadata"

scripts/docgen-compat/content-sources/node/HOME.md

Lines changed: 0 additions & 11 deletions
This file was deleted.

0 commit comments

Comments
 (0)