Skip to content

Commit

Permalink
Merge branch 'v11' into ch-schema
Browse files Browse the repository at this point in the history
  • Loading branch information
hsubox76 committed Sep 23, 2024
2 parents f5f2a48 + 097bd67 commit a10b5a8
Show file tree
Hide file tree
Showing 17 changed files with 43 additions and 117 deletions.
6 changes: 6 additions & 0 deletions .changeset/large-snakes-march.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'firebase': major
'@firebase/vertexai': major
---

Release VertexAI in Firebase for general availability.
6 changes: 6 additions & 0 deletions .changeset/slimy-cups-promise.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@firebase/functions-compat': patch
'@firebase/functions': patch
---

Remove node bundle from the functions SDK as the node-specific fetch code has been removed in favor of using native fetch throughout the SDK.
2 changes: 1 addition & 1 deletion .github/workflows/canary-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
NPM_TOKEN_STORAGE: ${{secrets.NPM_TOKEN_STORAGE}}
NPM_TOKEN_STORAGE_TYPES: ${{secrets.NPM_TOKEN_STORAGE_TYPES}}
NPM_TOKEN_UTIL: ${{secrets.NPM_TOKEN_UTIL}}
NPM_TOKEN_VERTEXAI_PREVIEW: ${{secrets.NPM_TOKEN_VERTEXAI_PREVIEW}}
NPM_TOKEN_VERTEXAI: ${{secrets.NPM_TOKEN_VERTEXAI}}
NPM_TOKEN_WEBCHANNEL_WRAPPER: ${{secrets.NPM_TOKEN_WEBCHANNEL_WRAPPER}}
NPM_TOKEN_FIREBASE: ${{secrets.NPM_TOKEN_FIREBASE}}
NPM_TOKEN_APP_COMPAT: ${{ secrets.NPM_TOKEN_APP_COMPAT }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/prerelease-manual-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ jobs:
NPM_TOKEN_STORAGE: ${{secrets.NPM_TOKEN_STORAGE}}
NPM_TOKEN_STORAGE_TYPES: ${{secrets.NPM_TOKEN_STORAGE_TYPES}}
NPM_TOKEN_UTIL: ${{secrets.NPM_TOKEN_UTIL}}
NPM_TOKEN_VERTEXAI_PREVIEW: ${{secrets.NPM_TOKEN_VERTEXAI_PREVIEW}}
NPM_TOKEN_VERTEXAI: ${{secrets.NPM_TOKEN_VERTEXAI}}
NPM_TOKEN_WEBCHANNEL_WRAPPER: ${{secrets.NPM_TOKEN_WEBCHANNEL_WRAPPER}}
NPM_TOKEN_FIREBASE: ${{secrets.NPM_TOKEN_FIREBASE}}
NPM_TOKEN_APP_COMPAT: ${{ secrets.NPM_TOKEN_APP_COMPAT }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ jobs:
NPM_TOKEN_STORAGE: ${{secrets.NPM_TOKEN_STORAGE}}
NPM_TOKEN_STORAGE_TYPES: ${{secrets.NPM_TOKEN_STORAGE_TYPES}}
NPM_TOKEN_UTIL: ${{secrets.NPM_TOKEN_UTIL}}
NPM_TOKEN_VERTEXAI_PREVIEW: ${{secrets.NPM_TOKEN_VERTEXAI_PREVIEW}}
NPM_TOKEN_VERTEXAI: ${{secrets.NPM_TOKEN_VERTEXAI}}
NPM_TOKEN_WEBCHANNEL_WRAPPER: ${{secrets.NPM_TOKEN_WEBCHANNEL_WRAPPER}}
NPM_TOKEN_FIREBASE: ${{secrets.NPM_TOKEN_FIREBASE}}
NPM_TOKEN_APP_COMPAT: ${{ secrets.NPM_TOKEN_APP_COMPAT }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ jobs:
NPM_TOKEN_STORAGE: ${{secrets.NPM_TOKEN_STORAGE}}
NPM_TOKEN_STORAGE_TYPES: ${{secrets.NPM_TOKEN_STORAGE_TYPES}}
NPM_TOKEN_UTIL: ${{secrets.NPM_TOKEN_UTIL}}
NPM_TOKEN_VERTEXAI_PREVIEW: ${{secrets.NPM_TOKEN_VERTEXAI_PREVIEW}}
NPM_TOKEN_VERTEXAI: ${{secrets.NPM_TOKEN_VERTEXAI}}
NPM_TOKEN_WEBCHANNEL_WRAPPER: ${{secrets.NPM_TOKEN_WEBCHANNEL_WRAPPER}}
NPM_TOKEN_FIREBASE: ${{secrets.NPM_TOKEN_FIREBASE}}
NPM_TOKEN_APP_COMPAT: ${{ secrets.NPM_TOKEN_APP_COMPAT }}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## API Report File for "@firebase/vertexai-preview"
## API Report File for "@firebase/vertexai"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
Expand Down
18 changes: 9 additions & 9 deletions packages/firebase/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -215,17 +215,17 @@
},
"default": "./storage/dist/esm/index.esm.js"
},
"./vertexai-preview": {
"types": "./vertexai-preview/dist/vertexai-preview/index.d.ts",
"./vertexai": {
"types": "./vertexai/dist/vertexai/index.d.ts",
"node": {
"require": "./vertexai-preview/dist/index.cjs.js",
"import": "./vertexai-preview/dist/index.mjs"
"require": "./vertexai/dist/index.cjs.js",
"import": "./vertexai/dist/index.mjs"
},
"browser": {
"require": "./vertexai-preview/dist/index.cjs.js",
"import": "./vertexai-preview/dist/esm/index.esm.js"
"require": "./vertexai/dist/index.cjs.js",
"import": "./vertexai/dist/esm/index.esm.js"
},
"default": "./vertexai-preview/dist/esm/index.esm.js"
"default": "./vertexai/dist/esm/index.esm.js"
},
"./compat/analytics": {
"types": "./compat/analytics/dist/compat/analytics/index.d.ts",
Expand Down Expand Up @@ -413,7 +413,7 @@
"@firebase/app-check": "0.8.8",
"@firebase/app-check-compat": "0.3.15",
"@firebase/util": "1.10.0",
"@firebase/vertexai-preview": "0.0.4"
"@firebase/vertexai": "0.0.4"
},
"devDependencies": {
"rollup": "2.79.1",
Expand Down Expand Up @@ -446,7 +446,7 @@
"messaging",
"messaging/sw",
"database",
"vertexai-preview"
"vertexai"
],
"typings": "empty.d.ts"
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@
* limitations under the License.
*/

export * from '@firebase/vertexai-preview';
export * from '@firebase/vertexai';
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "firebase/vertexai-preview",
"name": "firebase/vertexai",
"main": "dist/index.cjs.js",
"browser": "dist/esm/index.esm.js",
"module": "dist/esm/index.esm.js",
"typings": "dist/vertexai-preview/index.d.ts"
"typings": "dist/vertexai/index.d.ts"
}
8 changes: 4 additions & 4 deletions packages/functions-compat/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"version": "0.3.14",
"description": "",
"author": "Firebase <[email protected]> (https://firebase.google.com/)",
"main": "dist/index.node.cjs.js",
"main": "dist/index.cjs.js",
"browser": "dist/index.esm2017.js",
"module": "dist/index.esm2017.js",
"esm5": "dist/index.esm5.js",
"exports": {
".": {
"types": "./dist/src/index.d.ts",
"node": {
"import": "./dist/node-esm/index.node.esm.js",
"require": "./dist/index.node.cjs.js"
"require": "./dist/index.cjs.js",
"import": "./dist/index.esm2017.js"
},
"esm5": "./dist/index.esm5.js",
"browser": {
Expand Down Expand Up @@ -57,7 +57,7 @@
"test:all": "run-p --npm-path npm test:browser test:node",
"test:browser": "karma start",
"test:browser:debug": "karma start --browsers=Chrome --auto-watch",
"test:node": "TS_NODE_COMPILER_OPTIONS='{\"module\":\"commonjs\"}' nyc --reporter lcovonly -- mocha 'src/{,!(browser)/**/}*.test.ts' --file src/index.node.ts --config ../../config/mocharc.node.js",
"test:node": "TS_NODE_COMPILER_OPTIONS='{\"module\":\"commonjs\"}' nyc --reporter lcovonly -- mocha 'src/{,!(browser)/**/}*.test.ts' --config ../../config/mocharc.node.js",
"test:emulator": "env FIREBASE_FUNCTIONS_HOST=http://localhost FIREBASE_FUNCTIONS_PORT=5005 run-p --npm-path npm test:node",
"trusted-type-check": "tsec -p tsconfig.json --noEmit",
"add-compat-overloads": "ts-node-script ../../scripts/build/create-overloads.ts -i ../functions/dist/functions-public.d.ts -o dist/src/index.d.ts -a -r Functions:types.FirebaseFunctions -r FirebaseApp:FirebaseAppCompat --moduleToEnhance @firebase/functions"
Expand Down
19 changes: 1 addition & 18 deletions packages/functions-compat/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,21 +73,4 @@ const browserBuilds = [
}
];

const nodeBuilds = [
{
input: 'src/index.node.ts',
output: [{ file: pkg.main, format: 'cjs', sourcemap: true }],
plugins: es5BuildPlugins,
external: id => deps.some(dep => id === dep || id.startsWith(`${dep}/`))
},
{
input: 'src/index.node.ts',
output: [
{ file: pkg.exports['.'].node.import, format: 'es', sourcemap: true }
],
plugins: [...es2017BuildPlugins, emitModulePackageFile()],
external: id => deps.some(dep => id === dep || id.startsWith(`${dep}/`))
}
];

export default [...browserBuilds, ...nodeBuilds];
export default [...browserBuilds];
23 changes: 0 additions & 23 deletions packages/functions-compat/src/index.node.ts

This file was deleted.

8 changes: 4 additions & 4 deletions packages/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"version": "0.11.8",
"description": "",
"author": "Firebase <[email protected]> (https://firebase.google.com/)",
"main": "dist/index.node.cjs.js",
"main": "dist/index.cjs.js",
"browser": "dist/index.esm2017.js",
"module": "dist/index.esm2017.js",
"esm5": "dist/index.esm.js",
"exports": {
".": {
"types": "./dist/functions-public.d.ts",
"node": {
"import": "./dist/esm-node/index.node.esm.js",
"require": "./dist/index.node.cjs.js"
"import": "./dist/index.esm2017.js",
"require": "./dist/index.cjs.js"
},
"esm5": "./dist/index.esm.js",
"browser": {
Expand All @@ -38,7 +38,7 @@
"test:all": "run-p --npm-path npm test:browser test:node",
"test:browser": "karma start",
"test:browser:debug": "karma start --browsers=Chrome --auto-watch",
"test:node": "TS_NODE_COMPILER_OPTIONS='{\"module\":\"commonjs\"}' nyc --reporter lcovonly -- mocha 'src/{,!(browser)/**/}*.test.ts' --file src/index.node.ts --config ../../config/mocharc.node.js",
"test:node": "TS_NODE_COMPILER_OPTIONS='{\"module\":\"commonjs\"}' nyc --reporter lcovonly -- mocha 'src/{,!(browser)/**/}*.test.ts' --file src/index.ts --config ../../config/mocharc.node.js",
"test:emulator": "env FIREBASE_FUNCTIONS_EMULATOR_ORIGIN=http://localhost:5005 run-p --npm-path npm test:node",
"trusted-type-check": "tsec -p tsconfig.json --noEmit",
"api-report": "api-extractor run --local --verbose",
Expand Down
26 changes: 1 addition & 25 deletions packages/functions/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,28 +84,4 @@ const browserBuilds = [
}
];

const nodeBuilds = [
{
input: 'src/index.node.ts',
output: [{ file: pkg.main, format: 'cjs', sourcemap: true }],
external: id => deps.some(dep => id === dep || id.startsWith(`${dep}/`)),
plugins: [
...es5BuildPlugins,
replace(generateBuildTargetReplaceConfig('cjs', 5))
]
},
{
input: 'src/index.node.ts',
output: [
{ file: pkg.exports['.'].node.import, format: 'es', sourcemap: true }
],
external: id => deps.some(dep => id === dep || id.startsWith(`${dep}/`)),
plugins: [
...es2017BuildPlugins,
replace(generateBuildTargetReplaceConfig('esm', 2017)),
emitModulePackageFile()
]
}
];

export default [...browserBuilds, ...nodeBuilds];
export default [...browserBuilds];
22 changes: 0 additions & 22 deletions packages/functions/src/index.node.ts

This file was deleted.

8 changes: 4 additions & 4 deletions packages/vertexai/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@firebase/vertexai-preview",
"name": "@firebase/vertexai",
"version": "0.0.4",
"description": "A Firebase SDK for VertexAI (preview)",
"description": "A Firebase SDK for VertexAI",
"author": "Firebase <[email protected]> (https://firebase.google.com/)",
"engines": {
"node": ">=18.0.0"
Expand All @@ -11,7 +11,7 @@
"module": "dist/esm/index.esm2017.js",
"exports": {
".": {
"types": "./dist/vertexai-preview-public.d.ts",
"types": "./dist/vertexai-public.d.ts",
"node": {
"require": "./dist/index.cjs.js",
"import": "./dist/esm/index.esm2017.js"
Expand Down Expand Up @@ -40,7 +40,7 @@
"test:skip-clone": "karma start",
"test:browser": "yarn testsetup && karma start",
"api-report": "api-extractor run --local --verbose",
"typings:public": "node ../../scripts/build/use_typings.js ./dist/vertexai-preview-public.d.ts",
"typings:public": "node ../../scripts/build/use_typings.js ./dist/vertexai-public.d.ts",
"trusted-type-check": "tsec -p tsconfig.json --noEmit"
},
"peerDependencies": {
Expand Down

0 comments on commit a10b5a8

Please sign in to comment.