Skip to content

Commit 888da3d

Browse files
committed
chore: enable esModuleInterop
- Enable esModuleInterop in tsconfig.release.json for better CJS/ESM interop. - Update unit tests and source code to use default imports for CJS modules (fs, nock, jsonwebtoken, etc.) to align with new compiler settings.
1 parent afe2f71 commit 888da3d

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

mocha/setup.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,8 @@ import chaiAsPromised from "chai-as-promised";
33
import nock from "nock";
44

55
chai.use(chaiAsPromised);
6+
<<<<<<< HEAD
67
nock.disableNetConnect();
8+
=======
9+
nock.disableNetConnect();
10+
>>>>>>> f054321 (chore: enable esModuleInterop)

src/bin/firebase-functions.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,11 @@
2424

2525
import * as http from "http";
2626
import express from "express";
27+
<<<<<<< HEAD
2728
import fs from "fs/promises";
29+
=======
30+
import * as fs from "fs/promises";
31+
>>>>>>> f054321 (chore: enable esModuleInterop)
2832
import * as path from "path";
2933
import { loadStack } from "../runtime/loader";
3034
import { stackToWire } from "../runtime/manifest";

src/v2/providers/https.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ import * as options from "../options";
4848
import { withInit } from "../../common/onInit";
4949
import * as logger from "../../logger";
5050

51-
export { Request, CallableRequest, CallableResponse, FunctionsErrorCode, HttpsError };
51+
export { HttpsError };
52+
export type { Request, CallableRequest, CallableResponse, FunctionsErrorCode };
5253

5354
/**
5455
* Options that can be set on an onRequest HTTPS function.

0 commit comments

Comments
 (0)