Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 3 additions & 12 deletions .github/workflows/create_test_patches.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,24 +59,15 @@ jobs:
# yarn3+ by default disables lockfile alteration in CI. We want it.
YARN_ENABLE_IMMUTABLE_INSTALLS: false
run: |
PACKAGE_LIST=`find packages -maxdepth 1 -mindepth 1 -type d -exec basename {} \; | egrep -v 'template|invites'`
mkdir $HOME/packages
for PACKAGE in $PACKAGE_LIST; do
echo "Packing PR version of package $PACKAGE"
pushd packages/$PACKAGE;
yarn pack;
mv package.tgz $HOME/packages/react-native-firebase-${PACKAGE}.tgz;
ls -la $HOME/packages/*${PACKAGE}*
popd;
done
ls -la $HOME/packages/
./.github/workflows/scripts/create_npm_packages.sh ./packages $HOME/packages
cd $HOME
npx @react-native-community/cli init template --skip-install --skip-git-init
cd template
yarn
yarn add patch-package --dev
mkdir patches || true
for PACKAGE in $PACKAGE_LIST; do
PACKED_PACKAGE_LIST=`find $HOME/packages/ -maxdepth 1 -mindepth 1 -type f -exec basename -s .tgz {} \; | cut -d'-' -f4-10 | sort`
for PACKAGE in $PACKED_PACKAGE_LIST; do
echo "Installing package $PACKAGE into fresh template app, then clobbering with PR version"
yarn add @react-native-firebase/$PACKAGE || true
if [ -d node_modules/@react-native-firebase/$PACKAGE ]; then
Expand Down
33 changes: 33 additions & 0 deletions .github/workflows/scripts/create_npm_packages.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/bash

SOURCE_PACKAGE_DIR="$1"
TARGET_PACKAGE_DIR="$2"

echo "Creating local npm packages from source '${SOURCE_PACKAGE_DIR}' in '${TARGET_PACKAGE_DIR}'..."

# Make sure our target directory exists and is clean from previous runs
if ! [ -d "${TARGET_PACKAGE_DIR}" ]; then
mkdir "${TARGET_PACKAGE_DIR}"
else
rm -f "${TARGET_PACKAGE_DIR}"/*.tgz
fi

if ! [ -d "${SOURCE_PACKAGE_DIR}" ]; then
echo "Source package dir '${SOURCE_PACKAGE_DIR} not found."
exit 1;
fi

# Get our full list of packages, except any we specifically ignore
IGNORED_PACKAGE_NAMES='template|invites'
PACKAGE_LIST=`find ${SOURCE_PACKAGE_DIR} -maxdepth 1 -mindepth 1 -type d -exec basename {} \; | egrep -v "${IGNORED_PACKAGE_NAMES}"`

# Pack up each package
for PACKAGE in $PACKAGE_LIST; do
echo "Creating package for $PACKAGE from local source"
pushd "${SOURCE_PACKAGE_DIR}/${PACKAGE}";
yarn pack;
mv package.tgz "${TARGET_PACKAGE_DIR}/react-native-firebase-${PACKAGE}.tgz";
ls -la "${TARGET_PACKAGE_DIR}/react-native-firebase-${PACKAGE}.tgz"
popd;
done
ls -la "${TARGET_PACKAGE_DIR}"
25 changes: 3 additions & 22 deletions packages/ai/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@
"version": "23.8.3",
"author": "Invertase <oss@invertase.io> (http://invertase.io)",
"description": "React Native Firebase - Firebase AI is a fully-managed, unified AI development platform for building and using generative AI",
"main": "./dist/commonjs/index.js",
"module": "./dist/module/index.js",
"types": "./dist/typescript/module/lib/index.d.ts",
"main": "./dist/module/index.js",
"types": "./dist/typescript/lib/index.d.ts",
"scripts": {
"build": "genversion --esm --semi lib/version.ts",
"build:clean": "rimraf dist",
"compile": "bob build",
"compile": "rimraf dist && bob build",
"prepare": "yarn tests:ai:mocks && yarn run build && yarn compile"
},
"repository": {
Expand Down Expand Up @@ -41,18 +40,6 @@
"typescript": "^5.9.3"
},
"source": "./lib/index.ts",
"exports": {
".": {
"import": {
"types": "./dist/typescript/module/lib/index.d.ts",
"default": "./dist/module/index.js"
},
"require": {
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"default": "./dist/commonjs/index.js"
}
}
},
"files": [
"lib",
"dist",
Expand All @@ -64,12 +51,6 @@
"source": "lib",
"output": "dist",
"targets": [
[
"commonjs",
{
"esm": true
}
],
[
"module",
{
Expand Down
14 changes: 7 additions & 7 deletions packages/ai/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,18 @@
"strict": true,
"baseUrl": ".",
"paths": {
"@react-native-firebase/app/lib/common/*": ["../app/dist/typescript/commonjs/lib/common/*"],
"@react-native-firebase/app/lib/common": ["../app/dist/typescript/commonjs/lib/common"],
"@react-native-firebase/app/lib/common/*": ["../app/dist/typescript/lib/common/*"],
"@react-native-firebase/app/lib/common": ["../app/dist/typescript/lib/common"],
"@react-native-firebase/app/lib/internal/web/*": [
"../app/dist/typescript/commonjs/lib/internal/web/*"
"../app/dist/typescript/lib/internal/web/*"
],
"@react-native-firebase/app/lib/internal/*": [
"../app/dist/typescript/commonjs/lib/internal/*"
"../app/dist/typescript/lib/internal/*"
],
"@react-native-firebase/app/lib/internal": ["../app/dist/typescript/commonjs/lib/internal"],
"@react-native-firebase/app": ["../app/dist/typescript/commonjs/lib"],
"@react-native-firebase/app/lib/internal": ["../app/dist/typescript/lib/internal"],
"@react-native-firebase/app": ["../app/dist/typescript/lib"],
"@react-native-firebase/auth": ["../auth/lib"],
"@react-native-firebase/app-check": ["../app-check/dist/typescript/commonjs/lib"]
"@react-native-firebase/app-check": ["../app-check/dist/typescript/lib"]
}
},
"include": ["lib/**/*"],
Expand Down
27 changes: 3 additions & 24 deletions packages/analytics/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@
"version": "23.8.3",
"author": "Invertase <oss@invertase.io> (http://invertase.io)",
"description": "React Native Firebase - The analytics module provides out of the box support with Google Analytics for Firebase. Integration with the Android & iOS allows for in-depth analytical insight reporting, such as device information, location, user actions and more.",
"main": "./dist/commonjs/index.js",
"module": "./dist/module/index.js",
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"main": "./dist/module/index.js",
"types": "./dist/typescript/lib/index.d.ts",
"scripts": {
"build": "genversion --esm --semi lib/version.ts",
"build:clean": "rimraf android/build && rimraf ios/build",
"compile": "bob build",
"compile": "rimraf dist && bob build",
"prepare": "yarn run build && yarn compile"
},
"repository": {
Expand All @@ -36,20 +35,6 @@
"devDependencies": {
"react-native-builder-bob": "^0.40.17"
},
"exports": {
".": {
"source": "./lib/index.ts",
"import": {
"types": "./dist/typescript/module/lib/index.d.ts",
"default": "./dist/module/index.js"
},
"require": {
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"default": "./dist/commonjs/index.js"
}
},
"./package.json": "./package.json"
},
"react-native-builder-bob": {
"source": "lib",
"output": "dist",
Expand All @@ -60,12 +45,6 @@
"esm": true
}
],
[
"commonjs",
{
"esm": true
}
],
[
"typescript",
{
Expand Down
12 changes: 6 additions & 6 deletions packages/analytics/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@
"baseUrl": ".",
"rootDir": ".",
"paths": {
"@react-native-firebase/app/lib/common/*": ["../app/dist/typescript/commonjs/lib/common/*"],
"@react-native-firebase/app/lib/common": ["../app/dist/typescript/commonjs/lib/common"],
"@react-native-firebase/app/lib/common/*": ["../app/dist/typescript/lib/common/*"],
"@react-native-firebase/app/lib/common": ["../app/dist/typescript/lib/common"],
"@react-native-firebase/app/lib/internal/web/*": [
"../app/dist/typescript/commonjs/lib/internal/web/*"
"../app/dist/typescript/lib/internal/web/*"
],
"@react-native-firebase/app/lib/internal/*": [
"../app/dist/typescript/commonjs/lib/internal/*"
"../app/dist/typescript/lib/internal/*"
],
"@react-native-firebase/app/lib/internal": ["../app/dist/typescript/commonjs/lib/internal"],
"@react-native-firebase/app": ["../app/dist/typescript/commonjs/lib"]
"@react-native-firebase/app/lib/internal": ["../app/dist/typescript/lib/internal"],
"@react-native-firebase/app": ["../app/dist/typescript/lib"]
}
},
"include": ["lib/**/*"],
Expand Down
28 changes: 3 additions & 25 deletions packages/app-check/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,14 @@
"version": "23.8.3",
"author": "Invertase <oss@invertase.io> (http://invertase.io)",
"description": "React Native Firebase - App Check",
"main": "./dist/commonjs/index.js",
"module": "./dist/module/index.js",
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"main": "./dist/module/index.js",
"types": "./dist/typescript/lib/index.d.ts",
"scripts": {
"build": "genversion --esm --semi lib/version.ts",
"build:clean": "rimraf android/build && rimraf ios/build",
"build:plugin": "rimraf plugin/build && tsc --build plugin",
"lint:plugin": "eslint plugin/src/*",
"compile": "bob build",
"compile": "rimraf dist && bob build",
"prepare": "yarn run build && yarn compile && yarn run build:plugin"
},
"repository": {
Expand Down Expand Up @@ -44,21 +43,6 @@
"access": "public",
"provenance": true
},
"exports": {
".": {
"source": "./lib/index.ts",
"import": {
"types": "./dist/typescript/module/lib/index.d.ts",
"default": "./dist/module/index.js"
},
"require": {
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"default": "./dist/commonjs/index.js"
}
},
"./app.plugin.js": "./app.plugin.js",
"./package.json": "./package.json"
},
"react-native-builder-bob": {
"source": "lib",
"output": "dist",
Expand All @@ -69,12 +53,6 @@
"esm": true
}
],
[
"commonjs",
{
"esm": true
}
],
[
"typescript",
{
Expand Down
12 changes: 6 additions & 6 deletions packages/app-check/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@
"baseUrl": ".",
"rootDir": ".",
"paths": {
"@react-native-firebase/app/lib/common/*": ["../app/dist/typescript/commonjs/lib/common/*"],
"@react-native-firebase/app/lib/common": ["../app/dist/typescript/commonjs/lib/common"],
"@react-native-firebase/app/lib/common/*": ["../app/dist/typescript/lib/common/*"],
"@react-native-firebase/app/lib/common": ["../app/dist/typescript/lib/common"],
"@react-native-firebase/app/lib/internal/web/*": [
"../app/dist/typescript/commonjs/lib/internal/web/*"
"../app/dist/typescript/lib/internal/web/*"
],
"@react-native-firebase/app/lib/internal/*": [
"../app/dist/typescript/commonjs/lib/internal/*"
"../app/dist/typescript/lib/internal/*"
],
"@react-native-firebase/app/lib/internal": ["../app/dist/typescript/commonjs/lib/internal"],
"@react-native-firebase/app": ["../app/dist/typescript/commonjs/lib"]
"@react-native-firebase/app/lib/internal": ["../app/dist/typescript/lib/internal"],
"@react-native-firebase/app": ["../app/dist/typescript/lib"]
}
},
"include": ["lib/**/*", "../app/lib/internal/global.d.ts"],
Expand Down
72 changes: 3 additions & 69 deletions packages/app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,15 @@
"version": "23.8.3",
"author": "Invertase <oss@invertase.io> (http://invertase.io)",
"description": "A well tested, feature rich Firebase implementation for React Native, supporting iOS & Android. Individual module support for Admob, Analytics, Auth, Crash Reporting, Cloud Firestore, Database, Dynamic Links, Functions, Messaging (FCM), Remote Config, Storage and more.",
"main": "./dist/commonjs/index.js",
"module": "./dist/module/index.js",
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"main": "./dist/module/index.js",
"types": "./dist/typescript/lib/index.d.ts",
"scripts": {
"build": "genversion --esm --semi lib/version.ts && npm run build:version",
"build:version": "node ./scripts/genversion-ios && node ./scripts/genversion-android",
"build:clean": "rimraf android/build && rimraf ios/build",
"build:plugin": "rimraf plugin/build && tsc --build plugin",
"lint:plugin": "eslint plugin/src/*",
"compile": "bob build",
"compile": "rimraf dist && bob build",
"prepare": "npm run build && npm run build:plugin && npm run compile"
},
"repository": {
Expand Down Expand Up @@ -53,65 +52,6 @@
"dynamic-links",
"crashlytics"
],
"exports": {
".": {
"source": "./lib/index.ts",
"import": {
"types": "./dist/typescript/module/lib/index.d.ts",
"default": "./dist/module/index.js"
},
"require": {
"types": "./dist/typescript/commonjs/lib/index.d.ts",
"default": "./dist/commonjs/index.js"
}
},
"./lib/internal": {
"source": "./lib/internal/index.ts",
"import": {
"types": "./dist/typescript/module/lib/internal/index.d.ts",
"default": "./dist/module/internal/index.js"
},
"require": {
"types": "./dist/typescript/commonjs/lib/internal/index.d.ts",
"default": "./dist/commonjs/internal/index.js"
}
},
"./lib/internal/*": {
"source": "./lib/internal/*.ts",
"import": {
"types": "./dist/typescript/module/lib/internal/*.d.ts",
"default": "./dist/module/internal/*"
},
"require": {
"types": "./dist/typescript/commonjs/lib/internal/*.d.ts",
"default": "./dist/commonjs/internal/*"
}
},
"./lib/common": {
"source": "./lib/common/index.ts",
"import": {
"types": "./dist/typescript/module/lib/common/index.d.ts",
"default": "./dist/module/common/index.js"
},
"require": {
"types": "./dist/typescript/commonjs/lib/common/index.d.ts",
"default": "./dist/commonjs/common/index.js"
}
},
"./lib/common/*": {
"source": "./lib/common/*.ts",
"import": {
"types": "./dist/typescript/module/lib/common/*.d.ts",
"default": "./dist/module/common/*"
},
"require": {
"types": "./dist/typescript/commonjs/lib/common/*.d.ts",
"default": "./dist/commonjs/common/*"
}
},
"./app.plugin.js": "./app.plugin.js",
"./package.json": "./package.json"
},
"peerDependencies": {
"expo": ">=47.0.0",
"react": "*",
Expand Down Expand Up @@ -164,12 +104,6 @@
"esm": true
}
],
[
"commonjs",
{
"esm": true
}
],
[
"typescript",
{
Expand Down
Loading
Loading