diff --git a/.eslintrc.js b/.eslintrc.js
deleted file mode 100644
index 27201978..00000000
--- a/.eslintrc.js
+++ /dev/null
@@ -1,2 +0,0 @@
-// @generated by expo-module-scripts
-module.exports = require('expo-module-scripts/eslintrc.base.js');
diff --git a/.gitattributes b/.gitattributes
deleted file mode 100644
index 030ef144..00000000
--- a/.gitattributes
+++ /dev/null
@@ -1,3 +0,0 @@
-*.pbxproj -text
-# specific for windows script files
-*.bat text eol=crlf
\ No newline at end of file
diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml
deleted file mode 100644
index 4b221450..00000000
--- a/.github/actions/setup/action.yml
+++ /dev/null
@@ -1,19 +0,0 @@
-name: Setup
-description: Setup Node.js and install dependencies
-
-runs:
- using: composite
- steps:
- - name: Setup Node.js
- uses: actions/setup-node@v4
- with:
- node-version-file: .nvmrc
- cache: 'yarn'
-
- - name: Install dependencies
- run: yarn install --immutable
- shell: bash
-
- - name: Prepare project checkout
- run: yarn prepare
- shell: bash
diff --git a/.github/workflows/check-updates.yml b/.github/workflows/check-updates.yml
deleted file mode 100644
index dee11ac6..00000000
--- a/.github/workflows/check-updates.yml
+++ /dev/null
@@ -1,60 +0,0 @@
-name: Check for a new client version
-on:
- schedule:
- - cron: '*/5 * * * *'
- workflow_dispatch:
-
-jobs:
- skip-duplicates:
- name: Skip update if job is already in progress
- runs-on: ubuntu-latest
- outputs:
- should-skip: ${{ steps.skip-check.outputs.should_skip }}
- steps:
- - id: skip-check
- uses: fkirc/skip-duplicate-actions@v5
- with:
- do_not_skip: '[]'
- skip_after_successful_duplicate: 'false'
- concurrent_skipping: 'always'
-
- check-update:
- runs-on: ubuntu-latest
- needs: skip-duplicates
- if: ${{ needs.skip-duplicates.outputs.should-skip != 'true' }}
- outputs:
- latest: ${{ steps.check-update.outputs.latest }}
- dev: ${{ steps.check-update.outputs.dev }}
- integration: ${{ steps.check-update.outputs.dev }}
- steps:
- - name: Checkout
- uses: actions/checkout@v4
-
- - name: Setup
- uses: ./.github/actions/setup
-
- - name: Check for updates
- id: check-update
- run: yarn check-updates
-
- update-latest:
- name: Update latest tag
- needs:
- - check-update
- if: ${{ needs.check-update.outputs.latest != ''}}
- uses: ./.github/workflows/update-and-publish.yml
- secrets: inherit
- with:
- npmTag: latest
- version: ${{ needs.check-update.outputs.latest }}
-
- update-dev:
- name: Update dev tag
- needs:
- - check-update
- if: ${{ needs.check-update.outputs.dev != ''}}
- uses: ./.github/workflows/update-and-publish.yml
- secrets: inherit
- with:
- npmTag: dev
- version: ${{ needs.check-update.outputs.dev }}
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index e6b9aa47..04f0244a 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -1,18 +1,17 @@
name: CI
-on:
- push:
- branches:
- - main
- pull_request:
- branches:
- - main
-concurrency:
- group: ci-${{ github.workflow }}-${{ github.ref }}
- cancel-in-progress: true
+on: [push, pull_request]
jobs:
- test:
- name: Run test
- uses: ./.github/workflows/test.yml
- secrets: inherit
+ build:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ - uses: actions/setup-node@v4
+ with:
+ node-version: 22
+ cache: yarn
+ - run: corepack enable
+ - run: yarn install --immutable
+ - run: yarn typecheck
+ - run: yarn prepare
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
deleted file mode 100644
index 26eaec1b..00000000
--- a/.github/workflows/test.yml
+++ /dev/null
@@ -1,108 +0,0 @@
-name: Test
-on:
- workflow_call:
- inputs:
- ref:
- description: Ref to run the tests on
- type: string
- required: false
-
-jobs:
- lint-test:
- name: Lint
- runs-on: ubuntu-latest
- steps:
- - name: Checkout
- uses: actions/checkout@v4
- with:
- ref: ${{ inputs.ref }}
-
- - name: Setup
- uses: ./.github/actions/setup
-
- - name: Lint files
- run: yarn lint
-
- - name: Typecheck files
- run: yarn typecheck
-
- test-ios:
- name: E2E test for iOS
- runs-on: macos-14
- steps:
- - name: Checkout
- uses: actions/checkout@v4
- with:
- ref: ${{ inputs.ref }}
-
- - name: Setup
- uses: ./.github/actions/setup
-
- - name: Install macOS dependencies
- run: |
- brew tap wix/brew
- brew install applesimutils
- env:
- HOMEBREW_NO_AUTO_UPDATE: 1
- HOMEBREW_NO_INSTALL_CLEANUP: 1
- - name: Install CocoaPods dependecies
- working-directory: example
- run: yarn pod-install
-
- - name: Detox build
- working-directory: example
- run: yarn detox build --configuration ios.sim.release
-
- - name: Detox test
- working-directory: example
- run: yarn detox test --configuration ios.sim.release --cleanup --headless
-
- test-android:
- name: E2E test for Android
- runs-on: ubuntu-latest
- steps:
- # default runner has not enough space for creating emulators
- - name: Free disk space
- uses: jlumbroso/free-disk-space@v1.3.1
- with:
- android: false
- tool-cache: true
- dotnet: true
- haskell: true
- swap-storage: true
- docker-images: true
- large-packages: false
-
- - name: Checkout
- uses: actions/checkout@v4
- with:
- ref: ${{ inputs.ref }}
-
- - name: Setup Java
- uses: actions/setup-java@v3
- with:
- cache: gradle
- distribution: temurin
- java-version: 17
-
- - name: Setup
- uses: ./.github/actions/setup
-
- - name: Detox build
- working-directory: example
- run: yarn detox build --configuration android.emu.release
-
- - name: Enable KVM group perms # make android simulator use KVM and run much faster
- run: |
- echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
- sudo udevadm control --reload-rules
- sudo udevadm trigger --name-match=kvm
-
- - name: Detox test
- uses: reactivecircus/android-emulator-runner@v2
- with:
- working-directory: example
- api-level: 28
- arch: x86_64
- avd-name: Pixel_API_28
- script: yarn detox test --configuration android.emu.release --headless
diff --git a/.github/workflows/update-and-publish.yml b/.github/workflows/update-and-publish.yml
deleted file mode 100644
index 57225e21..00000000
--- a/.github/workflows/update-and-publish.yml
+++ /dev/null
@@ -1,139 +0,0 @@
-name: Update prisma client and publish the package
-on:
- workflow_call:
- inputs:
- npmTag:
- description: npm tag to publish to
- type: string
- required: true
- version:
- description: npm version to publish
- type: string
- required: true
- secrets:
- SLACK_WEBHOOK_URL:
- required: true
- NPM_TOKEN:
- required: true
- workflow_dispatch:
- inputs:
- npmTag:
- description: npm tag to publish to
- type: string
- required: true
- version:
- description: npm version to publish
- type: string
- required: true
-
-concurrency:
- group: publish
-
-jobs:
- update:
- name: Update client & engines on a temporary branch
- runs-on: ubuntu-latest
- env:
- TMP_BRANCH_NAME: tmp/release-${{ inputs.npmTag }}-${{ inputs.version }}
- NPM_TAG: ${{ inputs.npmTag }}
- NPM_VERSION: ${{ inputs.version }}
- outputs:
- tmpBranch: ${{ steps.do-update.outputs.tmpBranch }}
- steps:
- - name: Checkout
- uses: actions/checkout@v4
- with:
- token: ${{ secrets.PRISMA_BOT_TOKEN }}
-
- - name: Setup
- uses: ./.github/actions/setup
-
- - name: Update version in temporary branch
- id: do-update
- run: |
- git checkout -b "$TMP_BRANCH_NAME"
- yarn bump-client "$NPM_TAG" "$NPM_VERSION"
- git config user.email prismabots@gmail.com
- git config user.name Prismo
- git commit -am "chore(deps): Update prisma to $NPM_VERSION on $NPM_TAG"
- git push origin "$TMP_BRANCH_NAME"
- echo "tmpBranch=$TMP_BRANCH_NAME" >> "$GITHUB_OUTPUT"
-
- test:
- name: Test release branch
- needs:
- - update
- uses: ./.github/workflows/test.yml
- with:
- ref: ${{ needs.update.outputs.tmpBranch }}
- secrets: inherit
-
- publish:
- name: Merge temp branch back and publish
- runs-on: ubuntu-latest
- needs:
- - update
- - test
- steps:
- - name: Checkout
- uses: actions/checkout@v4
- with:
- token: ${{ secrets.PRISMA_BOT_TOKEN }}
-
- - name: Merge temp release branch back into main
- env:
- TMP_BRANCH_NAME: ${{ needs.update.outputs.tmpBranch }}
- run: |
- git fetch origin "$TMP_BRANCH_NAME"
- git merge --ff-only "origin/$TMP_BRANCH_NAME"
-
- - name: Setup
- uses: ./.github/actions/setup
-
- - name: Publish
- env:
- NPM_TAG: ${{ inputs.npmTag }}
- NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- run: yarn npm publish --tag "$NPM_TAG"
-
- - name: Push
- run: git push origin main
-
- notify-on-failure:
- name: Notify on publish failure
- needs:
- - update
- - test
- - publish
- if: ${{ always() && contains(needs.*.result, 'failure') }}
-
- runs-on: ubuntu-latest
- steps:
- - name: Set current job url in SLACK_FOOTER env var
- run: echo "SLACK_FOOTER=<$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID|Click here to go to the job logs>" >> $GITHUB_ENV
-
- - name: Slack Notification on Failure
- uses: rtCamp/action-slack-notify@v2.3.0
- env:
- SLACK_TITLE: 'React Native publish failed'
- SLACK_COLOR: '#FF0000'
- SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}
- SLACK_CHANNEL: feed-react-native-publish-failures
-
- finalize:
- name: Cleanup
- runs-on: ubuntu-latest
- needs:
- - update
- - test
- - publish
- if: always()
- steps:
- - name: Checkout
- uses: actions/checkout@v4
-
- - name: Remove temporary branch
- env:
- TMP_BRANCH_NAME: ${{ needs.update.outputs.tmpBranch }}
- run: |
- git push --delete origin "$TMP_BRANCH_NAME"
diff --git a/.gitignore b/.gitignore
index 0c25a906..640e8bb0 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,85 +1,9 @@
-# OSX
-#
.DS_Store
-
-# XDE
-.expo/
-
-# VSCode
.vscode/
jsconfig.json
-
-# Xcode
-#
-build/
-*.pbxuser
-!default.pbxuser
-*.mode1v3
-!default.mode1v3
-*.mode2v3
-!default.mode2v3
-*.perspectivev3
-!default.perspectivev3
-xcuserdata
-*.xccheckout
-*.moved-aside
-DerivedData
-*.hmap
-*.ipa
-*.xcuserstate
-project.xcworkspace
-
-# Android/IJ
-#
-.classpath
-.cxx
-.gradle
-.idea
-.project
-.settings
-local.properties
-android.iml
-
-# Cocoapods
-#
-example/ios/Pods
-
-# Ruby
-example/vendor/
-
-# node.js
-#
node_modules/
-npm-debug.log
-yarn-debug.log
-yarn-error.log
-
-# BUCK
-buck-out/
-\.buckd/
-android/app/libs
-android/keystores/debug.keystore
-
-# Yarn
+lib/
+/native/query-compiler/target/
+/native/PrismaQueryCompiler.xcframework/
.yarn/*
-!.yarn/patches
-!.yarn/plugins
!.yarn/releases
-!.yarn/sdks
-!.yarn/versions
-
-# Expo
-.expo/
-
-# Turborepo
-.turbo/
-
-# generated by bob
-lib/
-
-# config plugin output
-!plugin/build
-
-# development client
-example/client/*
-engines
\ No newline at end of file
diff --git a/.nvmrc b/.nvmrc
deleted file mode 100644
index fb3e6603..00000000
--- a/.nvmrc
+++ /dev/null
@@ -1 +0,0 @@
-v18.20.2
diff --git a/.ruby-version b/.ruby-version
deleted file mode 100644
index ef538c28..00000000
--- a/.ruby-version
+++ /dev/null
@@ -1 +0,0 @@
-3.1.2
diff --git a/.versions/engine b/.versions/engine
deleted file mode 100644
index 1e221af8..00000000
--- a/.versions/engine
+++ /dev/null
@@ -1 +0,0 @@
-c74f8976aaa3212c16a61537319f9024d0c21e85
\ No newline at end of file
diff --git a/.versions/prisma-dev b/.versions/prisma-dev
deleted file mode 100644
index 04153423..00000000
--- a/.versions/prisma-dev
+++ /dev/null
@@ -1 +0,0 @@
-6.1.0-dev.17
\ No newline at end of file
diff --git a/.versions/prisma-latest b/.versions/prisma-latest
deleted file mode 100644
index 5fe60723..00000000
--- a/.versions/prisma-latest
+++ /dev/null
@@ -1 +0,0 @@
-6.0.1
diff --git a/.watchmanconfig b/.watchmanconfig
deleted file mode 100644
index 0967ef42..00000000
--- a/.watchmanconfig
+++ /dev/null
@@ -1 +0,0 @@
-{}
diff --git a/.yarnrc.yml b/.yarnrc.yml
index eed42233..bd0044b7 100644
--- a/.yarnrc.yml
+++ b/.yarnrc.yml
@@ -1,11 +1,2 @@
-compressionLevel: mixed
-
-enableGlobalCache: false
-
-nmHoistingLimits: workspaces
-
nodeLinker: node-modules
-
-npmAuthToken: ${NODE_AUTH_TOKEN-}
-
yarnPath: .yarn/releases/yarn-4.1.1.cjs
diff --git a/PrismaReactNative.podspec b/PrismaReactNative.podspec
new file mode 100644
index 00000000..1ac9fc8e
--- /dev/null
+++ b/PrismaReactNative.podspec
@@ -0,0 +1,19 @@
+require "json"
+
+package = JSON.parse(File.read(File.join(__dir__, "package.json")))
+
+Pod::Spec.new do |s|
+ s.name = "PrismaReactNative"
+ s.version = package["version"]
+ s.summary = package["description"]
+ s.homepage = package["homepage"]
+ s.license = package["license"]
+ s.author = package["author"]
+ s.source = { git: package["repository"]["url"] }
+ s.platforms = { ios: "16.4" }
+ s.static_framework = true
+ s.dependency "ExpoModulesCore"
+ s.source_files = "ios/**/*.{h,m,mm,swift}", "native/include/*.h"
+ s.public_header_files = "native/include/*.h"
+ s.vendored_frameworks = "native/PrismaQueryCompiler.xcframework"
+end
diff --git a/README.md b/README.md
index bf623007..a29df350 100644
--- a/README.md
+++ b/README.md
@@ -1,184 +1,101 @@
-# Early Access: Prisma ORM for React Native and Expo
+# React Native Prisma 7.9
-A Prisma engine adaptation for React Native. Please note that this is in [Early Access](https://www.prisma.io/docs/orm/more/releases#early-access)
+面向 Expo 与 React Native 新架构的 Prisma 7.9 同步本地数据库方案。
-## Installation
+- 将 Prisma 7.9 Query Compiler 精简为 SQLite 原生库,通过 Expo Modules JSI 同步调用。
+- 通过 `expo-sqlite` 的 JSI 同步接口直接读写 SQLite。
+- CRUD、聚合、关联查询和查询计划事务直接返回结果,不为每次本地查询额外创建 Promise。
+- 避免数据库已经返回、界面仍等待 Promise 调度后才更新的问题。
+- 支持 Expo 默认 Hermes,不在运行时加载 WebAssembly,也不携带旧版完整 Query Engine。
+- 当前 iOS 开发基线为 Expo 58、React Native 0.87、Prisma 7.9.1。
-Install `@prisma/client`, `@prisma/react-native` and the `react-native-quick-base64` dependency:
+`release` 已包含 iPhone 与 arm64/x86_64 模拟器的原生 Query Compiler;安装后需要重新生成原生工程或执行 `bun ios`。
-```
-npm i --save --save-exact @prisma/client@latest @prisma/react-native@latest react-native-quick-base64
-```
-
-To ensure migration files are copied into the app bundle you need to either enable the Expo plugin or configure ios and Android manually:
-
-### Expo
-
-If you are using Expo, you can add the expo plugin to automatically copy migration files. Modify your `app.json` by adding the react-native-prisma plugin:
-
-```json
-{
- "expo": {
- // ... The rest of your expo config
- "plugins": ["@prisma/react-native"]
- }
-}
-```
-
-To activate the plugin, run prebuild:
-
-```
-npx expo prebuild --clean
-```
+## 安装
-The Expo plugin simply configures the Android and ios projects during the prebuild phase. If you are not using Expo, you can do this manually:
+`prisma`、`@prisma/client` 与本包版本必须一致:
-
-### iOS
-
-Go into `Xcode` → `Build Phases` → `Bundle React Native Code and images` and modify it so that it looks like this:
-
-
-
-```bash
-set -e
-
-WITH_ENVIRONMENT="../node_modules/react-native/scripts/xcode/with-environment.sh"
-REACT_NATIVE_XCODE="../node_modules/react-native/scripts/react-native-xcode.sh"
-PRISMA_MIGRATIONS="../node_modules/@prisma/react-native/copy-migrations.sh" # Add this
-
-/bin/sh -c "$WITH_ENVIRONMENT $PRISMA_MIGRATIONS $REACT_NATIVE_XCODE" # Add it to the list of running scripts
+```sh
+bun add @prisma/client@7.9.1 expo-sqlite github:song-react/react-native-prisma#release
+bun add -d prisma@7.9.1
```
-### Android
+生成器配置:
-For Android you need to modify your apps `app/Build.gradle`. Add the following at the top of the file.
-
-```groovy
-apply from: "../../node_modules/@prisma/react-native/react-native-prisma.gradle"
-```
-
-## Enable React Native support in your schema file
-
-React Native support is currently a preview feature and has to be activated in your schema.prisma file. You can place this file in the root of the application:
-
-```ts
+```prisma
generator client {
- provider = "prisma-client-js"
- previewFeatures = ["reactNative"]
+ provider = "prisma-client"
+ output = "../generated/prisma"
}
datasource db {
provider = "sqlite"
- url = "file:./app.db"
}
-// Your data model
-
model User {
- id Int @id @default(autoincrement())
- name String
+ id Int @id @default(autoincrement())
+ name String
}
```
-You can create the database file and initial migration using Prisma migrate:
+每次生成 Prisma Client 后执行准备脚本:
-```
-npx prisma@latest migrate dev
-```
-
-
-you can now generate the Prisma Client like this:
-
-```
-npx prisma@latest generate
-```
-
-## Reactive queries
-
-This package contains an extension to the Prisma client that allows you to use reactive queries. Use at your own convenience and care since it might introduce large re-renders in your app.
-
-```ts
-import { PrismaClient } from '@prisma/client/react-native';
-import { reactiveHooksExtension } from '@prisma/react-native';
-
-const baseClient = new PrismaClient();
-
-export const extendedClient = baseClient.$extends(reactiveHooksExtension());
-```
-
-Then in your React component you can use the hook:
-
-```tsx
-import { Text } from 'react-native';
-import { extendedClient } from './myDbModule';
-
-export default function App {
-
- // Will automatically re-render the component with new data
- const users = extendedClient.user.useFindMany();
-
- return (
- { users }
- )
+```json
+{
+ "scripts": {
+ "db:generate": "prisma generate && prisma-react-native generated/prisma",
+ "db:migrate": "prisma migrate dev && bun db:generate",
+ "db:push": "prisma db push && bun db:generate",
+ "db:studio": "prisma studio",
+ "postinstall": "bun db:generate && prisma-react-native generated/prisma"
+ }
}
```
-Bear in mind, for the reactive queries to work you have to use the extended client to modify the data:
+`prisma-react-native` 会移除生成客户端中的 Node 与 WebAssembly 依赖,并接入 Hermes 可用的同步原生 Query Compiler。
+它还会把 `prisma/migrations/*/migration.sql` 嵌入生成的 Client,供设备端首次启动和版本升级时执行。
+
+## Demo
```ts
-extendedClient.user.create({ ...userData });
-```
+import { PrismaClient } from './generated/prisma/client';
+import {
+ PrismaExpoSQLite,
+ queriesExtension,
+} from '@prisma/react-native';
-There are several hooks you can use for your reactive queries:
+export const db = new PrismaClient({
+ adapter: new PrismaExpoSQLite('app.db'),
+}).$extends(queriesExtension());
-```ts
-useFindMany();
-useFindFirst();
-useFindUnique();
+// 自动应用尚未执行的迁移,并完成首次连接。
+export const databaseReady = db.$applyPendingMigrations();
```
-### Non hook reactive queries
-
-It is also possible to use callbacks for this queries in case you are not using hooks, but you still want to get notified when data changes
+连接完成后直接同步调用:
```ts
-import { PrismaClient } from '@prisma/client/react-native';
-import { reactiveQueriesExtension } from '@prisma/react-native';
+const start = async () => {
+ await databaseReady;
-const baseClient = new PrismaClient();
+ const user = db.user.create({ data: { name: 'Ada' } });
+ const users = db.user.findMany({ orderBy: { id: 'desc' } });
+ const count = db.user.count();
-export const extendedClient = baseClient.$extends(reactiveQueriesExtension());
+ console.log(user, users, count);
+};
```
-## Applying migrations
-
-On application start you need to run the migrations to make sure the database is in a consistent state with your Prisma generated client:
+## API
```ts
-import '@prisma/react-native';
-import { PrismaClient } from '@prisma/client/react-native';
-
-const baseClient = new PrismaClient();
-
-async function initializeDb() {
- try {
- baseClient.$applyPendingMigrations();
- } catch (e) {
- console.error(`failed to apply migrations: ${e}`);
- throw new Error(
- 'Applying migrations failed, your app is now in an inconsistent state. We cannot guarantee safety, it is now your responsibility to reset the database or tell the user to re-install the app'
- );
- }
-}
+import { queriesExtension } from '@prisma/react-native';
+import { PrismaExpoSQLite } from '@prisma/react-native';
```
-Care must be taken to ensure migrations will always succeed. Migrations will be executed on the users device at runtime, and if they fail to run, your application will most likely be unable to work correctly. In such a situation, the only option for the user might be to delete all app data and start over.
-
-## Material
-
-🎥 Watch the introduction at App.js here: https://www.youtube.com/watch?v=keZYUjAYSJM
+开发时使用 `prisma migrate dev` 生成迁移;`prisma db push` 只更新开发机数据库,不会更新用户设备。App 启动时调用一次 `$applyPendingMigrations()`,之后 CRUD、聚合和查询计划事务均同步返回。
-📖 Read the announcement post here: https://www.prisma.io/blog/bringing-prisma-orm-to-react-native-and-expo
+## 发布分支
-📹 Watch Catalin build an app with Prisma and Expo here: https://www.youtube.com/watch?v=65Iqes0lxpQ
+- `main`:完整 TypeScript 源码。
+- `release`:iOS 原生 Query Compiler、CommonJS、ESM、类型声明及混淆 JS,可直接作为 Git 依赖安装。
diff --git a/android/CMakeLists.txt b/android/CMakeLists.txt
deleted file mode 100644
index 65ad3a33..00000000
--- a/android/CMakeLists.txt
+++ /dev/null
@@ -1,54 +0,0 @@
-cmake_minimum_required(VERSION 3.9.0)
-project(Prisma)
-
-set (PACKAGE_NAME "react-native-prisma")
-set (CMAKE_VERBOSE_MAKEFILE ON)
-set (CMAKE_CXX_STANDARD 17)
-set (BUILD_DIR ${CMAKE_SOURCE_DIR}/build)
-
-
-add_library(
- ${PACKAGE_NAME}
- SHARED
- ../cpp/react-native-prisma.cpp
- ../cpp/macros.h
- ../cpp/QueryEngineHostObject.cpp
- ../cpp/QueryEngineHostObject.h
- ../cpp/react-native-prisma.h
- ../cpp/ThreadPool.cpp
- ../cpp/ThreadPool.h
- ../cpp/utils.h
- ../cpp/utils.cpp
- ../engines/android/query_engine.h
- cpp-adapter.cpp
-)
-
-include_directories(
- ../cpp
- ../engines/android
-)
-
-set_target_properties(
- ${PACKAGE_NAME} PROPERTIES
- CXX_STANDARD 17
- CXX_EXTENSIONS OFF
- POSITION_INDEPENDENT_CODE ON
-)
-
-find_package(ReactAndroid REQUIRED CONFIG)
-find_package(fbjni REQUIRED CONFIG)
-
-cmake_path(SET QUERY_ENGINE_LIB ${CMAKE_CURRENT_SOURCE_DIR}/../engines/android/jniLibs/${ANDROID_ABI}/libquery_engine.a NORMALIZE)
-
-add_library(query_engine STATIC IMPORTED)
-set_target_properties(query_engine PROPERTIES IMPORTED_LOCATION ${QUERY_ENGINE_LIB})
-
-target_link_libraries(
- ${PACKAGE_NAME}
- query_engine
- fbjni::fbjni
- ReactAndroid::jsi
- ReactAndroid::turbomodulejsijni
- ReactAndroid::react_nativemodule_core
- android
-)
\ No newline at end of file
diff --git a/android/build.gradle b/android/build.gradle
deleted file mode 100644
index c169c722..00000000
--- a/android/build.gradle
+++ /dev/null
@@ -1,162 +0,0 @@
-buildscript {
- repositories {
- google()
- mavenCentral()
- }
-
- dependencies {
- classpath "com.android.tools.build:gradle:7.2.1"
- }
-}
-
-def isNewArchitectureEnabled() {
- return rootProject.hasProperty("newArchEnabled") && rootProject.getProperty("newArchEnabled") == "true"
-}
-
-apply plugin: "com.android.library"
-
-if (isNewArchitectureEnabled()) {
- apply plugin: "com.facebook.react"
-}
-
-def getExtOrDefault(name) {
- return rootProject.ext.has(name) ? rootProject.ext.get(name) : project.properties["Prisma_" + name]
-}
-
-def getExtOrIntegerDefault(name) {
- return rootProject.ext.has(name) ? rootProject.ext.get(name) : (project.properties["Prisma_" + name]).toInteger()
-}
-
-def supportsNamespace() {
- def parsed = com.android.Version.ANDROID_GRADLE_PLUGIN_VERSION.tokenize('.')
- def major = parsed[0].toInteger()
- def minor = parsed[1].toInteger()
-
- // Namespace support was added in 7.3.0
- return (major == 7 && minor >= 3) || major >= 8
-}
-
-def resolveBuildType() {
- Gradle gradle = getGradle()
- String tskReqStr = gradle.getStartParameter().getTaskRequests()['args'].toString()
-
- return tskReqStr.contains('Release') ? 'release' : 'debug'
-}
-
-android {
- if (supportsNamespace()) {
- namespace "com.prisma"
-
- sourceSets {
- main {
- manifest.srcFile "src/main/AndroidManifestNew.xml"
- }
- }
- }
-
- // ndkVersion getExtOrDefault("ndkVersion")
- compileSdkVersion getExtOrIntegerDefault("compileSdkVersion")
-
- defaultConfig {
- minSdkVersion getExtOrIntegerDefault("minSdkVersion")
- targetSdkVersion getExtOrIntegerDefault("targetSdkVersion")
- buildConfigField "boolean", "IS_NEW_ARCHITECTURE_ENABLED", isNewArchitectureEnabled().toString()
-
- externalNativeBuild {
- cmake {
- cppFlags "-O2", "-fexceptions", "-frtti", "-DONANDROID", "-lz"
- abiFilters 'x86', 'x86_64', 'armeabi-v7a', 'arm64-v8a'
- arguments '-DANDROID_STL=c++_shared'
- }
- }
-
- packagingOptions {
- doNotStrip resolveBuildType() == 'debug' ? "**/**/*.so" : ''
- excludes = [
- "META-INF",
- "META-INF/**",
- "**/libjsi.so",
- "**/libreact_nativemodule_core.so",
- "**/libturbomodulejsijni.so",
- "**/libc++_shared.so",
- "**/libfbjni.so"
- ]
- }
- }
-
- externalNativeBuild {
- cmake {
- path "CMakeLists.txt"
- }
- }
-
- buildFeatures {
- buildConfig true
- prefab true
- }
-
- buildTypes {
- release {
- minifyEnabled false
- }
- }
-
- lintOptions {
- disable "GradleCompatible"
- }
-
- compileOptions {
- sourceCompatibility JavaVersion.VERSION_1_8
- targetCompatibility JavaVersion.VERSION_1_8
- }
-
- sourceSets {
- main {
- if (isNewArchitectureEnabled()) {
- java.srcDirs += [
- "src/newarch",
- // This is needed to build Kotlin project with NewArch enabled
- "${project.buildDir}/generated/source/codegen/java"
- ]
- } else {
- java.srcDirs += ["src/oldarch"]
- }
- }
- }
-}
-
-repositories {
- mavenCentral()
- google()
-}
-
-
-dependencies {
- // For < 0.71, this will be from the local maven repo
- // For > 0.71, this will be replaced by `com.facebook.react:react-android:$version` by react gradle plugin
- //noinspection GradleDynamicVersion
- implementation "com.facebook.react:react-native:+"
-}
-
-// Resolves "LOCAL_SRC_FILES points to a missing file, Check that libfb.so exists or that its path is correct".
-tasks.whenTaskAdded { task ->
- if (task.name.contains("configureCMakeDebug")) {
- rootProject.getTasksByName("packageReactNdkDebugLibs", true).forEach {
- task.dependsOn(it)
- }
- }
- // We want to add a dependency for both configureCMakeRelease and configureCMakeRelWithDebInfo
- if (task.name.contains("configureCMakeRel")) {
- rootProject.getTasksByName("packageReactNdkReleaseLibs", true).forEach {
- task.dependsOn(it)
- }
- }
-}
-
-if (isNewArchitectureEnabled()) {
- react {
- jsRootDir = file("../src/")
- libraryName = "Prisma"
- codegenJavaPackageName = "com.prisma"
- }
-}
diff --git a/android/cpp-adapter.cpp b/android/cpp-adapter.cpp
deleted file mode 100644
index 8957ec53..00000000
--- a/android/cpp-adapter.cpp
+++ /dev/null
@@ -1,38 +0,0 @@
-#include "react-native-prisma.h"
-#include
-#include
-#include
-#include
-#include
-
-namespace jni = facebook::jni;
-namespace react = facebook::react;
-namespace jsi = facebook::jsi;
-
-struct PrismaModule : jni::JavaClass {
- static constexpr auto kJavaDescriptor = "Lcom/prisma/PrismaModule;";
-
- static void registerNatives() {
- javaClassStatic()->registerNatives(
- {makeNativeMethod("installNativeJsi", PrismaModule::installNativeJsi)});
- }
-
-private:
- static void installNativeJsi(
- jni::alias_ref thiz, jlong jsiRuntimePtr,
- jni::alias_ref jsCallInvokerHolder,
- jni::alias_ref docPath,
- jni::alias_ref migrationsPath) {
- auto jsiRuntime = reinterpret_cast(jsiRuntimePtr);
- auto jsCallInvoker = jsCallInvokerHolder->cthis()->getCallInvoker();
- std::string docPathString = docPath->toStdString();
- std::string migrationsPathString = migrationsPath->toStdString();
-
- prisma::install_cxx(*jsiRuntime, jsCallInvoker, docPathString.c_str(),
- migrationsPathString.c_str());
- }
-};
-
-JNIEXPORT jint JNI_OnLoad(JavaVM *vm, void *) {
- return jni::initialize(vm, [] { PrismaModule::registerNatives(); });
-}
\ No newline at end of file
diff --git a/android/gradle.properties b/android/gradle.properties
deleted file mode 100644
index a59aaeb9..00000000
--- a/android/gradle.properties
+++ /dev/null
@@ -1,5 +0,0 @@
-Prisma_kotlinVersion=1.7.0
-Prisma_minSdkVersion=21
-Prisma_targetSdkVersion=34
-Prisma_compileSdkVersion=34
-Prisma_ndkversion=21.4.7075529
diff --git a/android/src/main/AndroidManifest.xml b/android/src/main/AndroidManifest.xml
deleted file mode 100644
index 5605b402..00000000
--- a/android/src/main/AndroidManifest.xml
+++ /dev/null
@@ -1,3 +0,0 @@
-
-
diff --git a/android/src/main/AndroidManifestNew.xml b/android/src/main/AndroidManifestNew.xml
deleted file mode 100644
index a2f47b60..00000000
--- a/android/src/main/AndroidManifestNew.xml
+++ /dev/null
@@ -1,2 +0,0 @@
-
-
diff --git a/android/src/main/java/com/prisma/PrismaModule.java b/android/src/main/java/com/prisma/PrismaModule.java
deleted file mode 100644
index 97d5d43d..00000000
--- a/android/src/main/java/com/prisma/PrismaModule.java
+++ /dev/null
@@ -1,139 +0,0 @@
-package com.prisma;
-
-import android.content.res.AssetManager;
-import android.os.Environment;
-
-import androidx.annotation.NonNull;
-
-import com.facebook.react.bridge.Promise;
-import com.facebook.react.bridge.ReactApplicationContext;
-import com.facebook.react.bridge.ReactMethod;
-import com.facebook.react.turbomodule.core.CallInvokerHolderImpl;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-
-public class PrismaModule extends PrismaSpec {
- public static final String NAME = "Prisma";
-
- PrismaModule(ReactApplicationContext context) {
- super(context);
- }
-
- @Override
- @NonNull
- public String getName() {
- return NAME;
- }
-
- static {
-// System.loadLibrary("query-engine");
- System.loadLibrary("react-native-prisma");
- }
-
- public static native void installNativeJsi(long jsContextNativePointer, CallInvokerHolderImpl callInvoker, String docPath, String migrationsPath);
-
- public String copyDirorfileFromAssetManager(String arg_assetDir, String arg_destinationDir) throws IOException
- {
- String sd_path = getReactApplicationContext().getCacheDir().getAbsolutePath();
- String dest_dir_path = sd_path + addLeadingSlash(arg_destinationDir);
- File dest_dir = new File(dest_dir_path);
-
- createDir(dest_dir);
-
- AssetManager asset_manager = getReactApplicationContext().getAssets();
- String[] files = asset_manager.list(arg_assetDir);
-
- for (int i = 0; i < files.length; i++)
- {
-
- String abs_asset_file_path = addTrailingSlash(arg_assetDir) + files[i];
- String sub_files[] = asset_manager.list(abs_asset_file_path);
-
- if (sub_files.length == 0)
- {
- // It is a file
- String dest_file_path = addTrailingSlash(dest_dir_path) + files[i];
- copyAssetFile(abs_asset_file_path, dest_file_path);
- } else
- {
- // It is a sub directory
- copyDirorfileFromAssetManager(abs_asset_file_path, addTrailingSlash(arg_destinationDir) + files[i]);
- }
- }
-
- return dest_dir_path;
- }
-
-
- public void copyAssetFile(String assetFilePath, String destinationFilePath) throws IOException
- {
- InputStream in = getReactApplicationContext().getAssets().open(assetFilePath);
- OutputStream out = new FileOutputStream(destinationFilePath);
-
- byte[] buf = new byte[1024];
- int len;
- while ((len = in.read(buf)) > 0)
- out.write(buf, 0, len);
- in.close();
- out.close();
- }
-
- public String addTrailingSlash(String path)
- {
- if (path.charAt(path.length() - 1) != '/')
- {
- path += "/";
- }
- return path;
- }
-
- public String addLeadingSlash(String path)
- {
- if (path.charAt(0) != '/')
- {
- path = "/" + path;
- }
- return path;
- }
-
- public void createDir(File dir) throws IOException
- {
- if (dir.exists())
- {
- if (!dir.isDirectory())
- {
- throw new IOException("Can't create directory, a file is in the way");
- }
- } else
- {
- dir.mkdirs();
- if (!dir.isDirectory())
- {
- throw new IOException("Unable to create directory");
- }
- }
- }
-
- @ReactMethod(isBlockingSynchronousMethod = true)
- public void install() {
- ReactApplicationContext context = this.getReactApplicationContext();
- long jsContextPointer = context.getJavaScriptContextHolder().get();
- CallInvokerHolderImpl jsCallInvokerHolder = (CallInvokerHolderImpl)context.getCatalystInstance().getJSCallInvokerHolder();
- String dbPath = context.getDatabasePath("defaultDatabase").getAbsolutePath().replace("defaultDatabase", "");
- String migrationsPath;
- try {
- migrationsPath = copyDirorfileFromAssetManager("migrations", "migrations");
- } catch (IOException e) {
- throw new RuntimeException(e);
- }
- installNativeJsi(
- jsContextPointer,
- jsCallInvokerHolder,
- dbPath, migrationsPath
- );
- }
-}
diff --git a/android/src/main/java/com/prisma/PrismaPackage.java b/android/src/main/java/com/prisma/PrismaPackage.java
deleted file mode 100644
index cd0f7889..00000000
--- a/android/src/main/java/com/prisma/PrismaPackage.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package com.prisma;
-
-import androidx.annotation.Nullable;
-
-import com.facebook.react.bridge.NativeModule;
-import com.facebook.react.bridge.ReactApplicationContext;
-import com.facebook.react.module.model.ReactModuleInfo;
-import com.facebook.react.module.model.ReactModuleInfoProvider;
-import com.facebook.react.TurboReactPackage;
-
-import java.util.HashMap;
-import java.util.Map;
-
-public class PrismaPackage extends TurboReactPackage {
-
- @Nullable
- @Override
- public NativeModule getModule(String name, ReactApplicationContext reactContext) {
- if (name.equals(PrismaModule.NAME)) {
- return new PrismaModule(reactContext);
- } else {
- return null;
- }
- }
-
- @Override
- public ReactModuleInfoProvider getReactModuleInfoProvider() {
- return () -> {
- final Map moduleInfos = new HashMap<>();
- boolean isTurboModule = BuildConfig.IS_NEW_ARCHITECTURE_ENABLED;
- moduleInfos.put(
- PrismaModule.NAME,
- new ReactModuleInfo(
- PrismaModule.NAME,
- PrismaModule.NAME,
- false, // canOverrideExistingModule
- false, // needsEagerInit
- true, // hasConstants
- false, // isCxxModule
- isTurboModule // isTurboModule
- ));
- return moduleInfos;
- };
- }
-}
diff --git a/android/src/newarch/PrismaSpec.java b/android/src/newarch/PrismaSpec.java
deleted file mode 100644
index 442b4972..00000000
--- a/android/src/newarch/PrismaSpec.java
+++ /dev/null
@@ -1,9 +0,0 @@
-package com.prisma;
-
-import com.facebook.react.bridge.ReactApplicationContext;
-
-abstract class PrismaSpec extends NativePrismaSpec {
- PrismaSpec(ReactApplicationContext context) {
- super(context);
- }
-}
diff --git a/android/src/oldarch/PrismaSpec.java b/android/src/oldarch/PrismaSpec.java
deleted file mode 100644
index dd3e1069..00000000
--- a/android/src/oldarch/PrismaSpec.java
+++ /dev/null
@@ -1,13 +0,0 @@
-package com.prisma;
-
-import com.facebook.react.bridge.ReactApplicationContext;
-import com.facebook.react.bridge.ReactContextBaseJavaModule;
-import com.facebook.react.bridge.Promise;
-
-abstract class PrismaSpec extends ReactContextBaseJavaModule {
- PrismaSpec(ReactApplicationContext context) {
- super(context);
- }
-
- public abstract void install();
-}
diff --git a/app.plugin.js b/app.plugin.js
deleted file mode 100644
index 3ae4fa6e..00000000
--- a/app.plugin.js
+++ /dev/null
@@ -1 +0,0 @@
-module.exports = require('./expo');
diff --git a/babel.config.js b/babel.config.js
deleted file mode 100644
index 21769e85..00000000
--- a/babel.config.js
+++ /dev/null
@@ -1,4 +0,0 @@
-/* eslint-env node */
-module.exports = {
- presets: ['module:@react-native/babel-preset'],
-};
diff --git a/copy-migrations.sh b/copy-migrations.sh
deleted file mode 100755
index 43205c26..00000000
--- a/copy-migrations.sh
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-echo "Copying prisma migration files..."
-
-MIGRATIONS_TARGET=${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}
-
-rm -rf "$MIGRATIONS_TARGET/migrations"
-mkdir "$MIGRATIONS_TARGET/migrations"
-cp -r ${SRCROOT}/../migrations ${MIGRATIONS_TARGET}
-
-echo "migration files copied ✅"
\ No newline at end of file
diff --git a/cpp/QueryEngineHostObject.cpp b/cpp/QueryEngineHostObject.cpp
deleted file mode 100644
index 8fa6c038..00000000
--- a/cpp/QueryEngineHostObject.cpp
+++ /dev/null
@@ -1,14 +0,0 @@
-#include "QueryEngineHostObject.h"
-
-namespace prisma {
-namespace jsi = facebook::jsi;
-
-QueryEngineHostObject::QueryEngineHostObject(
- std::string id, std::function log_callback) {
- this->id = id;
- this->log_callback = log_callback;
-}
-
-void QueryEngineHostObject::setEngine(QueryEngine *ptr) { this->engine = ptr; }
-
-} // namespace prisma
diff --git a/cpp/QueryEngineHostObject.h b/cpp/QueryEngineHostObject.h
deleted file mode 100644
index ec18d023..00000000
--- a/cpp/QueryEngineHostObject.h
+++ /dev/null
@@ -1,26 +0,0 @@
-
-#ifndef query_engine_host_object_h
-#define query_engine_host_object_h
-
-#include "query_engine.h"
-#include
-#include
-#include
-
-namespace prisma {
-namespace jsi = facebook::jsi;
-
-class JSI_EXPORT QueryEngineHostObject : public jsi::HostObject {
-public:
- QueryEngineHostObject(std::string id,
- std::function log_callback);
-
- void setEngine(QueryEngine *ptr);
-
- std::string id;
- std::function log_callback;
- QueryEngine *engine;
-};
-} // namespace prisma
-
-#endif
diff --git a/cpp/ThreadPool.cpp b/cpp/ThreadPool.cpp
deleted file mode 100644
index 9a4c1b72..00000000
--- a/cpp/ThreadPool.cpp
+++ /dev/null
@@ -1,117 +0,0 @@
-#include "ThreadPool.h"
-
-namespace prisma {
-
-ThreadPool::ThreadPool() : done(false) {
- // This returns the number of threads supported by the system. If the
- // function can't figure out this information, it returns 0. 0 is not good,
- // so we create at least 1
- auto numberOfThreads = std::thread::hardware_concurrency();
- if (numberOfThreads == 0) {
- numberOfThreads = 1;
- }
-
- for (unsigned i = 0; i < numberOfThreads; ++i) {
- // The threads will execute the private member `doWork`. Note that we need
- // to pass a reference to the function (namespaced with the class name) as
- // the first argument, and the current object as second argument
- threads.push_back(std::thread(&ThreadPool::doWork, this));
- }
-}
-
-// The destructor joins all the threads so the program can exit gracefully.
-// This will be executed if there is any exception (e.g. creating the threads)
-ThreadPool::~ThreadPool() {
- // So threads know it's time to shut down
- done = true;
-
- // Wake up all the threads, so they can finish and be joined
- workQueueConditionVariable.notify_all();
-
- for (auto &thread : threads) {
- if (thread.joinable()) {
- thread.join();
- }
- }
-
- threads.clear();
-}
-
-// This function will be called by the server every time there is a request
-// that needs to be processed by the thread pool
-void ThreadPool::queueWork(std::function task) {
- // Grab the mutex
- std::lock_guard g(workQueueMutex);
-
- // Push the request to the queue
- workQueue.push(task);
-
- // Notify one thread that there are requests to process
- workQueueConditionVariable.notify_one();
-}
-
-// Function used by the threads to grab work from the queue
-void ThreadPool::doWork() {
- // Loop while the queue is not destructing
- while (!done) {
- std::function task;
-
- // Create a scope, so we don't lock the queue for longer than necessary
- {
- std::unique_lock g(workQueueMutex);
- workQueueConditionVariable.wait(g, [&] {
- // Only wake up if there are elements in the queue or the program is
- // shutting down
- return !workQueue.empty() || done;
- });
-
- // If we are shutting down exit witout trying to process more work
- if (done) {
- break;
- }
-
- task = workQueue.front();
- workQueue.pop();
- }
- ++busy;
- task();
- --busy;
- }
-}
-
-void ThreadPool::waitFinished() {
- std::unique_lock g(workQueueMutex);
- workQueueConditionVariable.wait(
- g, [&] { return workQueue.empty() && (busy == 0); });
-}
-
-void ThreadPool::restartPool() {
- // So threads know it's time to shut down
- done = true;
-
- // Wake up all the threads, so they can finish and be joined
- workQueueConditionVariable.notify_all();
-
- for (auto &thread : threads) {
- if (thread.joinable()) {
- thread.join();
- }
- }
-
- threads.clear();
-
- auto numberOfThreads = std::thread::hardware_concurrency();
- if (numberOfThreads == 0) {
- numberOfThreads = 1;
- }
-
- for (unsigned i = 0; i < numberOfThreads; ++i) {
- // The threads will execute the private member `doWork`. Note that we need
- // to pass a reference to the function (namespaced with the class name) as
- // the first argument, and the current object as second argument
- threads.push_back(std::thread(&ThreadPool::doWork, this));
- }
-
- done = false;
-}
-} // namespace prisma
diff --git a/cpp/ThreadPool.h b/cpp/ThreadPool.h
deleted file mode 100644
index f368a9f3..00000000
--- a/cpp/ThreadPool.h
+++ /dev/null
@@ -1,47 +0,0 @@
-#ifndef ThreadPool_h
-#define ThreadPool_h
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-namespace prisma {
-
-class ThreadPool {
-public:
- ThreadPool();
- ~ThreadPool();
- void queueWork(std::function task);
- void waitFinished();
- void restartPool();
-
-private:
- unsigned int busy;
- // This condition variable is used for the threads to wait until there is work
- // to do
- std::condition_variable_any workQueueConditionVariable;
-
- // We store the threads in a vector, so we can later stop them gracefully
- std::vector threads;
-
- // Mutex to protect workQueue
- std::mutex workQueueMutex;
-
- // Queue of requests waiting to be processed
- std::queue> workQueue;
-
- // This will be set to true when the thread pool is shutting down. This tells
- // the threads to stop looping and finish
- bool done;
-
- // Function used by the threads to grab work from the queue
- void doWork();
-};
-
-} // namespace prisma
-
-#endif /* ThreadPool_h */
diff --git a/cpp/macros.h b/cpp/macros.h
deleted file mode 100644
index 592e0c4e..00000000
--- a/cpp/macros.h
+++ /dev/null
@@ -1,11 +0,0 @@
-#ifndef macros_h
-#define macros_h
-
-#define HOSTFN(name, basecount) \
-jsi::Function::createFromHostFunction( \
-rt, \
-jsi::PropNameID::forAscii(rt, name), \
-basecount, \
-[=](jsi::Runtime &rt, const jsi::Value &thisValue, const jsi::Value *args, size_t count) -> jsi::Value
-
-#endif /* macros_h */
diff --git a/cpp/react-native-prisma.cpp b/cpp/react-native-prisma.cpp
deleted file mode 100644
index 387fbd0b..00000000
--- a/cpp/react-native-prisma.cpp
+++ /dev/null
@@ -1,274 +0,0 @@
-#include "react-native-prisma.h"
-#include "QueryEngineHostObject.h"
-#include "ThreadPool.h"
-#include "macros.h"
-#include "query_engine.h"
-#include "utils.h"
-#include
-#include
-
-namespace prisma {
-
-namespace jsi = facebook::jsi;
-
-static std::string base_path;
-std::string migrations_path;
-std::shared_ptr call_invoker;
-std::unordered_map>
- engine_map;
-ThreadPool thread_pool;
-
-// Pure C function that is used by Rust to call the log callback
-extern void log_callback(const char *id, const char *msg) {
- if (engine_map.count(id)) {
- auto engine = engine_map[id];
- engine->log_callback(msg);
- }
-}
-
-void install_cxx(jsi::Runtime &rt,
- std::shared_ptr call_invoker_param,
- const char *base_path_param,
- const char *migrations_path_param) {
- base_path = std::string(base_path_param);
- migrations_path = std::string(migrations_path_param);
- call_invoker = call_invoker_param;
-
- auto create = HOSTFN("create", 1) {
- // Rust will return a pointer to the internal struct, C++ has nothing to do
- // with this it will only be passed to the stateless functions
- QueryEngine *ptr;
- // Each query engine requires a unique id to route the logging messages
- std::string id = get_uuid();
-
- jsi::Object params = args[0].asObject(rt);
-
- std::string datamodel =
- params.getProperty(rt, "datamodel").asString(rt).utf8(rt);
- std::string log_level =
- params.getProperty(rt, "logLevel").asString(rt).utf8(rt);
- bool log_queries = params.getProperty(rt, "logQueries").asBool();
- std::shared_ptr js_log_callback =
- std::make_shared(params.getProperty(rt, "logCallback"));
- bool ignore_env_var_errors =
- params.getProperty(rt, "ignoreEnvVarErrors").asBool();
- std::string env = params.getProperty(rt, "env").asString(rt).utf8(rt);
- std::string datasource_overrides =
- params.getProperty(rt, "datasourceOverrides").asString(rt).utf8(rt);
-
- ConstructorOptionsNative nativeOptions = ConstructorOptionsNative{""};
- ConstructorOptions options =
- ConstructorOptions{.id = id.c_str(),
- .datamodel = datamodel.c_str(),
- .base_path = base_path.c_str(),
- .log_level = log_level.c_str(),
- .log_queries = log_queries,
- .datasource_overrides = datasource_overrides.c_str(),
- .env = env.c_str(),
- .ignore_env_var_errors = ignore_env_var_errors,
- .native = nativeOptions,
- .log_callback = &log_callback};
-
- char *error_ptr;
-
- int prisma_res = prisma_create(options, &ptr, &error_ptr);
-
- if (prisma_res != PRISMA_OK) {
- auto error_string = std::string(error_ptr);
- free(error_ptr);
- throw std::runtime_error("Failed to create prisma engine: " +
- error_string);
- }
-
- auto log_callback_fn = [&rt, js_log_callback](std::string msg) {
- call_invoker->invokeAsync([&rt, msg, &js_log_callback] {
- js_log_callback->asObject(rt).asFunction(rt).call(
- rt, jsi::String::createFromUtf8(rt, msg));
- });
- };
-
- QueryEngineHostObject engineHostObject =
- QueryEngineHostObject(id, log_callback_fn);
-
- engineHostObject.setEngine(ptr);
-
- auto engine = std::make_shared(engineHostObject);
- engine_map[id] = engine;
-
- return jsi::Object::createFromHostObject(rt, engine);
- });
-
- auto connect = HOSTFN("connect", 2) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- std::string trace = args[1].asString(rt).utf8(rt);
- char *error_ptr;
-
- int result = prisma_connect(queryEngineHostObject->engine, trace.c_str(),
- &error_ptr);
- if (result != PRISMA_OK) {
- std::string error_message(error_ptr);
- free(error_ptr);
- throw std::runtime_error(error_message);
- }
- return {};
- });
-
- auto execute = HOSTFN("execute", 4) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- std::string body = args[1].asString(rt).utf8(rt);
- std::string trace = args[2].asString(rt).utf8(rt);
- std::string tx_id;
- if (count > 3 && args[3].isString()) {
- tx_id = args[3].asString(rt).utf8(rt);
- }
-
- auto promise_constructor = rt.global().getPropertyAsFunction(rt, "Promise");
-
- auto promise = promise_constructor.callAsConstructor(rt, HOSTFN("executor", 2) {
- auto resolve = std::make_shared(rt, args[0]);
- auto reject = std::make_shared(rt, args[1]);
-
- auto task = [&rt, &queryEngineHostObject, body = std::move(body),
- trace = std::move(trace), tx_id = std::move(tx_id), resolve,
- reject]() {
- const char *response;
- char *error_ptr;
-
- if (!tx_id.empty()) {
- response = prisma_query(queryEngineHostObject->engine, body.c_str(),
- trace.c_str(), tx_id.c_str(), &error_ptr);
- } else {
- response = prisma_query(queryEngineHostObject->engine, body.c_str(),
- trace.c_str(), nullptr, &error_ptr);
- }
-
- call_invoker->invokeAsync([&rt, response = std::move(response),
- error_ptr, resolve, reject]() {
- if (error_ptr == nullptr) {
- resolve->asObject(rt).asFunction(rt).call(
- rt, jsi::String::createFromUtf8(rt, response));
- } else {
- auto errCtr = rt.global().getPropertyAsFunction(rt, "Error");
- std::string error_message(error_ptr);
- free(error_ptr);
-
- auto error = errCtr.callAsConstructor(
- rt, jsi::String::createFromUtf8(rt, error_message));
-
- reject->asObject(rt).asFunction(rt).call(rt, error);
- }
- });
- };
-
- thread_pool.queueWork(task);
-
- return {};
- }));
-
- return promise;
- });
-
- auto start_transaction = HOSTFN("startTransaction", 3) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- std::string body = args[1].asString(rt).utf8(rt);
- std::string trace = args[2].asString(rt).utf8(rt);
-
- const char *response = prisma_start_transaction(
- queryEngineHostObject->engine, body.c_str(), trace.c_str());
-
- if (response == nullptr) {
- throw std::runtime_error("prisma engine did not start transaction");
- }
-
- return jsi::String::createFromUtf8(rt, std::string(response));
- });
-
- auto commit_transaction = HOSTFN("commitTransaction", 3) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- std::string body = args[1].asString(rt).utf8(rt);
- std::string trace = args[2].asString(rt).utf8(rt);
-
- const char *response = prisma_commit_transaction(
- queryEngineHostObject->engine, body.c_str(), trace.c_str());
-
- if (response == nullptr) {
- throw std::runtime_error("prisma engine did not commit transaction");
- }
-
- return jsi::String::createFromUtf8(rt, std::string(response));
- });
-
- auto rollback_transaction = HOSTFN("rollbackTransaction", 3) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- std::string body = args[1].asString(rt).utf8(rt);
- std::string trace = args[2].asString(rt).utf8(rt);
-
- const char *response = prisma_rollback_transaction(
- queryEngineHostObject->engine, body.c_str(), trace.c_str());
-
- if (response == nullptr) {
- throw std::runtime_error("prisma engine did not rollback transaction");
- }
-
- return jsi::String::createFromUtf8(rt, std::string(response));
- });
-
- auto disconnect = HOSTFN("disconnect", 2) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- std::string trace = args[1].asString(rt).utf8(rt);
-
- engine_map.erase(queryEngineHostObject->id);
-
- int res = prisma_disconnect(queryEngineHostObject->engine, trace.c_str());
-
- if (res != PRISMA_OK) {
- throw std::runtime_error("Could not disconnect from prisma query engine");
- }
- return {};
- });
-
- auto apply_pending_migrations = HOSTFN("applyPendingMigrations", 1) {
- std::shared_ptr queryEngineHostObject =
- args[0].asObject(rt).asHostObject(rt);
- char *error_ptr;
- int res = prisma_apply_pending_migrations(
- queryEngineHostObject->engine, migrations_path.c_str(), &error_ptr);
-
- if (res != PRISMA_OK) {
- auto error_string = std::string(error_ptr);
- free(error_ptr);
- throw std::runtime_error(error_string);
- }
-
- return {};
- });
-
- jsi::Object module = jsi::Object(rt);
- module.setProperty(rt, "create", std::move(create));
- module.setProperty(rt, "connect", std::move(connect));
- module.setProperty(rt, "execute", std::move(execute));
- module.setProperty(rt, "startTransaction", std::move(start_transaction));
- module.setProperty(rt, "commitTransaction", std::move(commit_transaction));
- module.setProperty(rt, "rollbackTransaction",
- std::move(rollback_transaction));
- module.setProperty(rt, "disconnect", std::move(disconnect));
- module.setProperty(rt, "applyPendingMigrations",
- std::move(apply_pending_migrations));
-
- rt.global().setProperty(rt, "__PrismaProxy", std::move(module));
-}
-
-void invalidate() {
- for (auto &engine : engine_map) {
- prisma_destroy(engine.second->engine);
- }
- engine_map.clear();
-}
-
-} // namespace prisma
diff --git a/cpp/react-native-prisma.h b/cpp/react-native-prisma.h
deleted file mode 100644
index 316a921f..00000000
--- a/cpp/react-native-prisma.h
+++ /dev/null
@@ -1,18 +0,0 @@
-#ifndef PRISMA_H
-#define PRISMA_H
-
-#include
-#include
-
-namespace prisma {
-
-namespace jsi = facebook::jsi;
-namespace react = facebook::react;
-
-void install_cxx(jsi::Runtime &rt,
- std::shared_ptr jsCallInvoker,
- const char *basePathStr, const char *migrations_path);
-void invalidate();
-} // namespace prisma
-
-#endif /* PRISMA_H */
diff --git a/cpp/utils.cpp b/cpp/utils.cpp
deleted file mode 100644
index 6e19c16b..00000000
--- a/cpp/utils.cpp
+++ /dev/null
@@ -1,23 +0,0 @@
-#include "utils.h"
-#include
-#include
-
-// Semi random function, more than enough for our purposes
-std::string get_uuid() {
- static std::random_device dev;
- static std::mt19937 rng(dev());
-
- std::uniform_int_distribution dist(0, 15);
-
- const char *v = "0123456789abcdef";
- const bool dash[] = {0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0};
-
- std::string res;
- for (int i = 0; i < 16; i++) {
- if (dash[i])
- res += "-";
- res += v[dist(rng)];
- res += v[dist(rng)];
- }
- return res;
-}
\ No newline at end of file
diff --git a/cpp/utils.h b/cpp/utils.h
deleted file mode 100644
index d1d5ab02..00000000
--- a/cpp/utils.h
+++ /dev/null
@@ -1,4 +0,0 @@
-#pragma once
-#include
-
-std::string get_uuid();
\ No newline at end of file
diff --git a/example/.bundle/config b/example/.bundle/config
deleted file mode 100644
index 848943bb..00000000
--- a/example/.bundle/config
+++ /dev/null
@@ -1,2 +0,0 @@
-BUNDLE_PATH: "vendor/bundle"
-BUNDLE_FORCE_RUBY_PLATFORM: 1
diff --git a/example/.detoxrc.js b/example/.detoxrc.js
deleted file mode 100644
index e26ba46a..00000000
--- a/example/.detoxrc.js
+++ /dev/null
@@ -1,50 +0,0 @@
-/** @type {Detox.DetoxConfig} */
-module.exports = {
- testRunner: {
- args: {
- $0: 'jest',
- config: 'e2e/jest.config.js',
- },
- jest: {
- setupTimeout: 120000,
- },
- },
- apps: {
- 'ios.release': {
- type: 'ios.app',
- binaryPath: 'ios/build/Build/Products/Release-iphonesimulator/Prisma.app',
- build:
- 'xcodebuild -quiet -workspace ios/PrismaExample.xcworkspace -scheme Release -configuration Release -sdk iphonesimulator -derivedDataPath ios/build',
- },
- 'android.release': {
- type: 'android.apk',
- binaryPath: 'android/app/build/outputs/apk/release/app-release.apk',
- build:
- 'cd android && ./gradlew assembleRelease assembleAndroidTest -DtestBuildType=release && cd ..',
- },
- },
- devices: {
- simulator: {
- type: 'ios.simulator',
- device: {
- type: 'iPhone 15',
- },
- },
- emulator: {
- type: 'android.emulator',
- device: {
- avdName: 'Pixel_API_28',
- },
- },
- },
- configurations: {
- 'ios.sim.release': {
- device: 'simulator',
- app: 'ios.release',
- },
- 'android.emu.release': {
- device: 'emulator',
- app: 'android.release',
- },
- },
-};
diff --git a/example/.ruby-version b/example/.ruby-version
deleted file mode 100644
index 15a27998..00000000
--- a/example/.ruby-version
+++ /dev/null
@@ -1 +0,0 @@
-3.3.0
diff --git a/example/.watchmanconfig b/example/.watchmanconfig
deleted file mode 100644
index 0967ef42..00000000
--- a/example/.watchmanconfig
+++ /dev/null
@@ -1 +0,0 @@
-{}
diff --git a/example/Gemfile b/example/Gemfile
deleted file mode 100644
index 7558f393..00000000
--- a/example/Gemfile
+++ /dev/null
@@ -1,7 +0,0 @@
-source 'https://rubygems.org'
-
-# You may use http://rbenv.org/ or https://rvm.io/ to install and use this version
-ruby ">= 2.6.10"
-
-gem 'cocoapods', '1.14'
-gem 'activesupport', '>= 6.1.7.3', '< 7.1.0'
diff --git a/example/Gemfile.lock b/example/Gemfile.lock
deleted file mode 100644
index 7b06f222..00000000
--- a/example/Gemfile.lock
+++ /dev/null
@@ -1,105 +0,0 @@
-GEM
- remote: https://rubygems.org/
- specs:
- CFPropertyList (3.0.7)
- base64
- nkf
- rexml
- activesupport (6.1.7.6)
- concurrent-ruby (~> 1.0, >= 1.0.2)
- i18n (>= 1.6, < 2)
- minitest (>= 5.1)
- tzinfo (~> 2.0)
- zeitwerk (~> 2.3)
- addressable (2.8.6)
- public_suffix (>= 2.0.2, < 6.0)
- algoliasearch (1.27.5)
- httpclient (~> 2.8, >= 2.8.3)
- json (>= 1.5.1)
- atomos (0.1.3)
- base64 (0.2.0)
- claide (1.1.0)
- cocoapods (1.14.0)
- addressable (~> 2.8)
- claide (>= 1.0.2, < 2.0)
- cocoapods-core (= 1.14.0)
- cocoapods-deintegrate (>= 1.0.3, < 2.0)
- cocoapods-downloader (>= 2.0)
- cocoapods-plugins (>= 1.0.0, < 2.0)
- cocoapods-search (>= 1.0.0, < 2.0)
- cocoapods-trunk (>= 1.6.0, < 2.0)
- cocoapods-try (>= 1.1.0, < 2.0)
- colored2 (~> 3.1)
- escape (~> 0.0.4)
- fourflusher (>= 2.3.0, < 3.0)
- gh_inspector (~> 1.0)
- molinillo (~> 0.8.0)
- nap (~> 1.0)
- ruby-macho (>= 2.3.0, < 3.0)
- xcodeproj (>= 1.23.0, < 2.0)
- cocoapods-core (1.14.0)
- activesupport (>= 5.0, < 8)
- addressable (~> 2.8)
- algoliasearch (~> 1.0)
- concurrent-ruby (~> 1.1)
- fuzzy_match (~> 2.0.4)
- nap (~> 1.0)
- netrc (~> 0.11)
- public_suffix (~> 4.0)
- typhoeus (~> 1.0)
- cocoapods-deintegrate (1.0.5)
- cocoapods-downloader (2.1)
- cocoapods-plugins (1.0.0)
- nap
- cocoapods-search (1.0.1)
- cocoapods-trunk (1.6.0)
- nap (>= 0.8, < 2.0)
- netrc (~> 0.11)
- cocoapods-try (1.2.0)
- colored2 (3.1.2)
- concurrent-ruby (1.2.2)
- escape (0.0.4)
- ethon (0.16.0)
- ffi (>= 1.15.0)
- ffi (1.16.3)
- fourflusher (2.3.1)
- fuzzy_match (2.0.4)
- gh_inspector (1.1.3)
- httpclient (2.8.3)
- i18n (1.14.1)
- concurrent-ruby (~> 1.0)
- json (2.7.1)
- minitest (5.20.0)
- molinillo (0.8.0)
- nanaimo (0.3.0)
- nap (1.1.0)
- netrc (0.11.0)
- nkf (0.2.0)
- public_suffix (4.0.7)
- rexml (3.2.6)
- ruby-macho (2.5.1)
- typhoeus (1.4.1)
- ethon (>= 0.9.0)
- tzinfo (2.0.6)
- concurrent-ruby (~> 1.0)
- xcodeproj (1.24.0)
- CFPropertyList (>= 2.3.3, < 4.0)
- atomos (~> 0.1.3)
- claide (>= 1.0.2, < 2.0)
- colored2 (~> 3.1)
- nanaimo (~> 0.3.0)
- rexml (~> 3.2.4)
- zeitwerk (2.6.13)
-
-PLATFORMS
- ruby
-
-DEPENDENCIES
- activesupport (>= 6.1.7.3, < 7.1.0)
- cocoapods (= 1.14)
-
-RUBY VERSION
- ruby 2.7.6p219
-
-BUNDLED WITH
- 2.4.2
diff --git a/example/README.md b/example/README.md
deleted file mode 100644
index 12470c30..00000000
--- a/example/README.md
+++ /dev/null
@@ -1,79 +0,0 @@
-This is a new [**React Native**](https://reactnative.dev) project, bootstrapped using [`@react-native-community/cli`](https://github.com/react-native-community/cli).
-
-# Getting Started
-
->**Note**: Make sure you have completed the [React Native - Environment Setup](https://reactnative.dev/docs/environment-setup) instructions till "Creating a new application" step, before proceeding.
-
-## Step 1: Start the Metro Server
-
-First, you will need to start **Metro**, the JavaScript _bundler_ that ships _with_ React Native.
-
-To start Metro, run the following command from the _root_ of your React Native project:
-
-```bash
-# using npm
-npm start
-
-# OR using Yarn
-yarn start
-```
-
-## Step 2: Start your Application
-
-Let Metro Bundler run in its _own_ terminal. Open a _new_ terminal from the _root_ of your React Native project. Run the following command to start your _Android_ or _iOS_ app:
-
-### For Android
-
-```bash
-# using npm
-npm run android
-
-# OR using Yarn
-yarn android
-```
-
-### For iOS
-
-```bash
-# using npm
-npm run ios
-
-# OR using Yarn
-yarn ios
-```
-
-If everything is set up _correctly_, you should see your new app running in your _Android Emulator_ or _iOS Simulator_ shortly provided you have set up your emulator/simulator correctly.
-
-This is one way to run your app — you can also run it directly from within Android Studio and Xcode respectively.
-
-## Step 3: Modifying your App
-
-Now that you have successfully run the app, let's modify it.
-
-1. Open `App.tsx` in your text editor of choice and edit some lines.
-2. For **Android**: Press the R key twice or select **"Reload"** from the **Developer Menu** (Ctrl + M (on Window and Linux) or Cmd ⌘ + M (on macOS)) to see your changes!
-
- For **iOS**: Hit Cmd ⌘ + R in your iOS Simulator to reload the app and see your changes!
-
-## Congratulations! :tada:
-
-You've successfully run and modified your React Native App. :partying_face:
-
-### Now what?
-
-- If you want to add this new React Native code to an existing application, check out the [Integration guide](https://reactnative.dev/docs/integration-with-existing-apps).
-- If you're curious to learn more about React Native, check out the [Introduction to React Native](https://reactnative.dev/docs/getting-started).
-
-# Troubleshooting
-
-If you can't get this to work, see the [Troubleshooting](https://reactnative.dev/docs/troubleshooting) page.
-
-# Learn More
-
-To learn more about React Native, take a look at the following resources:
-
-- [React Native Website](https://reactnative.dev) - learn more about React Native.
-- [Getting Started](https://reactnative.dev/docs/environment-setup) - an **overview** of React Native and how setup your environment.
-- [Learn the Basics](https://reactnative.dev/docs/getting-started) - a **guided tour** of the React Native **basics**.
-- [Blog](https://reactnative.dev/blog) - read the latest official React Native **Blog** posts.
-- [`@facebook/react-native`](https://github.com/facebook/react-native) - the Open Source; GitHub **repository** for React Native.
diff --git a/example/android/app/build.gradle b/example/android/app/build.gradle
deleted file mode 100644
index ad320b80..00000000
--- a/example/android/app/build.gradle
+++ /dev/null
@@ -1,131 +0,0 @@
-apply plugin: "com.android.application"
-apply plugin: "org.jetbrains.kotlin.android"
-apply plugin: "com.facebook.react"
-apply from: "../../../react-native-prisma.gradle"
-
-/**
- * This is the configuration block to customize your React Native Android app.
- * By default you don't need to apply any configuration, just uncomment the lines you need.
- */
-react {
- /* Folders */
- // The root of your project, i.e. where "package.json" lives. Default is '..'
- // root = file("../")
- // The folder where the react-native NPM package is. Default is ../node_modules/react-native
- // reactNativeDir = file("../node_modules/react-native")
- // The folder where the react-native Codegen package is. Default is ../node_modules/@react-native/codegen
- // codegenDir = file("../node_modules/@react-native/codegen")
- // The cli.js file which is the React Native CLI entrypoint. Default is ../node_modules/react-native/cli.js
- // cliFile = file("../node_modules/react-native/cli.js")
-
- /* Variants */
- // The list of variants to that are debuggable. For those we're going to
- // skip the bundling of the JS bundle and the assets. By default is just 'debug'.
- // If you add flavors like lite, prod, etc. you'll have to list your debuggableVariants.
- // debuggableVariants = ["liteDebug", "prodDebug"]
-
- /* Bundling */
- // A list containing the node command and its flags. Default is just 'node'.
- // nodeExecutableAndArgs = ["node"]
- //
- // The command to run when bundling. By default is 'bundle'
- // bundleCommand = "ram-bundle"
- //
- // The path to the CLI configuration file. Default is empty.
- // bundleConfig = file(../rn-cli.config.js)
- //
- // The name of the generated asset file containing your JS bundle
- // bundleAssetName = "MyApplication.android.bundle"
- //
- // The entry file for bundle generation. Default is 'index.android.js' or 'index.js'
- // entryFile = file("../js/MyApplication.android.js")
- //
- // A list of extra flags to pass to the 'bundle' commands.
- // See https://github.com/react-native-community/cli/blob/main/docs/commands.md#bundle
- // extraPackagerArgs = []
-
- /* Hermes Commands */
- // The hermes compiler command to run. By default it is 'hermesc'
- // hermesCommand = "$rootDir/my-custom-hermesc/bin/hermesc"
- //
- // The list of flags to pass to the Hermes compiler. By default is "-O", "-output-source-map"
- // hermesFlags = ["-O", "-output-source-map"]
-}
-
-/**
- * Set this to true to Run Proguard on Release builds to minify the Java bytecode.
- */
-def enableProguardInReleaseBuilds = false
-
-/**
- * The preferred build flavor of JavaScriptCore (JSC)
- *
- * For example, to use the international variant, you can use:
- * `def jscFlavor = 'org.webkit:android-jsc-intl:+'`
- *
- * The international variant includes ICU i18n library and necessary data
- * allowing to use e.g. `Date.toLocaleString` and `String.localeCompare` that
- * give correct results when using with locales other than en-US. Note that
- * this variant is about 6MiB larger per architecture than default.
- */
-def jscFlavor = 'org.webkit:android-jsc:+'
-
-android {
- ndkVersion rootProject.ext.ndkVersion
- buildToolsVersion rootProject.ext.buildToolsVersion
- compileSdk rootProject.ext.compileSdkVersion
-
- namespace "com.prismaexample"
- defaultConfig {
- applicationId "com.prismaexample"
- minSdkVersion rootProject.ext.minSdkVersion
- targetSdkVersion rootProject.ext.targetSdkVersion
- versionCode 1
- versionName "1.0"
- testBuildType System.getProperty('testBuildType', 'debug')
- testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
- }
- signingConfigs {
- debug {
- storeFile file('debug.keystore')
- storePassword 'android'
- keyAlias 'androiddebugkey'
- keyPassword 'android'
- }
- }
- buildTypes {
- debug {
- signingConfig signingConfigs.debug
- }
- release {
- // Caution! In production, you need to generate your own keystore file.
- // see https://reactnative.dev/docs/signed-apk-android.
- signingConfig signingConfigs.debug
- minifyEnabled enableProguardInReleaseBuilds
- proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
- proguardFile "${rootProject.projectDir}/../node_modules/detox/android/detox/proguard-rules-app.pro"
- }
- }
-}
-
-dependencies {
- // The version of react-native is set by the React Native Gradle Plugin
- implementation("com.facebook.react:react-android")
- implementation("com.facebook.react:flipper-integration")
- androidTestImplementation('com.wix:detox:+')
- implementation('androidx.appcompat:appcompat:1.1.0')
-
- if (hermesEnabled.toBoolean()) {
- implementation("com.facebook.react:hermes-android")
- } else {
- implementation jscFlavor
- }
-}
-
-configurations.all {
- resolutionStrategy {
- force 'androidx.test:core:1.5.0'
- }
-}
-
-apply from: file("../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project)
diff --git a/example/android/app/debug.keystore b/example/android/app/debug.keystore
deleted file mode 100644
index 364e105e..00000000
Binary files a/example/android/app/debug.keystore and /dev/null differ
diff --git a/example/android/app/proguard-rules.pro b/example/android/app/proguard-rules.pro
deleted file mode 100644
index 11b02572..00000000
--- a/example/android/app/proguard-rules.pro
+++ /dev/null
@@ -1,10 +0,0 @@
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the proguardFiles
-# directive in build.gradle.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
diff --git a/example/android/app/src/androidTest/java/com/prismaexample/DetoxTest.java b/example/android/app/src/androidTest/java/com/prismaexample/DetoxTest.java
deleted file mode 100644
index e4a4aaed..00000000
--- a/example/android/app/src/androidTest/java/com/prismaexample/DetoxTest.java
+++ /dev/null
@@ -1,30 +0,0 @@
-
-package com.prismaexample;
-
-import com.wix.detox.Detox;
-import com.wix.detox.config.DetoxConfig;
-
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import androidx.test.ext.junit.runners.AndroidJUnit4;
-import androidx.test.filters.LargeTest;
-import androidx.test.rule.ActivityTestRule;
-
-@RunWith(AndroidJUnit4.class)
-@LargeTest
-public class DetoxTest {
- @Rule
- public ActivityTestRule mActivityRule = new ActivityTestRule<>(MainActivity.class, false, false);
-
- @Test
- public void runDetoxTests() {
- DetoxConfig detoxConfig = new DetoxConfig();
- detoxConfig.idlePolicyConfig.masterTimeoutSec = 90;
- detoxConfig.idlePolicyConfig.idleResourceTimeoutSec = 60;
- detoxConfig.rnContextLoadTimeoutSec = (BuildConfig.DEBUG ? 180 : 60);
-
- Detox.runTests(mActivityRule, detoxConfig);
- }
-}
\ No newline at end of file
diff --git a/example/android/app/src/debug/AndroidManifest.xml b/example/android/app/src/debug/AndroidManifest.xml
deleted file mode 100644
index eb98c01a..00000000
--- a/example/android/app/src/debug/AndroidManifest.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
-
-
diff --git a/example/android/app/src/main/AndroidManifest.xml b/example/android/app/src/main/AndroidManifest.xml
deleted file mode 100644
index 5d684a23..00000000
--- a/example/android/app/src/main/AndroidManifest.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/example/android/app/src/main/assets/migrations/0_init/migration.sql b/example/android/app/src/main/assets/migrations/0_init/migration.sql
deleted file mode 100644
index d2e6651e..00000000
--- a/example/android/app/src/main/assets/migrations/0_init/migration.sql
+++ /dev/null
@@ -1,53 +0,0 @@
--- CreateTable
-CREATE TABLE "User" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "email" TEXT NOT NULL,
- "name" TEXT,
- "nick" TEXT
-);
-
--- CreateTable
-CREATE TABLE "Profile" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "bio" TEXT NOT NULL,
- "userId" INTEGER NOT NULL,
- CONSTRAINT "Profile_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User" ("id") ON DELETE RESTRICT ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "Post" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
- "updatedAt" DATETIME NOT NULL,
- "title" TEXT NOT NULL,
- "published" BOOLEAN NOT NULL DEFAULT false,
- "authorId" INTEGER NOT NULL,
- CONSTRAINT "Post_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User" ("id") ON DELETE RESTRICT ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "Category" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "name" TEXT NOT NULL
-);
-
--- CreateTable
-CREATE TABLE "_CategoryToPost" (
- "A" INTEGER NOT NULL,
- "B" INTEGER NOT NULL,
- CONSTRAINT "_CategoryToPost_A_fkey" FOREIGN KEY ("A") REFERENCES "Category" ("id") ON DELETE CASCADE ON UPDATE CASCADE,
- CONSTRAINT "_CategoryToPost_B_fkey" FOREIGN KEY ("B") REFERENCES "Post" ("id") ON DELETE CASCADE ON UPDATE CASCADE
-);
-
--- CreateIndex
-CREATE UNIQUE INDEX "User_email_key" ON "User"("email");
-
--- CreateIndex
-CREATE UNIQUE INDEX "Profile_userId_key" ON "Profile"("userId");
-
--- CreateIndex
-CREATE UNIQUE INDEX "_CategoryToPost_AB_unique" ON "_CategoryToPost"("A", "B");
-
--- CreateIndex
-CREATE INDEX "_CategoryToPost_B_index" ON "_CategoryToPost"("B");
-
diff --git a/example/android/app/src/main/assets/migrations/20240118142005_nick2/migration.sql b/example/android/app/src/main/assets/migrations/20240118142005_nick2/migration.sql
deleted file mode 100644
index 6af8f23f..00000000
--- a/example/android/app/src/main/assets/migrations/20240118142005_nick2/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "nick2" TEXT;
diff --git a/example/android/app/src/main/assets/migrations/20240119102352_nick3/migration.sql b/example/android/app/src/main/assets/migrations/20240119102352_nick3/migration.sql
deleted file mode 100644
index 42103e81..00000000
--- a/example/android/app/src/main/assets/migrations/20240119102352_nick3/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "nick3" TEXT;
diff --git a/example/android/app/src/main/assets/migrations/20240119143417_nick4/migration.sql b/example/android/app/src/main/assets/migrations/20240119143417_nick4/migration.sql
deleted file mode 100644
index 616a6b93..00000000
--- a/example/android/app/src/main/assets/migrations/20240119143417_nick4/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "nick4" TEXT;
diff --git a/example/android/app/src/main/assets/migrations/20240122145141_my_field/migration.sql b/example/android/app/src/main/assets/migrations/20240122145141_my_field/migration.sql
deleted file mode 100644
index 17fa170f..00000000
--- a/example/android/app/src/main/assets/migrations/20240122145141_my_field/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "myField" TEXT;
diff --git a/example/android/app/src/main/assets/migrations/migration_lock.toml b/example/android/app/src/main/assets/migrations/migration_lock.toml
deleted file mode 100644
index e5e5c470..00000000
--- a/example/android/app/src/main/assets/migrations/migration_lock.toml
+++ /dev/null
@@ -1,3 +0,0 @@
-# Please do not edit this file manually
-# It should be added in your version-control system (i.e. Git)
-provider = "sqlite"
\ No newline at end of file
diff --git a/example/android/app/src/main/java/com/prismaexample/MainActivity.kt b/example/android/app/src/main/java/com/prismaexample/MainActivity.kt
deleted file mode 100644
index 5459b2db..00000000
--- a/example/android/app/src/main/java/com/prismaexample/MainActivity.kt
+++ /dev/null
@@ -1,22 +0,0 @@
-package com.prismaexample
-
-import com.facebook.react.ReactActivity
-import com.facebook.react.ReactActivityDelegate
-import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.fabricEnabled
-import com.facebook.react.defaults.DefaultReactActivityDelegate
-
-class MainActivity : ReactActivity() {
-
- /**
- * Returns the name of the main component registered from JavaScript. This is used to schedule
- * rendering of the component.
- */
- override fun getMainComponentName(): String = "PrismaExample"
-
- /**
- * Returns the instance of the [ReactActivityDelegate]. We use [DefaultReactActivityDelegate]
- * which allows you to enable New Architecture with a single boolean flags [fabricEnabled]
- */
- override fun createReactActivityDelegate(): ReactActivityDelegate =
- DefaultReactActivityDelegate(this, mainComponentName, fabricEnabled)
-}
diff --git a/example/android/app/src/main/java/com/prismaexample/MainApplication.kt b/example/android/app/src/main/java/com/prismaexample/MainApplication.kt
deleted file mode 100644
index b86a256f..00000000
--- a/example/android/app/src/main/java/com/prismaexample/MainApplication.kt
+++ /dev/null
@@ -1,45 +0,0 @@
-package com.prismaexample
-
-import android.app.Application
-import com.facebook.react.PackageList
-import com.facebook.react.ReactApplication
-import com.facebook.react.ReactHost
-import com.facebook.react.ReactNativeHost
-import com.facebook.react.ReactPackage
-import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.load
-import com.facebook.react.defaults.DefaultReactHost.getDefaultReactHost
-import com.facebook.react.defaults.DefaultReactNativeHost
-import com.facebook.react.flipper.ReactNativeFlipper
-import com.facebook.soloader.SoLoader
-
-class MainApplication : Application(), ReactApplication {
-
- override val reactNativeHost: ReactNativeHost =
- object : DefaultReactNativeHost(this) {
- override fun getPackages(): List {
- // Packages that cannot be autolinked yet can be added manually here, for example:
- // packages.add(new MyReactNativePackage());
- return PackageList(this).packages
- }
-
- override fun getJSMainModuleName(): String = "index"
-
- override fun getUseDeveloperSupport(): Boolean = BuildConfig.DEBUG
-
- override val isNewArchEnabled: Boolean = BuildConfig.IS_NEW_ARCHITECTURE_ENABLED
- override val isHermesEnabled: Boolean = BuildConfig.IS_HERMES_ENABLED
- }
-
- override val reactHost: ReactHost
- get() = getDefaultReactHost(this.applicationContext, reactNativeHost)
-
- override fun onCreate() {
- super.onCreate()
- SoLoader.init(this, false)
- if (BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
- // If you opted-in for the New Architecture, we load the native entry point for this app.
- load()
- }
- ReactNativeFlipper.initializeFlipper(this, reactNativeHost.reactInstanceManager)
- }
-}
diff --git a/example/android/app/src/main/res/drawable/rn_edit_text_material.xml b/example/android/app/src/main/res/drawable/rn_edit_text_material.xml
deleted file mode 100644
index 73b37e4d..00000000
--- a/example/android/app/src/main/res/drawable/rn_edit_text_material.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
diff --git a/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
deleted file mode 100644
index a2f59082..00000000
Binary files a/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png b/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
deleted file mode 100644
index 1b523998..00000000
Binary files a/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
deleted file mode 100644
index ff10afd6..00000000
Binary files a/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png b/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
deleted file mode 100644
index 115a4c76..00000000
Binary files a/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
deleted file mode 100644
index dcd3cd80..00000000
Binary files a/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png b/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
deleted file mode 100644
index 459ca609..00000000
Binary files a/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
deleted file mode 100644
index 8ca12fe0..00000000
Binary files a/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png b/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
deleted file mode 100644
index 8e19b410..00000000
Binary files a/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
deleted file mode 100644
index b824ebdd..00000000
Binary files a/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ
diff --git a/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png b/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
deleted file mode 100644
index 4c19a13c..00000000
Binary files a/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png and /dev/null differ
diff --git a/example/android/app/src/main/res/values/strings.xml b/example/android/app/src/main/res/values/strings.xml
deleted file mode 100644
index c518fb81..00000000
--- a/example/android/app/src/main/res/values/strings.xml
+++ /dev/null
@@ -1,3 +0,0 @@
-
- PrismaExample
-
diff --git a/example/android/app/src/main/res/values/styles.xml b/example/android/app/src/main/res/values/styles.xml
deleted file mode 100644
index 7ba83a2a..00000000
--- a/example/android/app/src/main/res/values/styles.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
-
-
-
diff --git a/example/android/app/src/main/res/xml/network_security_config.xml b/example/android/app/src/main/res/xml/network_security_config.xml
deleted file mode 100644
index c7755e76..00000000
--- a/example/android/app/src/main/res/xml/network_security_config.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
- 10.0.2.2
- localhost
-
-
\ No newline at end of file
diff --git a/example/android/build.gradle b/example/android/build.gradle
deleted file mode 100644
index fb94af9f..00000000
--- a/example/android/build.gradle
+++ /dev/null
@@ -1,30 +0,0 @@
-buildscript {
- ext {
- buildToolsVersion = "34.0.0"
- minSdkVersion = 21
- compileSdkVersion = 34
- targetSdkVersion = 34
- ndkVersion = "25.1.8937393"
- kotlinVersion = "1.8.0"
- }
- repositories {
- google()
- mavenCentral()
-
- }
- dependencies {
- classpath("com.android.tools.build:gradle")
- classpath("com.facebook.react:react-native-gradle-plugin")
- classpath("org.jetbrains.kotlin:kotlin-gradle-plugin")
- }
-}
-
-allprojects {
- repositories {
- maven {
- url "$rootDir/../node_modules/detox/Detox-android"
- }
- }
-}
-
-apply plugin: "com.facebook.react.rootproject"
diff --git a/example/android/gradle.properties b/example/android/gradle.properties
deleted file mode 100644
index a46a5b90..00000000
--- a/example/android/gradle.properties
+++ /dev/null
@@ -1,41 +0,0 @@
-# Project-wide Gradle settings.
-
-# IDE (e.g. Android Studio) users:
-# Gradle settings configured through the IDE *will override*
-# any settings specified in this file.
-
-# For more details on how to configure your build environment visit
-# http://www.gradle.org/docs/current/userguide/build_environment.html
-
-# Specifies the JVM arguments used for the daemon process.
-# The setting is particularly useful for tweaking memory settings.
-# Default value: -Xmx512m -XX:MaxMetaspaceSize=256m
-org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m
-
-# When configured, Gradle will run in incubating parallel mode.
-# This option should only be used with decoupled projects. More details, visit
-# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
-# org.gradle.parallel=true
-
-# AndroidX package structure to make it clearer which packages are bundled with the
-# Android operating system, and which are packaged with your app's APK
-# https://developer.android.com/topic/libraries/support-library/androidx-rn
-android.useAndroidX=true
-# Automatically convert third-party libraries to use AndroidX
-android.enableJetifier=true
-
-# Use this property to specify which architecture you want to build.
-# You can also override it from the CLI using
-# ./gradlew -PreactNativeArchitectures=x86_64
-reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64
-
-# Use this property to enable support to the new architecture.
-# This will allow you to use TurboModules and the Fabric render in
-# your application. You should enable this flag either if you want
-# to write custom TurboModules/Fabric components OR use libraries that
-# are providing them.
-newArchEnabled=false
-
-# Use this property to enable or disable the Hermes JS engine.
-# If set to false, you will be using JSC instead.
-hermesEnabled=true
diff --git a/example/android/gradle/wrapper/gradle-wrapper.jar b/example/android/gradle/wrapper/gradle-wrapper.jar
deleted file mode 100644
index 7f93135c..00000000
Binary files a/example/android/gradle/wrapper/gradle-wrapper.jar and /dev/null differ
diff --git a/example/android/gradle/wrapper/gradle-wrapper.properties b/example/android/gradle/wrapper/gradle-wrapper.properties
deleted file mode 100644
index d11cdd90..00000000
--- a/example/android/gradle/wrapper/gradle-wrapper.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-distributionBase=GRADLE_USER_HOME
-distributionPath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip
-networkTimeout=10000
-validateDistributionUrl=true
-zipStoreBase=GRADLE_USER_HOME
-zipStorePath=wrapper/dists
diff --git a/example/android/gradlew b/example/android/gradlew
deleted file mode 100755
index 0adc8e1a..00000000
--- a/example/android/gradlew
+++ /dev/null
@@ -1,249 +0,0 @@
-#!/bin/sh
-
-#
-# Copyright © 2015-2021 the original authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# https://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-##############################################################################
-#
-# Gradle start up script for POSIX generated by Gradle.
-#
-# Important for running:
-#
-# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
-# noncompliant, but you have some other compliant shell such as ksh or
-# bash, then to run this script, type that shell name before the whole
-# command line, like:
-#
-# ksh Gradle
-#
-# Busybox and similar reduced shells will NOT work, because this script
-# requires all of these POSIX shell features:
-# * functions;
-# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
-# «${var#prefix}», «${var%suffix}», and «$( cmd )»;
-# * compound commands having a testable exit status, especially «case»;
-# * various built-in commands including «command», «set», and «ulimit».
-#
-# Important for patching:
-#
-# (2) This script targets any POSIX shell, so it avoids extensions provided
-# by Bash, Ksh, etc; in particular arrays are avoided.
-#
-# The "traditional" practice of packing multiple parameters into a
-# space-separated string is a well documented source of bugs and security
-# problems, so this is (mostly) avoided, by progressively accumulating
-# options in "$@", and eventually passing that to Java.
-#
-# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
-# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
-# see the in-line comments for details.
-#
-# There are tweaks for specific operating systems such as AIX, CygWin,
-# Darwin, MinGW, and NonStop.
-#
-# (3) This script is generated from the Groovy template
-# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
-# within the Gradle project.
-#
-# You can find Gradle at https://github.com/gradle/gradle/.
-#
-##############################################################################
-
-# Attempt to set APP_HOME
-
-# Resolve links: $0 may be a link
-app_path=$0
-
-# Need this for daisy-chained symlinks.
-while
- APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
- [ -h "$app_path" ]
-do
- ls=$( ls -ld "$app_path" )
- link=${ls#*' -> '}
- case $link in #(
- /*) app_path=$link ;; #(
- *) app_path=$APP_HOME$link ;;
- esac
-done
-
-# This is normally unused
-# shellcheck disable=SC2034
-APP_BASE_NAME=${0##*/}
-# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
-APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
-
-# Use the maximum available, or set MAX_FD != -1 to use that value.
-MAX_FD=maximum
-
-warn () {
- echo "$*"
-} >&2
-
-die () {
- echo
- echo "$*"
- echo
- exit 1
-} >&2
-
-# OS specific support (must be 'true' or 'false').
-cygwin=false
-msys=false
-darwin=false
-nonstop=false
-case "$( uname )" in #(
- CYGWIN* ) cygwin=true ;; #(
- Darwin* ) darwin=true ;; #(
- MSYS* | MINGW* ) msys=true ;; #(
- NONSTOP* ) nonstop=true ;;
-esac
-
-CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
-
-
-# Determine the Java command to use to start the JVM.
-if [ -n "$JAVA_HOME" ] ; then
- if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
- # IBM's JDK on AIX uses strange locations for the executables
- JAVACMD=$JAVA_HOME/jre/sh/java
- else
- JAVACMD=$JAVA_HOME/bin/java
- fi
- if [ ! -x "$JAVACMD" ] ; then
- die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
-
-Please set the JAVA_HOME variable in your environment to match the
-location of your Java installation."
- fi
-else
- JAVACMD=java
- if ! command -v java >/dev/null 2>&1
- then
- die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
-
-Please set the JAVA_HOME variable in your environment to match the
-location of your Java installation."
- fi
-fi
-
-# Increase the maximum file descriptors if we can.
-if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
- case $MAX_FD in #(
- max*)
- # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
- # shellcheck disable=SC3045
- MAX_FD=$( ulimit -H -n ) ||
- warn "Could not query maximum file descriptor limit"
- esac
- case $MAX_FD in #(
- '' | soft) :;; #(
- *)
- # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
- # shellcheck disable=SC3045
- ulimit -n "$MAX_FD" ||
- warn "Could not set maximum file descriptor limit to $MAX_FD"
- esac
-fi
-
-# Collect all arguments for the java command, stacking in reverse order:
-# * args from the command line
-# * the main class name
-# * -classpath
-# * -D...appname settings
-# * --module-path (only if needed)
-# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
-
-# For Cygwin or MSYS, switch paths to Windows format before running java
-if "$cygwin" || "$msys" ; then
- APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
- CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
-
- JAVACMD=$( cygpath --unix "$JAVACMD" )
-
- # Now convert the arguments - kludge to limit ourselves to /bin/sh
- for arg do
- if
- case $arg in #(
- -*) false ;; # don't mess with options #(
- /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath
- [ -e "$t" ] ;; #(
- *) false ;;
- esac
- then
- arg=$( cygpath --path --ignore --mixed "$arg" )
- fi
- # Roll the args list around exactly as many times as the number of
- # args, so each arg winds up back in the position where it started, but
- # possibly modified.
- #
- # NB: a `for` loop captures its iteration list before it begins, so
- # changing the positional parameters here affects neither the number of
- # iterations, nor the values presented in `arg`.
- shift # remove old arg
- set -- "$@" "$arg" # push replacement arg
- done
-fi
-
-
-# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
-
-# Collect all arguments for the java command;
-# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
-# shell script including quotes and variable substitutions, so put them in
-# double quotes to make sure that they get re-expanded; and
-# * put everything else in single quotes, so that it's not re-expanded.
-
-set -- \
- "-Dorg.gradle.appname=$APP_BASE_NAME" \
- -classpath "$CLASSPATH" \
- org.gradle.wrapper.GradleWrapperMain \
- "$@"
-
-# Stop when "xargs" is not available.
-if ! command -v xargs >/dev/null 2>&1
-then
- die "xargs is not available"
-fi
-
-# Use "xargs" to parse quoted args.
-#
-# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
-#
-# In Bash we could simply go:
-#
-# readarray ARGS < <( xargs -n1 <<<"$var" ) &&
-# set -- "${ARGS[@]}" "$@"
-#
-# but POSIX shell has neither arrays nor command substitution, so instead we
-# post-process each arg (as a line of input to sed) to backslash-escape any
-# character that might be a shell metacharacter, then use eval to reverse
-# that process (while maintaining the separation between arguments), and wrap
-# the whole thing up as a single "set" statement.
-#
-# This will of course break if any of these variables contains a newline or
-# an unmatched quote.
-#
-
-eval "set -- $(
- printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
- xargs -n1 |
- sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
- tr '\n' ' '
- )" '"$@"'
-
-exec "$JAVACMD" "$@"
diff --git a/example/android/gradlew.bat b/example/android/gradlew.bat
deleted file mode 100644
index 93e3f59f..00000000
--- a/example/android/gradlew.bat
+++ /dev/null
@@ -1,92 +0,0 @@
-@rem
-@rem Copyright 2015 the original author or authors.
-@rem
-@rem Licensed under the Apache License, Version 2.0 (the "License");
-@rem you may not use this file except in compliance with the License.
-@rem You may obtain a copy of the License at
-@rem
-@rem https://www.apache.org/licenses/LICENSE-2.0
-@rem
-@rem Unless required by applicable law or agreed to in writing, software
-@rem distributed under the License is distributed on an "AS IS" BASIS,
-@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-@rem See the License for the specific language governing permissions and
-@rem limitations under the License.
-@rem
-
-@if "%DEBUG%"=="" @echo off
-@rem ##########################################################################
-@rem
-@rem Gradle startup script for Windows
-@rem
-@rem ##########################################################################
-
-@rem Set local scope for the variables with windows NT shell
-if "%OS%"=="Windows_NT" setlocal
-
-set DIRNAME=%~dp0
-if "%DIRNAME%"=="" set DIRNAME=.
-@rem This is normally unused
-set APP_BASE_NAME=%~n0
-set APP_HOME=%DIRNAME%
-
-@rem Resolve any "." and ".." in APP_HOME to make it shorter.
-for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
-
-@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
-
-@rem Find java.exe
-if defined JAVA_HOME goto findJavaFromJavaHome
-
-set JAVA_EXE=java.exe
-%JAVA_EXE% -version >NUL 2>&1
-if %ERRORLEVEL% equ 0 goto execute
-
-echo.
-echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
-echo.
-echo Please set the JAVA_HOME variable in your environment to match the
-echo location of your Java installation.
-
-goto fail
-
-:findJavaFromJavaHome
-set JAVA_HOME=%JAVA_HOME:"=%
-set JAVA_EXE=%JAVA_HOME%/bin/java.exe
-
-if exist "%JAVA_EXE%" goto execute
-
-echo.
-echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
-echo.
-echo Please set the JAVA_HOME variable in your environment to match the
-echo location of your Java installation.
-
-goto fail
-
-:execute
-@rem Setup the command line
-
-set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
-
-
-@rem Execute Gradle
-"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
-
-:end
-@rem End local scope for the variables with windows NT shell
-if %ERRORLEVEL% equ 0 goto mainEnd
-
-:fail
-rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
-rem the _cmd.exe /c_ return code!
-set EXIT_CODE=%ERRORLEVEL%
-if %EXIT_CODE% equ 0 set EXIT_CODE=1
-if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
-exit /b %EXIT_CODE%
-
-:mainEnd
-if "%OS%"=="Windows_NT" endlocal
-
-:omega
diff --git a/example/android/settings.gradle b/example/android/settings.gradle
deleted file mode 100644
index f2bca566..00000000
--- a/example/android/settings.gradle
+++ /dev/null
@@ -1,4 +0,0 @@
-rootProject.name = 'PrismaExample'
-apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
-include ':app'
-includeBuild('../node_modules/@react-native/gradle-plugin')
diff --git a/example/app.json b/example/app.json
deleted file mode 100644
index 6b936fd7..00000000
--- a/example/app.json
+++ /dev/null
@@ -1,4 +0,0 @@
-{
- "name": "PrismaExample",
- "displayName": "PrismaExample"
-}
diff --git a/example/babel.config.js b/example/babel.config.js
deleted file mode 100644
index d3622460..00000000
--- a/example/babel.config.js
+++ /dev/null
@@ -1,19 +0,0 @@
-/* eslint-env node */
-const path = require('path');
-
-const pak = require('../package.json');
-
-module.exports = {
- presets: ['module:@react-native/babel-preset', 'nativewind/babel'],
- plugins: [
- [
- 'module-resolver',
- {
- extensions: ['.tsx', '.ts', '.js', '.json'],
- alias: {
- [pak.name]: path.join(__dirname, '..', pak.source),
- },
- },
- ],
- ],
-};
diff --git a/example/dev.db b/example/dev.db
deleted file mode 100644
index a36fd182..00000000
Binary files a/example/dev.db and /dev/null differ
diff --git a/example/dev.db-journal b/example/dev.db-journal
deleted file mode 100644
index 8265c0d5..00000000
Binary files a/example/dev.db-journal and /dev/null differ
diff --git a/example/e2e/jest.config.js b/example/e2e/jest.config.js
deleted file mode 100644
index 4f980203..00000000
--- a/example/e2e/jest.config.js
+++ /dev/null
@@ -1,12 +0,0 @@
-/** @type {import('@jest/types').Config.InitialOptions} */
-module.exports = {
- rootDir: '..',
- testMatch: ['/e2e/**/*.test.js'],
- testTimeout: 120000,
- maxWorkers: 1,
- globalSetup: 'detox/runners/jest/globalSetup',
- globalTeardown: 'detox/runners/jest/globalTeardown',
- reporters: ['detox/runners/jest/reporter'],
- testEnvironment: 'detox/runners/jest/testEnvironment',
- verbose: true,
-};
diff --git a/example/e2e/starter.test.js b/example/e2e/starter.test.js
deleted file mode 100644
index a1c5c14b..00000000
--- a/example/e2e/starter.test.js
+++ /dev/null
@@ -1,14 +0,0 @@
-/* eslint-disable no-undef */
-describe('Example', () => {
- beforeAll(async () => {
- await device.launchApp();
- });
-
- beforeEach(async () => {
- await device.reloadReactNative();
- });
-
- it('Show basic test passed indicator', async () => {
- await expect(element(by.id('test_indicator'))).toBeVisible();
- });
-});
diff --git a/example/global.css b/example/global.css
deleted file mode 100644
index b5c61c95..00000000
--- a/example/global.css
+++ /dev/null
@@ -1,3 +0,0 @@
-@tailwind base;
-@tailwind components;
-@tailwind utilities;
diff --git a/example/globals.d.ts b/example/globals.d.ts
deleted file mode 100644
index a13e3136..00000000
--- a/example/globals.d.ts
+++ /dev/null
@@ -1 +0,0 @@
-///
diff --git a/example/index.js b/example/index.js
deleted file mode 100644
index e77bb4a6..00000000
--- a/example/index.js
+++ /dev/null
@@ -1,6 +0,0 @@
-import { AppRegistry } from 'react-native';
-
-import { name as appName } from './app.json';
-import App from './src/App';
-
-AppRegistry.registerComponent(appName, () => App);
diff --git a/example/ios/.xcode.env b/example/ios/.xcode.env
deleted file mode 100644
index 3d5782c7..00000000
--- a/example/ios/.xcode.env
+++ /dev/null
@@ -1,11 +0,0 @@
-# This `.xcode.env` file is versioned and is used to source the environment
-# used when running script phases inside Xcode.
-# To customize your local environment, you can create an `.xcode.env.local`
-# file that is not versioned.
-
-# NODE_BINARY variable contains the PATH to the node executable.
-#
-# Customize the NODE_BINARY variable here.
-# For example, to use nvm with brew, add the following line
-# . "$(brew --prefix nvm)/nvm.sh" --no-use
-export NODE_BINARY=$(command -v node)
diff --git a/example/ios/.xcode.env.local b/example/ios/.xcode.env.local
deleted file mode 100644
index 36623492..00000000
--- a/example/ios/.xcode.env.local
+++ /dev/null
@@ -1 +0,0 @@
-export NODE_BINARY=$(command -v node)
\ No newline at end of file
diff --git a/example/ios/File.swift b/example/ios/File.swift
deleted file mode 100644
index cb2608fd..00000000
--- a/example/ios/File.swift
+++ /dev/null
@@ -1,6 +0,0 @@
-//
-// File.swift
-// PrismaExample
-//
-
-import Foundation
diff --git a/example/ios/Podfile b/example/ios/Podfile
deleted file mode 100644
index 05475bc6..00000000
--- a/example/ios/Podfile
+++ /dev/null
@@ -1,34 +0,0 @@
-# Resolve react_native_pods.rb with node to allow for hoisting
-require Pod::Executable.execute_command('node', ['-p',
- 'require.resolve(
- "react-native/scripts/react_native_pods.rb",
- {paths: [process.argv[1]]},
- )', __dir__]).strip
-
-platform :ios, min_ios_version_supported
-prepare_react_native_project!
-inhibit_all_warnings!
-
-linkage = ENV['USE_FRAMEWORKS']
-if linkage != nil
- Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green
- use_frameworks! :linkage => linkage.to_sym
-end
-
-target 'PrismaExample' do
- config = use_native_modules!
-
- use_react_native!(
- :path => config[:reactNativePath],
- :app_path => "#{Pod::Config.instance.installation_root}/.."
- )
-
- post_install do |installer|
- # https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/react_native_pods.rb#L197-L202
- react_native_post_install(
- installer,
- config[:reactNativePath],
- :mac_catalyst_enabled => false
- )
- end
-end
diff --git a/example/ios/Podfile.lock b/example/ios/Podfile.lock
deleted file mode 100644
index d04dbb46..00000000
--- a/example/ios/Podfile.lock
+++ /dev/null
@@ -1,1315 +0,0 @@
-PODS:
- - boost (1.83.0)
- - DoubleConversion (1.1.6)
- - FBLazyVector (0.73.2)
- - FBReactNativeSpec (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - RCTRequired (= 0.73.2)
- - RCTTypeSafety (= 0.73.2)
- - React-Core (= 0.73.2)
- - React-jsi (= 0.73.2)
- - ReactCommon/turbomodule/core (= 0.73.2)
- - fmt (6.2.1)
- - GCDWebServer (3.5.4):
- - GCDWebServer/Core (= 3.5.4)
- - GCDWebServer/Core (3.5.4)
- - glog (0.3.5)
- - hermes-engine (0.73.2):
- - hermes-engine/Pre-built (= 0.73.2)
- - hermes-engine/Pre-built (0.73.2)
- - libevent (2.1.12)
- - RCT-Folly (2022.05.16.00):
- - boost
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - RCT-Folly/Default (= 2022.05.16.00)
- - RCT-Folly/Default (2022.05.16.00):
- - boost
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - RCT-Folly/Fabric (2022.05.16.00):
- - boost
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - RCT-Folly/Futures (2022.05.16.00):
- - boost
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - libevent
- - RCTRequired (0.73.2)
- - RCTTypeSafety (0.73.2):
- - FBLazyVector (= 0.73.2)
- - RCTRequired (= 0.73.2)
- - React-Core (= 0.73.2)
- - React (0.73.2):
- - React-Core (= 0.73.2)
- - React-Core/DevSupport (= 0.73.2)
- - React-Core/RCTWebSocket (= 0.73.2)
- - React-RCTActionSheet (= 0.73.2)
- - React-RCTAnimation (= 0.73.2)
- - React-RCTBlob (= 0.73.2)
- - React-RCTImage (= 0.73.2)
- - React-RCTLinking (= 0.73.2)
- - React-RCTNetwork (= 0.73.2)
- - React-RCTSettings (= 0.73.2)
- - React-RCTText (= 0.73.2)
- - React-RCTVibration (= 0.73.2)
- - React-callinvoker (0.73.2)
- - React-Codegen (0.73.2):
- - DoubleConversion
- - FBReactNativeSpec
- - glog
- - hermes-engine
- - RCT-Folly
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-jsi
- - React-jsiexecutor
- - React-NativeModulesApple
- - React-rncore
- - ReactCommon/turbomodule/bridging
- - ReactCommon/turbomodule/core
- - React-Core (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default (= 0.73.2)
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/CoreModulesHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/Default (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/DevSupport (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default (= 0.73.2)
- - React-Core/RCTWebSocket (= 0.73.2)
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-jsinspector (= 0.73.2)
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTActionSheetHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTAnimationHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTBlobHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTImageHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTLinkingHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTNetworkHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTSettingsHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTTextHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTVibrationHeaders (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-Core/RCTWebSocket (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Core/Default (= 0.73.2)
- - React-cxxreact
- - React-hermes
- - React-jsi
- - React-jsiexecutor
- - React-perflogger
- - React-runtimescheduler
- - React-utils
- - SocketRocket (= 0.6.1)
- - Yoga
- - React-CoreModules (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - RCTTypeSafety (= 0.73.2)
- - React-Codegen
- - React-Core/CoreModulesHeaders (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-NativeModulesApple
- - React-RCTBlob
- - React-RCTImage (= 0.73.2)
- - ReactCommon
- - SocketRocket (= 0.6.1)
- - React-cxxreact (0.73.2):
- - boost (= 1.83.0)
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-callinvoker (= 0.73.2)
- - React-debug (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-jsinspector (= 0.73.2)
- - React-logger (= 0.73.2)
- - React-perflogger (= 0.73.2)
- - React-runtimeexecutor (= 0.73.2)
- - React-debug (0.73.2)
- - React-Fabric (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-Fabric/animations (= 0.73.2)
- - React-Fabric/attributedstring (= 0.73.2)
- - React-Fabric/componentregistry (= 0.73.2)
- - React-Fabric/componentregistrynative (= 0.73.2)
- - React-Fabric/components (= 0.73.2)
- - React-Fabric/core (= 0.73.2)
- - React-Fabric/imagemanager (= 0.73.2)
- - React-Fabric/leakchecker (= 0.73.2)
- - React-Fabric/mounting (= 0.73.2)
- - React-Fabric/scheduler (= 0.73.2)
- - React-Fabric/telemetry (= 0.73.2)
- - React-Fabric/templateprocessor (= 0.73.2)
- - React-Fabric/textlayoutmanager (= 0.73.2)
- - React-Fabric/uimanager (= 0.73.2)
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/animations (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/attributedstring (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/componentregistry (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/componentregistrynative (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-Fabric/components/inputaccessory (= 0.73.2)
- - React-Fabric/components/legacyviewmanagerinterop (= 0.73.2)
- - React-Fabric/components/modal (= 0.73.2)
- - React-Fabric/components/rncore (= 0.73.2)
- - React-Fabric/components/root (= 0.73.2)
- - React-Fabric/components/safeareaview (= 0.73.2)
- - React-Fabric/components/scrollview (= 0.73.2)
- - React-Fabric/components/text (= 0.73.2)
- - React-Fabric/components/textinput (= 0.73.2)
- - React-Fabric/components/unimplementedview (= 0.73.2)
- - React-Fabric/components/view (= 0.73.2)
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/inputaccessory (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/legacyviewmanagerinterop (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/modal (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/rncore (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/root (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/safeareaview (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/scrollview (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/text (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/textinput (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/unimplementedview (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/components/view (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - Yoga
- - React-Fabric/core (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/imagemanager (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/leakchecker (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/mounting (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/scheduler (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/telemetry (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/templateprocessor (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/textlayoutmanager (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-Fabric/uimanager
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-Fabric/uimanager (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-cxxreact
- - React-debug
- - React-graphics
- - React-jsi
- - React-jsiexecutor
- - React-logger
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - ReactCommon/turbomodule/core
- - React-FabricImage (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - RCTRequired (= 0.73.2)
- - RCTTypeSafety (= 0.73.2)
- - React-Fabric
- - React-graphics
- - React-ImageManager
- - React-jsi
- - React-jsiexecutor (= 0.73.2)
- - React-logger
- - React-rendererdebug
- - React-utils
- - ReactCommon
- - Yoga
- - React-graphics (0.73.2):
- - glog
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - React-Core/Default (= 0.73.2)
- - React-utils
- - React-hermes (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - RCT-Folly/Futures (= 2022.05.16.00)
- - React-cxxreact (= 0.73.2)
- - React-jsi
- - React-jsiexecutor (= 0.73.2)
- - React-jsinspector (= 0.73.2)
- - React-perflogger (= 0.73.2)
- - React-ImageManager (0.73.2):
- - glog
- - RCT-Folly/Fabric
- - React-Core/Default
- - React-debug
- - React-Fabric
- - React-graphics
- - React-rendererdebug
- - React-utils
- - React-jserrorhandler (0.73.2):
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - React-debug
- - React-jsi
- - React-Mapbuffer
- - React-jsi (0.73.2):
- - boost (= 1.83.0)
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-jsiexecutor (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-cxxreact (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-perflogger (= 0.73.2)
- - React-jsinspector (0.73.2)
- - React-logger (0.73.2):
- - glog
- - React-Mapbuffer (0.73.2):
- - glog
- - React-debug
- - react-native-http-bridge-refurbished (1.3.2):
- - GCDWebServer
- - React
- - react-native-network-info (5.2.1):
- - React
- - react-native-prisma (0.2.1):
- - glog
- - RCT-Folly (= 2022.05.16.00)
- - React
- - React-callinvoker
- - React-Core
- - react-native-quick-base64 (2.0.8):
- - React-Core
- - React-nativeconfig (0.73.2)
- - React-NativeModulesApple (0.73.2):
- - glog
- - hermes-engine
- - React-callinvoker
- - React-Core
- - React-cxxreact
- - React-jsi
- - React-runtimeexecutor
- - ReactCommon/turbomodule/bridging
- - ReactCommon/turbomodule/core
- - React-perflogger (0.73.2)
- - React-RCTActionSheet (0.73.2):
- - React-Core/RCTActionSheetHeaders (= 0.73.2)
- - React-RCTAnimation (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - RCTTypeSafety
- - React-Codegen
- - React-Core/RCTAnimationHeaders
- - React-jsi
- - React-NativeModulesApple
- - ReactCommon
- - React-RCTAppDelegate (0.73.2):
- - RCT-Folly
- - RCTRequired
- - RCTTypeSafety
- - React-Core
- - React-CoreModules
- - React-hermes
- - React-nativeconfig
- - React-NativeModulesApple
- - React-RCTFabric
- - React-RCTImage
- - React-RCTNetwork
- - React-runtimescheduler
- - ReactCommon
- - React-RCTBlob (0.73.2):
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-Codegen
- - React-Core/RCTBlobHeaders
- - React-Core/RCTWebSocket
- - React-jsi
- - React-NativeModulesApple
- - React-RCTNetwork
- - ReactCommon
- - React-RCTFabric (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly/Fabric (= 2022.05.16.00)
- - React-Core
- - React-debug
- - React-Fabric
- - React-FabricImage
- - React-graphics
- - React-ImageManager
- - React-jsi
- - React-nativeconfig
- - React-RCTImage
- - React-RCTText
- - React-rendererdebug
- - React-runtimescheduler
- - React-utils
- - Yoga
- - React-RCTImage (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - RCTTypeSafety
- - React-Codegen
- - React-Core/RCTImageHeaders
- - React-jsi
- - React-NativeModulesApple
- - React-RCTNetwork
- - ReactCommon
- - React-RCTLinking (0.73.2):
- - React-Codegen
- - React-Core/RCTLinkingHeaders (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-NativeModulesApple
- - ReactCommon
- - ReactCommon/turbomodule/core (= 0.73.2)
- - React-RCTNetwork (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - RCTTypeSafety
- - React-Codegen
- - React-Core/RCTNetworkHeaders
- - React-jsi
- - React-NativeModulesApple
- - ReactCommon
- - React-RCTSettings (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - RCTTypeSafety
- - React-Codegen
- - React-Core/RCTSettingsHeaders
- - React-jsi
- - React-NativeModulesApple
- - ReactCommon
- - React-RCTText (0.73.2):
- - React-Core/RCTTextHeaders (= 0.73.2)
- - Yoga
- - React-RCTVibration (0.73.2):
- - RCT-Folly (= 2022.05.16.00)
- - React-Codegen
- - React-Core/RCTVibrationHeaders
- - React-jsi
- - React-NativeModulesApple
- - ReactCommon
- - React-rendererdebug (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - RCT-Folly (= 2022.05.16.00)
- - React-debug
- - React-rncore (0.73.2)
- - React-runtimeexecutor (0.73.2):
- - React-jsi (= 0.73.2)
- - React-runtimescheduler (0.73.2):
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-callinvoker
- - React-cxxreact
- - React-debug
- - React-jsi
- - React-rendererdebug
- - React-runtimeexecutor
- - React-utils
- - React-utils (0.73.2):
- - glog
- - RCT-Folly (= 2022.05.16.00)
- - React-debug
- - ReactCommon (0.73.2):
- - React-logger (= 0.73.2)
- - ReactCommon/turbomodule (= 0.73.2)
- - ReactCommon/turbomodule (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-callinvoker (= 0.73.2)
- - React-cxxreact (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-logger (= 0.73.2)
- - React-perflogger (= 0.73.2)
- - ReactCommon/turbomodule/bridging (= 0.73.2)
- - ReactCommon/turbomodule/core (= 0.73.2)
- - ReactCommon/turbomodule/bridging (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-callinvoker (= 0.73.2)
- - React-cxxreact (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-logger (= 0.73.2)
- - React-perflogger (= 0.73.2)
- - ReactCommon/turbomodule/core (0.73.2):
- - DoubleConversion
- - fmt (~> 6.2.1)
- - glog
- - hermes-engine
- - RCT-Folly (= 2022.05.16.00)
- - React-callinvoker (= 0.73.2)
- - React-cxxreact (= 0.73.2)
- - React-jsi (= 0.73.2)
- - React-logger (= 0.73.2)
- - React-perflogger (= 0.73.2)
- - RNReanimated (3.7.2):
- - glog
- - RCT-Folly (= 2022.05.16.00)
- - React-Core
- - ReactCommon/turbomodule/core
- - SocketRocket (0.6.1)
- - Yoga (1.14.0)
-
-DEPENDENCIES:
- - boost (from `../node_modules/react-native/third-party-podspecs/boost.podspec`)
- - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`)
- - FBLazyVector (from `../node_modules/react-native/Libraries/FBLazyVector`)
- - FBReactNativeSpec (from `../node_modules/react-native/React/FBReactNativeSpec`)
- - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`)
- - hermes-engine (from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`)
- - libevent (~> 2.1.12)
- - RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)
- - RCT-Folly/Fabric (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)
- - RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`)
- - RCTTypeSafety (from `../node_modules/react-native/Libraries/TypeSafety`)
- - React (from `../node_modules/react-native/`)
- - React-callinvoker (from `../node_modules/react-native/ReactCommon/callinvoker`)
- - React-Codegen (from `build/generated/ios`)
- - React-Core (from `../node_modules/react-native/`)
- - React-Core/RCTWebSocket (from `../node_modules/react-native/`)
- - React-CoreModules (from `../node_modules/react-native/React/CoreModules`)
- - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`)
- - React-debug (from `../node_modules/react-native/ReactCommon/react/debug`)
- - React-Fabric (from `../node_modules/react-native/ReactCommon`)
- - React-FabricImage (from `../node_modules/react-native/ReactCommon`)
- - React-graphics (from `../node_modules/react-native/ReactCommon/react/renderer/graphics`)
- - React-hermes (from `../node_modules/react-native/ReactCommon/hermes`)
- - React-ImageManager (from `../node_modules/react-native/ReactCommon/react/renderer/imagemanager/platform/ios`)
- - React-jserrorhandler (from `../node_modules/react-native/ReactCommon/jserrorhandler`)
- - React-jsi (from `../node_modules/react-native/ReactCommon/jsi`)
- - React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`)
- - React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector-modern`)
- - React-logger (from `../node_modules/react-native/ReactCommon/logger`)
- - React-Mapbuffer (from `../node_modules/react-native/ReactCommon`)
- - react-native-http-bridge-refurbished (from `../node_modules/react-native-http-bridge-refurbished`)
- - react-native-network-info (from `../node_modules/react-native-network-info`)
- - react-native-prisma (from `../..`)
- - react-native-quick-base64 (from `../node_modules/react-native-quick-base64`)
- - React-nativeconfig (from `../node_modules/react-native/ReactCommon`)
- - React-NativeModulesApple (from `../node_modules/react-native/ReactCommon/react/nativemodule/core/platform/ios`)
- - React-perflogger (from `../node_modules/react-native/ReactCommon/reactperflogger`)
- - React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`)
- - React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`)
- - React-RCTAppDelegate (from `../node_modules/react-native/Libraries/AppDelegate`)
- - React-RCTBlob (from `../node_modules/react-native/Libraries/Blob`)
- - React-RCTFabric (from `../node_modules/react-native/React`)
- - React-RCTImage (from `../node_modules/react-native/Libraries/Image`)
- - React-RCTLinking (from `../node_modules/react-native/Libraries/LinkingIOS`)
- - React-RCTNetwork (from `../node_modules/react-native/Libraries/Network`)
- - React-RCTSettings (from `../node_modules/react-native/Libraries/Settings`)
- - React-RCTText (from `../node_modules/react-native/Libraries/Text`)
- - React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`)
- - React-rendererdebug (from `../node_modules/react-native/ReactCommon/react/renderer/debug`)
- - React-rncore (from `../node_modules/react-native/ReactCommon`)
- - React-runtimeexecutor (from `../node_modules/react-native/ReactCommon/runtimeexecutor`)
- - React-runtimescheduler (from `../node_modules/react-native/ReactCommon/react/renderer/runtimescheduler`)
- - React-utils (from `../node_modules/react-native/ReactCommon/react/utils`)
- - ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`)
- - RNReanimated (from `../node_modules/react-native-reanimated`)
- - Yoga (from `../node_modules/react-native/ReactCommon/yoga`)
-
-SPEC REPOS:
- trunk:
- - fmt
- - GCDWebServer
- - libevent
- - SocketRocket
-
-EXTERNAL SOURCES:
- boost:
- :podspec: "../node_modules/react-native/third-party-podspecs/boost.podspec"
- DoubleConversion:
- :podspec: "../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec"
- FBLazyVector:
- :path: "../node_modules/react-native/Libraries/FBLazyVector"
- FBReactNativeSpec:
- :path: "../node_modules/react-native/React/FBReactNativeSpec"
- glog:
- :podspec: "../node_modules/react-native/third-party-podspecs/glog.podspec"
- hermes-engine:
- :podspec: "../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec"
- :tag: hermes-2023-11-17-RNv0.73.0-21043a3fc062be445e56a2c10ecd8be028dd9cc5
- RCT-Folly:
- :podspec: "../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec"
- RCTRequired:
- :path: "../node_modules/react-native/Libraries/RCTRequired"
- RCTTypeSafety:
- :path: "../node_modules/react-native/Libraries/TypeSafety"
- React:
- :path: "../node_modules/react-native/"
- React-callinvoker:
- :path: "../node_modules/react-native/ReactCommon/callinvoker"
- React-Codegen:
- :path: build/generated/ios
- React-Core:
- :path: "../node_modules/react-native/"
- React-CoreModules:
- :path: "../node_modules/react-native/React/CoreModules"
- React-cxxreact:
- :path: "../node_modules/react-native/ReactCommon/cxxreact"
- React-debug:
- :path: "../node_modules/react-native/ReactCommon/react/debug"
- React-Fabric:
- :path: "../node_modules/react-native/ReactCommon"
- React-FabricImage:
- :path: "../node_modules/react-native/ReactCommon"
- React-graphics:
- :path: "../node_modules/react-native/ReactCommon/react/renderer/graphics"
- React-hermes:
- :path: "../node_modules/react-native/ReactCommon/hermes"
- React-ImageManager:
- :path: "../node_modules/react-native/ReactCommon/react/renderer/imagemanager/platform/ios"
- React-jserrorhandler:
- :path: "../node_modules/react-native/ReactCommon/jserrorhandler"
- React-jsi:
- :path: "../node_modules/react-native/ReactCommon/jsi"
- React-jsiexecutor:
- :path: "../node_modules/react-native/ReactCommon/jsiexecutor"
- React-jsinspector:
- :path: "../node_modules/react-native/ReactCommon/jsinspector-modern"
- React-logger:
- :path: "../node_modules/react-native/ReactCommon/logger"
- React-Mapbuffer:
- :path: "../node_modules/react-native/ReactCommon"
- react-native-http-bridge-refurbished:
- :path: "../node_modules/react-native-http-bridge-refurbished"
- react-native-network-info:
- :path: "../node_modules/react-native-network-info"
- react-native-prisma:
- :path: "../.."
- react-native-quick-base64:
- :path: "../node_modules/react-native-quick-base64"
- React-nativeconfig:
- :path: "../node_modules/react-native/ReactCommon"
- React-NativeModulesApple:
- :path: "../node_modules/react-native/ReactCommon/react/nativemodule/core/platform/ios"
- React-perflogger:
- :path: "../node_modules/react-native/ReactCommon/reactperflogger"
- React-RCTActionSheet:
- :path: "../node_modules/react-native/Libraries/ActionSheetIOS"
- React-RCTAnimation:
- :path: "../node_modules/react-native/Libraries/NativeAnimation"
- React-RCTAppDelegate:
- :path: "../node_modules/react-native/Libraries/AppDelegate"
- React-RCTBlob:
- :path: "../node_modules/react-native/Libraries/Blob"
- React-RCTFabric:
- :path: "../node_modules/react-native/React"
- React-RCTImage:
- :path: "../node_modules/react-native/Libraries/Image"
- React-RCTLinking:
- :path: "../node_modules/react-native/Libraries/LinkingIOS"
- React-RCTNetwork:
- :path: "../node_modules/react-native/Libraries/Network"
- React-RCTSettings:
- :path: "../node_modules/react-native/Libraries/Settings"
- React-RCTText:
- :path: "../node_modules/react-native/Libraries/Text"
- React-RCTVibration:
- :path: "../node_modules/react-native/Libraries/Vibration"
- React-rendererdebug:
- :path: "../node_modules/react-native/ReactCommon/react/renderer/debug"
- React-rncore:
- :path: "../node_modules/react-native/ReactCommon"
- React-runtimeexecutor:
- :path: "../node_modules/react-native/ReactCommon/runtimeexecutor"
- React-runtimescheduler:
- :path: "../node_modules/react-native/ReactCommon/react/renderer/runtimescheduler"
- React-utils:
- :path: "../node_modules/react-native/ReactCommon/react/utils"
- ReactCommon:
- :path: "../node_modules/react-native/ReactCommon"
- RNReanimated:
- :path: "../node_modules/react-native-reanimated"
- Yoga:
- :path: "../node_modules/react-native/ReactCommon/yoga"
-
-SPEC CHECKSUMS:
- boost: d3f49c53809116a5d38da093a8aa78bf551aed09
- DoubleConversion: fea03f2699887d960129cc54bba7e52542b6f953
- FBLazyVector: fbc4957d9aa695250b55d879c1d86f79d7e69ab4
- FBReactNativeSpec: 86de768f89901ef6ed3207cd686362189d64ac88
- fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9
- GCDWebServer: 2c156a56c8226e2d5c0c3f208a3621ccffbe3ce4
- glog: c5d68082e772fa1c511173d6b30a9de2c05a69a2
- hermes-engine: b361c9ef5ef3cda53f66e195599b47e1f84ffa35
- libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913
- RCT-Folly: 7169b2b1c44399c76a47b5deaaba715eeeb476c0
- RCTRequired: 9b1e7e262745fb671e33c51c1078d093bd30e322
- RCTTypeSafety: a759e3b086eccf3e2cbf2493d22f28e082f958e6
- React: 805f5dd55bbdb92c36b4914c64aaae4c97d358dc
- React-callinvoker: 6a697867607c990c2c2c085296ee32cfb5e47c01
- React-Codegen: c4447ffa339f4e7a22e0c9c800eec9084f31899c
- React-Core: 49f66fecc7695464e9b7bc7dc7cd9473d2c60584
- React-CoreModules: 710e7c557a1a8180bd1645f5b4bf79f4bd3f5417
- React-cxxreact: 345857b5e4be000c0527df78be3b41a0677a20ce
- React-debug: f1637bce73342b2f6eee4982508fdfb088667a87
- React-Fabric: 4dfcff8f14d8e5a7a60b11b7862dad2a9d99c65b
- React-FabricImage: 4a9e9510b7f28bbde6a743b18c0cb941a142e938
- React-graphics: dd5af9d8b1b45171fd6933e19fed522f373bcb10
- React-hermes: a52d183a5cf8ccb7020ce3df4275b89d01e6b53e
- React-ImageManager: c5b7db131eff71443d7f3a8d686fd841d18befd3
- React-jserrorhandler: 97a6a12e2344c3c4fdd7ba1edefb005215c732f8
- React-jsi: a182068133f80918cd0eec77875abaf943a0b6be
- React-jsiexecutor: dacd00ce8a18fc00a0ae6c25e3015a6437e5d2e8
- React-jsinspector: 03644c063fc3621c9a4e8bf263a8150909129618
- React-logger: 66b168e2b2bee57bd8ce9e69f739d805732a5570
- React-Mapbuffer: 9ee041e1d7be96da6d76a251f92e72b711c651d6
- react-native-http-bridge-refurbished: 88fe66aa55e63807bd8cbaa372c062bc76ed4962
- react-native-network-info: d1290ffc0bd0709e11436f5b8d7f605dcc5c4530
- react-native-prisma: abb2f1b788c7fde4f056fa7d125fa82e706fa8dd
- react-native-quick-base64: 777057ea4286f806b00259ede65dc79c7c706320
- React-nativeconfig: d753fbbc8cecc8ae413d615599ac378bbf6999bb
- React-NativeModulesApple: 964f4eeab1b4325e8b6a799cf4444c3fd4eb0a9c
- React-perflogger: 29efe63b7ef5fbaaa50ef6eaa92482f98a24b97e
- React-RCTActionSheet: 69134c62aefd362027b20da01cd5d14ffd39db3f
- React-RCTAnimation: 3b5a57087c7a5e727855b803d643ac1d445488f5
- React-RCTAppDelegate: a3ce9b69c0620a1717d08e826d4dc7ad8a3a3cae
- React-RCTBlob: 26ea660f2be1e6de62f2d2ad9a9c7b9bfabb786f
- React-RCTFabric: bb6dbbff2f80b9489f8b2f1d2554aa040aa2e3cd
- React-RCTImage: 27b27f4663df9e776d0549ed2f3536213e793f1b
- React-RCTLinking: 962880ce9d0e2ea83fd182953538fc4ed757d4da
- React-RCTNetwork: 73a756b44d4ad584bae13a5f1484e3ce12accac8
- React-RCTSettings: 6d7f8d807f05de3d01cfb182d14e5f400716faac
- React-RCTText: 73006e95ca359595c2510c1c0114027c85a6ddd3
- React-RCTVibration: 599f427f9cbdd9c4bf38959ca020e8fef0717211
- React-rendererdebug: f2946e0a1c3b906e71555a7c4a39aa6a6c0e639b
- React-rncore: 74030de0ffef7b1a3fb77941168624534cc9ae7f
- React-runtimeexecutor: 2d1f64f58193f00a3ad71d3f89c2bfbfe11cf5a5
- React-runtimescheduler: df8945a656356ff10f58f65a70820478bfcf33ad
- React-utils: f5bc61e7ea3325c0732ae2d755f4441940163b85
- ReactCommon: 45b5d4f784e869c44a6f5a8fad5b114ca8f78c53
- RNReanimated: 3850671fd0c67051ea8e1e648e8c3e86bf3a28eb
- SocketRocket: f32cd54efbe0f095c4d7594881e52619cfe80b17
- Yoga: 13c8ef87792450193e117976337b8527b49e8c03
-
-PODFILE CHECKSUM: 0485f7e52cf89aa2ec3fcb550f67bb9b58bd9c2b
-
-COCOAPODS: 1.15.2
diff --git a/example/ios/PrismaExample-Bridging-Header.h b/example/ios/PrismaExample-Bridging-Header.h
deleted file mode 100644
index e11d920b..00000000
--- a/example/ios/PrismaExample-Bridging-Header.h
+++ /dev/null
@@ -1,3 +0,0 @@
-//
-// Use this file to import your target's public headers that you would like to expose to Swift.
-//
diff --git a/example/ios/PrismaExample.xcodeproj/project.pbxproj b/example/ios/PrismaExample.xcodeproj/project.pbxproj
deleted file mode 100644
index 2526ad6f..00000000
--- a/example/ios/PrismaExample.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,527 +0,0 @@
-// !$*UTF8*$!
-{
- archiveVersion = 1;
- classes = {
- };
- objectVersion = 54;
- objects = {
-
-/* Begin PBXBuildFile section */
- 0C80B921A6F3F58F76C31292 /* libPods-PrismaExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5DCACB8F33CDC322A6C60F78 /* libPods-PrismaExample.a */; };
- 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.mm */; };
- 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
- 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
- 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
- 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
- 00E356F21AD99517003FC87E /* PrismaExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PrismaExampleTests.m; sourceTree = ""; };
- 13B07F961A680F5B00A75B9A /* Prisma.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Prisma.app; sourceTree = BUILT_PRODUCTS_DIR; };
- 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = PrismaExample/AppDelegate.h; sourceTree = ""; };
- 13B07FB01A68108700A75B9A /* AppDelegate.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = AppDelegate.mm; path = PrismaExample/AppDelegate.mm; sourceTree = ""; };
- 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = PrismaExample/Images.xcassets; sourceTree = ""; };
- 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = PrismaExample/Info.plist; sourceTree = ""; };
- 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = PrismaExample/main.m; sourceTree = ""; };
- 19F6CBCC0A4E27FBF8BF4A61 /* libPods-PrismaExample-PrismaExampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-PrismaExample-PrismaExampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
- 3B4392A12AC88292D35C810B /* Pods-PrismaExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PrismaExample.debug.xcconfig"; path = "Target Support Files/Pods-PrismaExample/Pods-PrismaExample.debug.xcconfig"; sourceTree = ""; };
- 5709B34CF0A7D63546082F79 /* Pods-PrismaExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PrismaExample.release.xcconfig"; path = "Target Support Files/Pods-PrismaExample/Pods-PrismaExample.release.xcconfig"; sourceTree = ""; };
- 5B7EB9410499542E8C5724F5 /* Pods-PrismaExample-PrismaExampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PrismaExample-PrismaExampleTests.debug.xcconfig"; path = "Target Support Files/Pods-PrismaExample-PrismaExampleTests/Pods-PrismaExample-PrismaExampleTests.debug.xcconfig"; sourceTree = ""; };
- 5DCACB8F33CDC322A6C60F78 /* libPods-PrismaExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-PrismaExample.a"; sourceTree = BUILT_PRODUCTS_DIR; };
- 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = PrismaExample/LaunchScreen.storyboard; sourceTree = ""; };
- 89C6BE57DB24E9ADA2F236DE /* Pods-PrismaExample-PrismaExampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PrismaExample-PrismaExampleTests.release.xcconfig"; path = "Target Support Files/Pods-PrismaExample-PrismaExampleTests/Pods-PrismaExample-PrismaExampleTests.release.xcconfig"; sourceTree = ""; };
- ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
- 13B07F8C1A680F5B00A75B9A /* Frameworks */ = {
- isa = PBXFrameworksBuildPhase;
- buildActionMask = 2147483647;
- files = (
- 0C80B921A6F3F58F76C31292 /* libPods-PrismaExample.a in Frameworks */,
- );
- runOnlyForDeploymentPostprocessing = 0;
- };
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
- 00E356EF1AD99517003FC87E /* PrismaExampleTests */ = {
- isa = PBXGroup;
- children = (
- 00E356F21AD99517003FC87E /* PrismaExampleTests.m */,
- 00E356F01AD99517003FC87E /* Supporting Files */,
- );
- path = PrismaExampleTests;
- sourceTree = "";
- };
- 00E356F01AD99517003FC87E /* Supporting Files */ = {
- isa = PBXGroup;
- children = (
- 00E356F11AD99517003FC87E /* Info.plist */,
- );
- name = "Supporting Files";
- sourceTree = "";
- };
- 13B07FAE1A68108700A75B9A /* PrismaExample */ = {
- isa = PBXGroup;
- children = (
- 13B07FAF1A68108700A75B9A /* AppDelegate.h */,
- 13B07FB01A68108700A75B9A /* AppDelegate.mm */,
- 13B07FB51A68108700A75B9A /* Images.xcassets */,
- 13B07FB61A68108700A75B9A /* Info.plist */,
- 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */,
- 13B07FB71A68108700A75B9A /* main.m */,
- );
- name = PrismaExample;
- sourceTree = "";
- };
- 2D16E6871FA4F8E400B85C8A /* Frameworks */ = {
- isa = PBXGroup;
- children = (
- ED297162215061F000B7C4FE /* JavaScriptCore.framework */,
- 5DCACB8F33CDC322A6C60F78 /* libPods-PrismaExample.a */,
- 19F6CBCC0A4E27FBF8BF4A61 /* libPods-PrismaExample-PrismaExampleTests.a */,
- );
- name = Frameworks;
- sourceTree = "";
- };
- 832341AE1AAA6A7D00B99B32 /* Libraries */ = {
- isa = PBXGroup;
- children = (
- );
- name = Libraries;
- sourceTree = "";
- };
- 83CBB9F61A601CBA00E9B192 = {
- isa = PBXGroup;
- children = (
- 13B07FAE1A68108700A75B9A /* PrismaExample */,
- 832341AE1AAA6A7D00B99B32 /* Libraries */,
- 00E356EF1AD99517003FC87E /* PrismaExampleTests */,
- 83CBBA001A601CBA00E9B192 /* Products */,
- 2D16E6871FA4F8E400B85C8A /* Frameworks */,
- BBD78D7AC51CEA395F1C20DB /* Pods */,
- );
- indentWidth = 2;
- sourceTree = "";
- tabWidth = 2;
- usesTabs = 0;
- };
- 83CBBA001A601CBA00E9B192 /* Products */ = {
- isa = PBXGroup;
- children = (
- 13B07F961A680F5B00A75B9A /* Prisma.app */,
- );
- name = Products;
- sourceTree = "";
- };
- BBD78D7AC51CEA395F1C20DB /* Pods */ = {
- isa = PBXGroup;
- children = (
- 3B4392A12AC88292D35C810B /* Pods-PrismaExample.debug.xcconfig */,
- 5709B34CF0A7D63546082F79 /* Pods-PrismaExample.release.xcconfig */,
- 5B7EB9410499542E8C5724F5 /* Pods-PrismaExample-PrismaExampleTests.debug.xcconfig */,
- 89C6BE57DB24E9ADA2F236DE /* Pods-PrismaExample-PrismaExampleTests.release.xcconfig */,
- );
- path = Pods;
- sourceTree = "";
- };
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
- 13B07F861A680F5B00A75B9A /* PrismaExample */ = {
- isa = PBXNativeTarget;
- buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "PrismaExample" */;
- buildPhases = (
- C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */,
- 13B07F871A680F5B00A75B9A /* Sources */,
- 13B07F8C1A680F5B00A75B9A /* Frameworks */,
- 13B07F8E1A680F5B00A75B9A /* Resources */,
- 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
- 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */,
- E235C05ADACE081382539298 /* [CP] Copy Pods Resources */,
- );
- buildRules = (
- );
- dependencies = (
- );
- name = PrismaExample;
- productName = PrismaExample;
- productReference = 13B07F961A680F5B00A75B9A /* Prisma.app */;
- productType = "com.apple.product-type.application";
- };
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
- 83CBB9F71A601CBA00E9B192 /* Project object */ = {
- isa = PBXProject;
- attributes = {
- LastUpgradeCheck = 1210;
- TargetAttributes = {
- 13B07F861A680F5B00A75B9A = {
- LastSwiftMigration = 1120;
- };
- };
- };
- buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "PrismaExample" */;
- compatibilityVersion = "Xcode 12.0";
- developmentRegion = en;
- hasScannedForEncodings = 0;
- knownRegions = (
- en,
- Base,
- );
- mainGroup = 83CBB9F61A601CBA00E9B192;
- productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */;
- projectDirPath = "";
- projectRoot = "";
- targets = (
- 13B07F861A680F5B00A75B9A /* PrismaExample */,
- );
- };
-/* End PBXProject section */
-
-/* Begin PBXResourcesBuildPhase section */
- 13B07F8E1A680F5B00A75B9A /* Resources */ = {
- isa = PBXResourcesBuildPhase;
- buildActionMask = 2147483647;
- files = (
- 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */,
- 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
- );
- runOnlyForDeploymentPostprocessing = 0;
- };
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXShellScriptBuildPhase section */
- 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputPaths = (
- "$(SRCROOT)/.xcode.env.local",
- "$(SRCROOT)/.xcode.env",
- );
- name = "Bundle React Native code and images";
- outputPaths = (
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "set -e\n\nWITH_ENVIRONMENT=\"../node_modules/react-native/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"../node_modules/react-native/scripts/react-native-xcode.sh\"\nPRISMA_MIGRATIONS=\"../../copy-migrations.sh\"\n\n/bin/sh -c $PRISMA_MIGRATIONS\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n";
- };
- 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputFileListPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-PrismaExample/Pods-PrismaExample-frameworks-${CONFIGURATION}-input-files.xcfilelist",
- );
- name = "[CP] Embed Pods Frameworks";
- outputFileListPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-PrismaExample/Pods-PrismaExample-frameworks-${CONFIGURATION}-output-files.xcfilelist",
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-PrismaExample/Pods-PrismaExample-frameworks.sh\"\n";
- showEnvVarsInLog = 0;
- };
- C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputFileListPaths = (
- );
- inputPaths = (
- "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
- "${PODS_ROOT}/Manifest.lock",
- );
- name = "[CP] Check Pods Manifest.lock";
- outputFileListPaths = (
- );
- outputPaths = (
- "$(DERIVED_FILE_DIR)/Pods-PrismaExample-checkManifestLockResult.txt",
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
- showEnvVarsInLog = 0;
- };
- E235C05ADACE081382539298 /* [CP] Copy Pods Resources */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputFileListPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-PrismaExample/Pods-PrismaExample-resources-${CONFIGURATION}-input-files.xcfilelist",
- );
- name = "[CP] Copy Pods Resources";
- outputFileListPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-PrismaExample/Pods-PrismaExample-resources-${CONFIGURATION}-output-files.xcfilelist",
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-PrismaExample/Pods-PrismaExample-resources.sh\"\n";
- showEnvVarsInLog = 0;
- };
-/* End PBXShellScriptBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
- 13B07F871A680F5B00A75B9A /* Sources */ = {
- isa = PBXSourcesBuildPhase;
- buildActionMask = 2147483647;
- files = (
- 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */,
- 13B07FC11A68108700A75B9A /* main.m in Sources */,
- );
- runOnlyForDeploymentPostprocessing = 0;
- };
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
- 13B07F941A680F5B00A75B9A /* Debug */ = {
- isa = XCBuildConfiguration;
- baseConfigurationReference = 3B4392A12AC88292D35C810B /* Pods-PrismaExample.debug.xcconfig */;
- buildSettings = {
- ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
- CLANG_ENABLE_MODULES = YES;
- CURRENT_PROJECT_VERSION = 1;
- DEVELOPMENT_TEAM = 24CMR7378R;
- ENABLE_BITCODE = NO;
- INFOPLIST_FILE = PrismaExample/Info.plist;
- INFOPLIST_KEY_CFBundleDisplayName = Prisma;
- LD_RUNPATH_SEARCH_PATHS = (
- "$(inherited)",
- "@executable_path/Frameworks",
- );
- MARKETING_VERSION = 1.0;
- OTHER_LDFLAGS = (
- "$(inherited)",
- "-ObjC",
- "-lc++",
- );
- PRODUCT_BUNDLE_IDENTIFIER = io.prisma.example;
- PRODUCT_NAME = Prisma;
- SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
- SUPPORTS_MACCATALYST = NO;
- SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO;
- SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO;
- SWIFT_OPTIMIZATION_LEVEL = "-Onone";
- SWIFT_VERSION = 5.0;
- TARGETED_DEVICE_FAMILY = 1;
- VERSIONING_SYSTEM = "apple-generic";
- };
- name = Debug;
- };
- 13B07F951A680F5B00A75B9A /* Release */ = {
- isa = XCBuildConfiguration;
- baseConfigurationReference = 5709B34CF0A7D63546082F79 /* Pods-PrismaExample.release.xcconfig */;
- buildSettings = {
- ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
- CLANG_ENABLE_MODULES = YES;
- CURRENT_PROJECT_VERSION = 1;
- DEVELOPMENT_TEAM = 24CMR7378R;
- INFOPLIST_FILE = PrismaExample/Info.plist;
- INFOPLIST_KEY_CFBundleDisplayName = Prisma;
- LD_RUNPATH_SEARCH_PATHS = (
- "$(inherited)",
- "@executable_path/Frameworks",
- );
- MARKETING_VERSION = 1.0;
- OTHER_LDFLAGS = (
- "$(inherited)",
- "-ObjC",
- "-lc++",
- );
- PRODUCT_BUNDLE_IDENTIFIER = io.prisma.example;
- PRODUCT_NAME = Prisma;
- SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
- SUPPORTS_MACCATALYST = NO;
- SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO;
- SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO;
- SWIFT_VERSION = 5.0;
- TARGETED_DEVICE_FAMILY = 1;
- VERSIONING_SYSTEM = "apple-generic";
- };
- name = Release;
- };
- 83CBBA201A601CBA00E9B192 /* Debug */ = {
- isa = XCBuildConfiguration;
- buildSettings = {
- ALWAYS_SEARCH_USER_PATHS = NO;
- CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
- CLANG_CXX_LANGUAGE_STANDARD = "c++20";
- CLANG_CXX_LIBRARY = "libc++";
- CLANG_ENABLE_MODULES = YES;
- CLANG_ENABLE_OBJC_ARC = YES;
- CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
- CLANG_WARN_BOOL_CONVERSION = YES;
- CLANG_WARN_COMMA = YES;
- CLANG_WARN_CONSTANT_CONVERSION = YES;
- CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
- CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
- CLANG_WARN_EMPTY_BODY = YES;
- CLANG_WARN_ENUM_CONVERSION = YES;
- CLANG_WARN_INFINITE_RECURSION = YES;
- CLANG_WARN_INT_CONVERSION = YES;
- CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
- CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
- CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
- CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
- CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
- CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
- CLANG_WARN_STRICT_PROTOTYPES = YES;
- CLANG_WARN_SUSPICIOUS_MOVE = YES;
- CLANG_WARN_UNREACHABLE_CODE = YES;
- CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
- "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
- COPY_PHASE_STRIP = NO;
- ENABLE_STRICT_OBJC_MSGSEND = YES;
- ENABLE_TESTABILITY = YES;
- "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386;
- GCC_C_LANGUAGE_STANDARD = gnu99;
- GCC_DYNAMIC_NO_PIC = NO;
- GCC_NO_COMMON_BLOCKS = YES;
- GCC_OPTIMIZATION_LEVEL = 0;
- GCC_PREPROCESSOR_DEFINITIONS = (
- "DEBUG=1",
- "$(inherited)",
- );
- GCC_SYMBOLS_PRIVATE_EXTERN = NO;
- GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
- GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
- GCC_WARN_UNDECLARED_SELECTOR = YES;
- GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
- GCC_WARN_UNUSED_FUNCTION = YES;
- GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 13.4;
- LD_RUNPATH_SEARCH_PATHS = (
- /usr/lib/swift,
- "$(inherited)",
- );
- LIBRARY_SEARCH_PATHS = (
- "\"$(SDKROOT)/usr/lib/swift\"",
- "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"",
- "\"$(inherited)\"",
- );
- MTL_ENABLE_DEBUG_INFO = YES;
- ONLY_ACTIVE_ARCH = YES;
- OTHER_CFLAGS = "$(inherited)";
- OTHER_CPLUSPLUSFLAGS = (
- "$(OTHER_CFLAGS)",
- "-DFOLLY_NO_CONFIG",
- "-DFOLLY_MOBILE=1",
- "-DFOLLY_USE_LIBCPP=1",
- "-DFOLLY_CFG_NO_COROUTINES=1",
- );
- OTHER_LDFLAGS = (
- "$(inherited)",
- "-Wl",
- "-ld_classic",
- );
- REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
- SDKROOT = iphoneos;
- USE_HERMES = true;
- };
- name = Debug;
- };
- 83CBBA211A601CBA00E9B192 /* Release */ = {
- isa = XCBuildConfiguration;
- buildSettings = {
- ALWAYS_SEARCH_USER_PATHS = NO;
- CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
- CLANG_CXX_LANGUAGE_STANDARD = "c++20";
- CLANG_CXX_LIBRARY = "libc++";
- CLANG_ENABLE_MODULES = YES;
- CLANG_ENABLE_OBJC_ARC = YES;
- CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
- CLANG_WARN_BOOL_CONVERSION = YES;
- CLANG_WARN_COMMA = YES;
- CLANG_WARN_CONSTANT_CONVERSION = YES;
- CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
- CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
- CLANG_WARN_EMPTY_BODY = YES;
- CLANG_WARN_ENUM_CONVERSION = YES;
- CLANG_WARN_INFINITE_RECURSION = YES;
- CLANG_WARN_INT_CONVERSION = YES;
- CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
- CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
- CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
- CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
- CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
- CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
- CLANG_WARN_STRICT_PROTOTYPES = YES;
- CLANG_WARN_SUSPICIOUS_MOVE = YES;
- CLANG_WARN_UNREACHABLE_CODE = YES;
- CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
- "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
- COPY_PHASE_STRIP = YES;
- ENABLE_NS_ASSERTIONS = NO;
- ENABLE_STRICT_OBJC_MSGSEND = YES;
- "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386;
- GCC_C_LANGUAGE_STANDARD = gnu99;
- GCC_NO_COMMON_BLOCKS = YES;
- GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
- GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
- GCC_WARN_UNDECLARED_SELECTOR = YES;
- GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
- GCC_WARN_UNUSED_FUNCTION = YES;
- GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 13.4;
- LD_RUNPATH_SEARCH_PATHS = (
- /usr/lib/swift,
- "$(inherited)",
- );
- LIBRARY_SEARCH_PATHS = (
- "\"$(SDKROOT)/usr/lib/swift\"",
- "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"",
- "\"$(inherited)\"",
- );
- MTL_ENABLE_DEBUG_INFO = NO;
- OTHER_CFLAGS = "$(inherited)";
- OTHER_CPLUSPLUSFLAGS = (
- "$(OTHER_CFLAGS)",
- "-DFOLLY_NO_CONFIG",
- "-DFOLLY_MOBILE=1",
- "-DFOLLY_USE_LIBCPP=1",
- "-DFOLLY_CFG_NO_COROUTINES=1",
- );
- OTHER_LDFLAGS = (
- "$(inherited)",
- "-Wl",
- "-ld_classic",
- );
- REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
- SDKROOT = iphoneos;
- USE_HERMES = true;
- VALIDATE_PRODUCT = YES;
- };
- name = Release;
- };
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
- 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "PrismaExample" */ = {
- isa = XCConfigurationList;
- buildConfigurations = (
- 13B07F941A680F5B00A75B9A /* Debug */,
- 13B07F951A680F5B00A75B9A /* Release */,
- );
- defaultConfigurationIsVisible = 0;
- defaultConfigurationName = Release;
- };
- 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "PrismaExample" */ = {
- isa = XCConfigurationList;
- buildConfigurations = (
- 83CBBA201A601CBA00E9B192 /* Debug */,
- 83CBBA211A601CBA00E9B192 /* Release */,
- );
- defaultConfigurationIsVisible = 0;
- defaultConfigurationName = Release;
- };
-/* End XCConfigurationList section */
- };
- rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */;
-}
diff --git a/example/ios/PrismaExample.xcodeproj/xcshareddata/xcschemes/Debug.xcscheme b/example/ios/PrismaExample.xcodeproj/xcshareddata/xcschemes/Debug.xcscheme
deleted file mode 100644
index d614870b..00000000
--- a/example/ios/PrismaExample.xcodeproj/xcshareddata/xcschemes/Debug.xcscheme
+++ /dev/null
@@ -1,86 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/example/ios/PrismaExample.xcodeproj/xcshareddata/xcschemes/Release.xcscheme b/example/ios/PrismaExample.xcodeproj/xcshareddata/xcschemes/Release.xcscheme
deleted file mode 100644
index ad3ee8e9..00000000
--- a/example/ios/PrismaExample.xcodeproj/xcshareddata/xcschemes/Release.xcscheme
+++ /dev/null
@@ -1,88 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/example/ios/PrismaExample.xcworkspace/contents.xcworkspacedata b/example/ios/PrismaExample.xcworkspace/contents.xcworkspacedata
deleted file mode 100644
index 34d332a0..00000000
--- a/example/ios/PrismaExample.xcworkspace/contents.xcworkspacedata
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
-
-
-
-
diff --git a/example/ios/PrismaExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/example/ios/PrismaExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
deleted file mode 100644
index 18d98100..00000000
--- a/example/ios/PrismaExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
- IDEDidComputeMac32BitWarning
-
-
-
diff --git a/example/ios/PrismaExample/AppDelegate.h b/example/ios/PrismaExample/AppDelegate.h
deleted file mode 100644
index 5d280825..00000000
--- a/example/ios/PrismaExample/AppDelegate.h
+++ /dev/null
@@ -1,6 +0,0 @@
-#import
-#import
-
-@interface AppDelegate : RCTAppDelegate
-
-@end
diff --git a/example/ios/PrismaExample/AppDelegate.mm b/example/ios/PrismaExample/AppDelegate.mm
deleted file mode 100644
index 399c48db..00000000
--- a/example/ios/PrismaExample/AppDelegate.mm
+++ /dev/null
@@ -1,33 +0,0 @@
-#import "AppDelegate.h"
-#import "GCDWebServer/GCDWebServer.h"
-#import
-
-@implementation AppDelegate
-
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
- self.moduleName = @"PrismaExample";
- // You can add your custom initial props in the dictionary below.
- // They will be passed down to the ViewController used by React Native.
- self.initialProps = @{};
-
- [GCDWebServer setLogLevel:4];
-
- return [super application:application didFinishLaunchingWithOptions:launchOptions];
-}
-
-- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge
-{
- return [self getBundleURL];
-}
-
-- (NSURL *)getBundleURL
-{
-#if DEBUG
- return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index"];
-#else
- return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
-#endif
-}
-
-@end
diff --git a/example/ios/PrismaExample/Images.xcassets/AppIcon.appiconset/Contents.json b/example/ios/PrismaExample/Images.xcassets/AppIcon.appiconset/Contents.json
deleted file mode 100644
index f156cb6f..00000000
--- a/example/ios/PrismaExample/Images.xcassets/AppIcon.appiconset/Contents.json
+++ /dev/null
@@ -1,14 +0,0 @@
-{
- "images" : [
- {
- "filename" : "Frame 20.png",
- "idiom" : "universal",
- "platform" : "ios",
- "size" : "1024x1024"
- }
- ],
- "info" : {
- "author" : "xcode",
- "version" : 1
- }
-}
diff --git a/example/ios/PrismaExample/Images.xcassets/AppIcon.appiconset/Frame 20.png b/example/ios/PrismaExample/Images.xcassets/AppIcon.appiconset/Frame 20.png
deleted file mode 100644
index a5a32ce9..00000000
Binary files a/example/ios/PrismaExample/Images.xcassets/AppIcon.appiconset/Frame 20.png and /dev/null differ
diff --git a/example/ios/PrismaExample/Images.xcassets/Contents.json b/example/ios/PrismaExample/Images.xcassets/Contents.json
deleted file mode 100644
index 73c00596..00000000
--- a/example/ios/PrismaExample/Images.xcassets/Contents.json
+++ /dev/null
@@ -1,6 +0,0 @@
-{
- "info" : {
- "author" : "xcode",
- "version" : 1
- }
-}
diff --git a/example/ios/PrismaExample/Images.xcassets/Logo.imageset/Contents.json b/example/ios/PrismaExample/Images.xcassets/Logo.imageset/Contents.json
deleted file mode 100644
index 5b033657..00000000
--- a/example/ios/PrismaExample/Images.xcassets/Logo.imageset/Contents.json
+++ /dev/null
@@ -1,12 +0,0 @@
-{
- "images" : [
- {
- "filename" : "Frame 20.png",
- "idiom" : "universal"
- }
- ],
- "info" : {
- "author" : "xcode",
- "version" : 1
- }
-}
diff --git a/example/ios/PrismaExample/Images.xcassets/Logo.imageset/Frame 20.png b/example/ios/PrismaExample/Images.xcassets/Logo.imageset/Frame 20.png
deleted file mode 100644
index a5a32ce9..00000000
Binary files a/example/ios/PrismaExample/Images.xcassets/Logo.imageset/Frame 20.png and /dev/null differ
diff --git a/example/ios/PrismaExample/Info.plist b/example/ios/PrismaExample/Info.plist
deleted file mode 100644
index 7df94dfb..00000000
--- a/example/ios/PrismaExample/Info.plist
+++ /dev/null
@@ -1,51 +0,0 @@
-
-
-
-
- CFBundleDevelopmentRegion
- en
- CFBundleDisplayName
- Prisma
- CFBundleExecutable
- $(EXECUTABLE_NAME)
- CFBundleIdentifier
- $(PRODUCT_BUNDLE_IDENTIFIER)
- CFBundleInfoDictionaryVersion
- 6.0
- CFBundleName
- $(PRODUCT_NAME)
- CFBundlePackageType
- APPL
- CFBundleShortVersionString
- $(MARKETING_VERSION)
- CFBundleSignature
- ????
- CFBundleVersion
- $(CURRENT_PROJECT_VERSION)
- LSRequiresIPhoneOS
-
- NSAppTransportSecurity
-
- NSAllowsArbitraryLoads
-
- NSAllowsLocalNetworking
-
-
- NSLocationWhenInUseUsageDescription
-
- UILaunchStoryboardName
- LaunchScreen
- UIRequiredDeviceCapabilities
-
- armv7
-
- UISupportedInterfaceOrientations
-
- UIInterfaceOrientationPortrait
- UIInterfaceOrientationLandscapeLeft
- UIInterfaceOrientationLandscapeRight
-
- UIViewControllerBasedStatusBarAppearance
-
-
-
diff --git a/example/ios/PrismaExample/LaunchScreen.storyboard b/example/ios/PrismaExample/LaunchScreen.storyboard
deleted file mode 100644
index c27f5a17..00000000
--- a/example/ios/PrismaExample/LaunchScreen.storyboard
+++ /dev/null
@@ -1,36 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/example/ios/PrismaExample/main.m b/example/ios/PrismaExample/main.m
deleted file mode 100644
index d645c724..00000000
--- a/example/ios/PrismaExample/main.m
+++ /dev/null
@@ -1,10 +0,0 @@
-#import
-
-#import "AppDelegate.h"
-
-int main(int argc, char *argv[])
-{
- @autoreleasepool {
- return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
- }
-}
diff --git a/example/ios/PrismaExampleTests/Info.plist b/example/ios/PrismaExampleTests/Info.plist
deleted file mode 100644
index ba72822e..00000000
--- a/example/ios/PrismaExampleTests/Info.plist
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
- CFBundleDevelopmentRegion
- en
- CFBundleExecutable
- $(EXECUTABLE_NAME)
- CFBundleIdentifier
- $(PRODUCT_BUNDLE_IDENTIFIER)
- CFBundleInfoDictionaryVersion
- 6.0
- CFBundleName
- $(PRODUCT_NAME)
- CFBundlePackageType
- BNDL
- CFBundleShortVersionString
- 1.0
- CFBundleSignature
- ????
- CFBundleVersion
- 1
-
-
diff --git a/example/ios/PrismaExampleTests/PrismaExampleTests.m b/example/ios/PrismaExampleTests/PrismaExampleTests.m
deleted file mode 100644
index fbc04f84..00000000
--- a/example/ios/PrismaExampleTests/PrismaExampleTests.m
+++ /dev/null
@@ -1,66 +0,0 @@
-#import
-#import
-
-#import
-#import
-
-#define TIMEOUT_SECONDS 600
-#define TEXT_TO_LOOK_FOR @"Welcome to React"
-
-@interface PrismaExampleTests : XCTestCase
-
-@end
-
-@implementation PrismaExampleTests
-
-- (BOOL)findSubviewInView:(UIView *)view matching:(BOOL (^)(UIView *view))test
-{
- if (test(view)) {
- return YES;
- }
- for (UIView *subview in [view subviews]) {
- if ([self findSubviewInView:subview matching:test]) {
- return YES;
- }
- }
- return NO;
-}
-
-- (void)testRendersWelcomeScreen
-{
- UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController];
- NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS];
- BOOL foundElement = NO;
-
- __block NSString *redboxError = nil;
-#ifdef DEBUG
- RCTSetLogFunction(
- ^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) {
- if (level >= RCTLogLevelError) {
- redboxError = message;
- }
- });
-#endif
-
- while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) {
- [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
- [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
-
- foundElement = [self findSubviewInView:vc.view
- matching:^BOOL(UIView *view) {
- if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) {
- return YES;
- }
- return NO;
- }];
- }
-
-#ifdef DEBUG
- RCTSetLogFunction(RCTDefaultLogFunction);
-#endif
-
- XCTAssertNil(redboxError, @"RedBox error: %@", redboxError);
- XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS);
-}
-
-@end
diff --git a/example/ios/link-assets-manifest.json b/example/ios/link-assets-manifest.json
deleted file mode 100644
index f43dc5ad..00000000
--- a/example/ios/link-assets-manifest.json
+++ /dev/null
@@ -1,13 +0,0 @@
-{
- "migIndex": 1,
- "data": [
- {
- "path": "migrations/20240117094901_init/migration.sql",
- "sha1": "c2cba8c542661584c2409ac71985d902b25bdd71"
- },
- {
- "path": "migrations/migration_lock.toml",
- "sha1": "d31af1640ea175950b3b0e25f68481f74ef5d8ed"
- }
- ]
-}
diff --git a/example/metro.config.js b/example/metro.config.js
deleted file mode 100644
index e3999cb0..00000000
--- a/example/metro.config.js
+++ /dev/null
@@ -1,51 +0,0 @@
-/* eslint-env node */
-const { getDefaultConfig, mergeConfig } = require('@react-native/metro-config');
-const escape = require('escape-string-regexp');
-const exclusionList = require('metro-config/src/defaults/exclusionList');
-const { withNativeWind } = require('nativewind/metro');
-const path = require('path');
-
-const pak = require('../package.json');
-
-const root = path.resolve(__dirname, '..');
-const modules = Object.keys({ ...pak.peerDependencies });
-
-/**
- * Metro configuration
- * https://facebook.github.io/metro/docs/configuration
- *
- * @type {import('metro-config').MetroConfig}
- */
-const config = {
- watchFolders: [root],
-
- // We need to make sure that only one version is loaded for peerDependencies
- // So we block them at the root, and alias them to the versions in example's node_modules
- resolver: {
- blacklistRE: exclusionList(
- modules.map(
- (m) =>
- new RegExp(`^${escape(path.join(root, 'node_modules', m))}\\/.*$`)
- )
- ),
-
- extraNodeModules: modules.reduce((acc, name) => {
- acc[name] = path.join(__dirname, 'node_modules', name);
- return acc;
- }, {}),
- },
-
- transformer: {
- getTransformOptions: async () => ({
- transform: {
- experimentalImportSupport: false,
- inlineRequires: true,
- },
- }),
- },
-};
-
-module.exports = withNativeWind(
- mergeConfig(getDefaultConfig(__dirname), config),
- { input: './global.css' }
-);
diff --git a/example/migrations/0_init/migration.sql b/example/migrations/0_init/migration.sql
deleted file mode 100644
index d2e6651e..00000000
--- a/example/migrations/0_init/migration.sql
+++ /dev/null
@@ -1,53 +0,0 @@
--- CreateTable
-CREATE TABLE "User" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "email" TEXT NOT NULL,
- "name" TEXT,
- "nick" TEXT
-);
-
--- CreateTable
-CREATE TABLE "Profile" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "bio" TEXT NOT NULL,
- "userId" INTEGER NOT NULL,
- CONSTRAINT "Profile_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User" ("id") ON DELETE RESTRICT ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "Post" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
- "updatedAt" DATETIME NOT NULL,
- "title" TEXT NOT NULL,
- "published" BOOLEAN NOT NULL DEFAULT false,
- "authorId" INTEGER NOT NULL,
- CONSTRAINT "Post_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User" ("id") ON DELETE RESTRICT ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "Category" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "name" TEXT NOT NULL
-);
-
--- CreateTable
-CREATE TABLE "_CategoryToPost" (
- "A" INTEGER NOT NULL,
- "B" INTEGER NOT NULL,
- CONSTRAINT "_CategoryToPost_A_fkey" FOREIGN KEY ("A") REFERENCES "Category" ("id") ON DELETE CASCADE ON UPDATE CASCADE,
- CONSTRAINT "_CategoryToPost_B_fkey" FOREIGN KEY ("B") REFERENCES "Post" ("id") ON DELETE CASCADE ON UPDATE CASCADE
-);
-
--- CreateIndex
-CREATE UNIQUE INDEX "User_email_key" ON "User"("email");
-
--- CreateIndex
-CREATE UNIQUE INDEX "Profile_userId_key" ON "Profile"("userId");
-
--- CreateIndex
-CREATE UNIQUE INDEX "_CategoryToPost_AB_unique" ON "_CategoryToPost"("A", "B");
-
--- CreateIndex
-CREATE INDEX "_CategoryToPost_B_index" ON "_CategoryToPost"("B");
-
diff --git a/example/migrations/20240118142005_nick2/migration.sql b/example/migrations/20240118142005_nick2/migration.sql
deleted file mode 100644
index 6af8f23f..00000000
--- a/example/migrations/20240118142005_nick2/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "nick2" TEXT;
diff --git a/example/migrations/20240119102352_nick3/migration.sql b/example/migrations/20240119102352_nick3/migration.sql
deleted file mode 100644
index 42103e81..00000000
--- a/example/migrations/20240119102352_nick3/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "nick3" TEXT;
diff --git a/example/migrations/20240119143417_nick4/migration.sql b/example/migrations/20240119143417_nick4/migration.sql
deleted file mode 100644
index 616a6b93..00000000
--- a/example/migrations/20240119143417_nick4/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "nick4" TEXT;
diff --git a/example/migrations/20240122145141_my_field/migration.sql b/example/migrations/20240122145141_my_field/migration.sql
deleted file mode 100644
index 17fa170f..00000000
--- a/example/migrations/20240122145141_my_field/migration.sql
+++ /dev/null
@@ -1,2 +0,0 @@
--- AlterTable
-ALTER TABLE "User" ADD COLUMN "myField" TEXT;
diff --git a/example/migrations/migration_lock.toml b/example/migrations/migration_lock.toml
deleted file mode 100644
index e5e5c470..00000000
--- a/example/migrations/migration_lock.toml
+++ /dev/null
@@ -1,3 +0,0 @@
-# Please do not edit this file manually
-# It should be added in your version-control system (i.e. Git)
-provider = "sqlite"
\ No newline at end of file
diff --git a/example/package.json b/example/package.json
deleted file mode 100644
index 8439e183..00000000
--- a/example/package.json
+++ /dev/null
@@ -1,47 +0,0 @@
-{
- "name": "react-native-prisma-example",
- "version": "0.0.1",
- "private": true,
- "scripts": {
- "android": "react-native run-android",
- "ios": "react-native run-ios --simulator='iPhone 15' --scheme='Debug'",
- "start": "react-native start",
- "pods": "pod-install",
- "build:android": "cd android && ./gradlew assembleDebug --no-daemon --console=plain -PreactNativeArchitectures=arm64-v8a",
- "build:ios": "cd ios && xcodebuild -workspace PrismaExample.xcworkspace -scheme PrismaExample -configuration Debug -sdk iphonesimulator CC=clang CPLUSPLUS=clang++ LD=clang LDPLUSPLUS=clang++ GCC_OPTIMIZATION_LEVEL=0 GCC_PRECOMPILE_PREFIX_HEADER=YES ASSETCATALOG_COMPILER_OPTIMIZATION=time DEBUG_INFORMATION_FORMAT=dwarf COMPILER_INDEX_STORE_ENABLE=NO",
- "ios:release": "react-native run-ios --simulator='iPhone 15' --scheme='Release'",
- "prisma:generate": "prisma generate"
- },
- "dependencies": {
- "@prisma/client": "6.1.0-dev.17",
- "chance": "^1.1.11",
- "nativewind": "^4.0.23",
- "react": "18.2.0",
- "react-native": "0.73.2",
- "react-native-http-bridge-refurbished": "^1.2.9",
- "react-native-network-info": "^5.2.1",
- "react-native-quick-base64": "^2.0.8",
- "react-native-reanimated": "^3.7.2",
- "react-native-url-polyfill": "^2.0.0",
- "text-encoding": "^0.7.0"
- },
- "devDependencies": {
- "@babel/core": "^7.20.0",
- "@babel/preset-env": "^7.20.0",
- "@babel/runtime": "^7.20.0",
- "@react-native/babel-preset": "^0.73.18",
- "@react-native/metro-config": "^0.73.2",
- "@react-native/typescript-config": "^0.73.1",
- "@types/chance": "^1.1.6",
- "@types/text-encoding": "^0",
- "babel-plugin-module-resolver": "^5.0.0",
- "detox": "20.20.3",
- "jest": "^29",
- "pod-install": "0.2.0",
- "prisma": "6.1.0-dev.17",
- "tailwindcss": "^3.4.0"
- },
- "engines": {
- "node": ">=18"
- }
-}
diff --git a/example/react-native.config.js b/example/react-native.config.js
deleted file mode 100644
index 9ddf8c8f..00000000
--- a/example/react-native.config.js
+++ /dev/null
@@ -1,12 +0,0 @@
-/* eslint-env node */
-const path = require('path');
-
-const pak = require('../package.json');
-
-module.exports = {
- dependencies: {
- [pak.name]: {
- root: path.join(__dirname, '..'),
- },
- },
-};
diff --git a/example/schema.prisma b/example/schema.prisma
deleted file mode 100644
index 94f5d399..00000000
--- a/example/schema.prisma
+++ /dev/null
@@ -1,46 +0,0 @@
-generator client {
- provider = "prisma-client-js"
- previewFeatures = ["reactNative"]
-}
-
-datasource db {
- provider = "sqlite"
- url = "file:./dev.db"
-}
-
-model User {
- id Int @id @default(autoincrement())
- email String @unique
- name String?
- posts Post[]
- profile Profile?
- nick String?
- nick2 String?
- nick3 String?
- nick4 String?
- myField String?
-}
-
-model Profile {
- id Int @id @default(autoincrement())
- bio String
- user User @relation(fields: [userId], references: [id])
- userId Int @unique
-}
-
-model Post {
- id Int @id @default(autoincrement())
- createdAt DateTime @default(now())
- updatedAt DateTime @updatedAt
- title String
- published Boolean @default(false)
- author User @relation(fields: [authorId], references: [id])
- authorId Int
- categories Category[]
-}
-
-model Category {
- id Int @id @default(autoincrement())
- name String
- posts Post[]
-}
diff --git a/example/src/App.tsx b/example/src/App.tsx
deleted file mode 100644
index 88a7319f..00000000
--- a/example/src/App.tsx
+++ /dev/null
@@ -1,112 +0,0 @@
-import '@prisma/react-native';
-import React, { useEffect, useState } from 'react';
-import {
- Clipboard,
- SafeAreaView,
- ScrollView,
- Text,
- TouchableOpacity,
- View,
-} from 'react-native';
-import { NetworkInfo } from 'react-native-network-info';
-import { atob, btoa } from 'react-native-quick-base64';
-
-import 'react-native-url-polyfill/auto';
-import '../global.css';
-import { Button } from './Button';
-import './server';
-import {
- hooksPrisma,
- createRandomUser,
- deleteUsers,
- initializeDB,
- runE2EQuery,
- // createRandomUserGeneric,
-} from './db';
-
-// global.TextEncoder = require('text-encoding').TextEncoder;
-global.atob = atob;
-global.btoa = btoa;
-
-export default function App() {
- const [prismaTime, setPrismaTime] = useState(0);
- const [IP, setIP] = useState('');
- const [dbInitialized, setDbInitialized] = useState(false);
- const [e2eSuccess, setE2ESuccess] = useState(false);
-
- useEffect(() => {
- const setup = async () => {
- await initializeDB();
- NetworkInfo.getIPAddress().then((ip) => {
- setIP(`${ip}:3000`);
- });
- setDbInitialized(true);
- await runE2EQuery();
- setE2ESuccess(true);
- };
-
- setup();
- }, []);
-
- const createUser = async () => {
- const start = performance.now();
-
- await createRandomUser();
-
- const end = performance.now();
- setPrismaTime(end - start);
- };
-
- const users = hooksPrisma.user.useFindMany();
-
- if (!dbInitialized) {
- return (
-
- Initializing database...
-
- );
- }
-
- const copyIP = () => {
- Clipboard.setString(IP);
- console.warn('IP copied to clipboard');
- };
-
- return (
-
-
-
- ▲ Prisma
- {e2eSuccess ? (
-
- ) : (
-
- )}
-
-
-
- HTTP Server Running on Port 3000
-
-
-
-
- Engine Response
-
- {prismaTime.toFixed(0)}ms
-
-
- {JSON.stringify(users, null, 4)}
-
-
-
-
- {/* */}
-
- );
-}
diff --git a/example/src/Button.tsx b/example/src/Button.tsx
deleted file mode 100644
index 6a9c99e4..00000000
--- a/example/src/Button.tsx
+++ /dev/null
@@ -1,13 +0,0 @@
-import React from 'react';
-import { TouchableOpacity, Text } from 'react-native';
-
-export const Button = (props: { title: string; callback: any }) => {
- return (
-
- {props.title}
-
- );
-};
diff --git a/example/src/db.ts b/example/src/db.ts
deleted file mode 100644
index 0e331a2c..00000000
--- a/example/src/db.ts
+++ /dev/null
@@ -1,82 +0,0 @@
-import { PrismaClient } from '@prisma/client/react-native';
-import {
- reactiveHooksExtension,
- reactiveQueriesExtension,
-} from '@prisma/react-native';
-import Chance from 'chance';
-
-const chance = new Chance();
-
-const basePrisma = new PrismaClient({
- log: [{ emit: 'event', level: 'query' }],
-});
-
-export async function initializeDB() {
- try {
- await basePrisma.$applyPendingMigrations();
- } catch (e) {
- console.error(`failed to apply migrations: ${e}`);
- throw new Error(
- 'Applying migrations failed, your app is now in an inconsistent state. We cannot guarantee safety, it is now your responsability to reset the database or tell the user to re-install the app'
- );
- }
-}
-// You should always call this at the start of the application
-// failure to migrate might leave you with a non working app version
-
-// Examples of a reactive client for REACT
-export const hooksPrisma = basePrisma.$extends(reactiveHooksExtension());
-
-export async function createRandomUser() {
- await hooksPrisma.user.create({
- data: {
- email: chance.email(),
- name: chance.name(),
- },
- });
-}
-
-export async function deleteUsers() {
- return await hooksPrisma.user.deleteMany();
-}
-
-// A generic reactive client
-const reactivePrisma = basePrisma.$extends(reactiveQueriesExtension());
-
-// create a reactive query
-const unsubscriber = reactivePrisma.user.findMany((data) => {
- console.log(data);
-});
-
-export async function createRandomUserGeneric() {
- return await reactivePrisma.user.create({
- data: {
- email: chance.email(),
- name: chance.name(),
- },
- });
-}
-
-export async function runE2EQuery() {
- const createdUser = await basePrisma.user.create({
- data: {
- email: chance.email(),
- name: chance.name(),
- },
- });
- const foundUser = await basePrisma.user.findFirst({
- where: {
- id: createdUser.id,
- },
- });
- await basePrisma.user.delete({
- where: {
- id: foundUser?.id,
- },
- });
-}
-
-// @ts-expect-error
-module.hot?.dispose(() => {
- unsubscriber();
-});
diff --git a/example/src/server.ts b/example/src/server.ts
deleted file mode 100644
index 682da5c3..00000000
--- a/example/src/server.ts
+++ /dev/null
@@ -1,94 +0,0 @@
-import { BridgeServer } from 'react-native-http-bridge-refurbished';
-
-const server = new BridgeServer('http_service', true);
-let engine: any;
-let logs: string[] = [];
-
-async function sleep(ms: number): Promise {
- return new Promise((resolve) => {
- setTimeout(resolve, ms);
- });
-}
-
-server.get('/ping', async (_, res) => {
- res.send(200, 'application/text', 'pong');
-});
-
-server.post('/connect', async (req, res) => {
- // @ts-expect-error
- const schema: string = req.postData!.schema;
-
- logs = [];
-
- engine = __PrismaProxy!.create({
- datamodel: schema,
- logLevel: 'ERROR',
- logQueries: true,
- env: {},
- ignoreEnvVarErrors: true,
- datasourceOverrides: {},
- logCallback: (msg: string) => {
- logs.push(msg);
- },
- });
-
- __PrismaProxy!.connect(engine, '{}');
-
- res.send(200, 'application/json', '{}');
-});
-
-server.post('/query', async (req, res) => {
- // @ts-expect-error
- const body: string = req.postData?.body;
- // @ts-expect-error
- const txId: string = req.postData?.txId;
- const queryRes = await __PrismaProxy!.execute(engine, body, '', txId);
- // sleep for a bit to allow for logs to be collected
- await sleep(1);
- res.send(
- 200,
- 'application/json',
- JSON.stringify({ engineResponse: queryRes, logs })
- );
-});
-
-server.post('/start_transaction', async (req, res) => {
- // @ts-expect-error
- const body: string = req.postData?.body;
- // @ts-expect-error
- const trace: string = req.postData?.trace;
- const queryRes = __PrismaProxy!.startTransaction(engine, body, trace);
- res.send(200, 'application/text', JSON.stringify(queryRes));
-});
-
-server.post('/commit_transaction', async (req, res) => {
- // @ts-expect-error
- const txId: string = req.postData?.txId;
- // @ts-expect-error
- const trace: string = req.postData?.trace;
- const queryRes = __PrismaProxy!.commitTransaction(engine, txId, trace);
- res.send(200, 'application/text', JSON.stringify(queryRes));
-});
-
-server.post('/rollback_transaction', async (req, res) => {
- // @ts-expect-error
- const txId: string = req.postData?.txId;
- // @ts-expect-error
- const trace: string = req.postData?.trace;
- const queryRes = __PrismaProxy!.rollbackTransaction(engine, txId, trace);
- res.send(200, 'application/text', JSON.stringify(queryRes));
-});
-
-server.post('/disconnect', async (req, res) => {
- if (engine == null) {
- res.send(200, 'application/text', '');
- return;
- }
- // @ts-expect-error
- const trace: string = req.postData?.trace;
- __PrismaProxy!.disconnect(engine, trace);
- engine = null;
- res.send(200, 'application/text', '');
-});
-
-server.listen(3000);
diff --git a/example/tailwind.config.js b/example/tailwind.config.js
deleted file mode 100644
index 98137f0d..00000000
--- a/example/tailwind.config.js
+++ /dev/null
@@ -1,13 +0,0 @@
-/** @type {import('tailwindcss').Config} */
-module.exports = {
- content: ['./src/**.*{js,jsx,ts,tsx}'],
- presets: [require('nativewind/preset')],
- theme: {
- extend: {
- colors: {
- prisma: '#151718',
- },
- },
- },
- plugins: [],
-};
diff --git a/expo-module.config.json b/expo-module.config.json
new file mode 100644
index 00000000..94ed4f33
--- /dev/null
+++ b/expo-module.config.json
@@ -0,0 +1,7 @@
+{
+ "platforms": ["apple"],
+ "apple": {
+ "modules": ["PrismaQueryCompilerModule"],
+ "podspecPath": "PrismaReactNative.podspec"
+ }
+}
diff --git a/expo.d.ts b/expo.d.ts
deleted file mode 100644
index 020de8e4..00000000
--- a/expo.d.ts
+++ /dev/null
@@ -1 +0,0 @@
-export * from './plugin/build';
diff --git a/expo.js b/expo.js
deleted file mode 100644
index 3c7d11b6..00000000
--- a/expo.js
+++ /dev/null
@@ -1 +0,0 @@
-module.exports = require('./plugin/build');
diff --git a/ios/Prisma.h b/ios/Prisma.h
deleted file mode 100644
index b5043807..00000000
--- a/ios/Prisma.h
+++ /dev/null
@@ -1,16 +0,0 @@
-#ifdef __cplusplus
-#import "react-native-prisma.h"
-#endif
-
-#ifdef RCT_NEW_ARCH_ENABLED
-#import "RNPrismaSpec.h"
-
-@interface Prisma : NSObject
-#else
-#import
-#import
-
-@interface Prisma : NSObject
-#endif
-
-@end
diff --git a/ios/Prisma.mm b/ios/Prisma.mm
deleted file mode 100644
index 5898a16b..00000000
--- a/ios/Prisma.mm
+++ /dev/null
@@ -1,57 +0,0 @@
-#import "Prisma.h"
-#import
-#import
-#import
-#import
-
-@implementation Prisma
-
-@synthesize bridge=_bridge;
-
-RCT_EXPORT_MODULE()
-
-RCT_EXPORT_BLOCKING_SYNCHRONOUS_METHOD(install)
-{
- RCTCxxBridge *cxxBridge = (RCTCxxBridge *)_bridge;
- if (cxxBridge == nil) {
- return @false;
- }
-
- auto jsiRuntime = (facebook::jsi::Runtime *)cxxBridge.runtime;
- if (jsiRuntime == nil) {
- return @false;
- }
- auto &runtime = *jsiRuntime;
- auto callInvoker = _bridge.jsCallInvoker;
-
- // get migrations folder
- auto bundleURL = NSBundle.mainBundle.bundleURL;
- auto migrations_path_absolute = [NSString stringWithFormat:@"%@%@", bundleURL.absoluteString, @"migrations"];
- auto migrations_path = [migrations_path_absolute stringByReplacingOccurrencesOfString:@"file://" withString:@""];
-
- NSArray *paths = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSUserDomainMask, true);
- NSString *libraryPath = [paths objectAtIndex:0];
-
-#if DEBUG
- std::cout << "▲ NSHomeDirectory:\n" << [NSHomeDirectory() UTF8String] << std::endl;
- std::cout << "▲ Library Path:\n" << [libraryPath UTF8String] << std::endl;
- std::cout << "▲ Migrations Path:\n" << [migrations_path UTF8String] << std::endl;
-#endif
-
- prisma::install_cxx(runtime, callInvoker, [libraryPath UTF8String], [migrations_path UTF8String]);
- return nil;
-}
-
-#ifdef RCT_NEW_ARCH_ENABLED
-- (std::shared_ptr)getTurboModule:
- (const facebook::react::ObjCTurboModule::InitParams &)params
-{
- return std::make_shared(params);
-}
-#endif
-
-- (void)invalidate {
- prisma::invalidate();
-}
-
-@end
diff --git a/ios/PrismaQueryCompilerModule.swift b/ios/PrismaQueryCompilerModule.swift
new file mode 100644
index 00000000..d3ea3afb
--- /dev/null
+++ b/ios/PrismaQueryCompilerModule.swift
@@ -0,0 +1,64 @@
+import ExpoModulesCore
+
+public final class PrismaQueryCompilerModule: Module {
+ private var compilers: [Int: OpaquePointer] = [:]
+ private var nextHandle = 1
+
+ public func definition() -> ModuleDefinition {
+ Name("PrismaQueryCompiler")
+
+ Function("create") { (params: String) throws -> Int in
+ var error: UnsafeMutablePointer?
+ guard let compiler = prisma_query_compiler_create(params, &error) else {
+ throw nativeError(error)
+ }
+ let handle = nextHandle
+ nextHandle += 1
+ compilers[handle] = compiler
+ return handle
+ }
+
+ Function("compile") { (handle: Int, request: String) throws -> String in
+ try call(handle, request, prisma_query_compiler_compile)
+ }
+
+ Function("compileBatch") { (handle: Int, request: String) throws -> String in
+ try call(handle, request, prisma_query_compiler_compile_batch)
+ }
+
+ Function("free") { (handle: Int) in
+ if let compiler = compilers.removeValue(forKey: handle) {
+ prisma_query_compiler_destroy(compiler)
+ }
+ }
+
+ OnDestroy {
+ compilers.values.forEach(prisma_query_compiler_destroy)
+ compilers.removeAll()
+ }
+ }
+
+ private func call(
+ _ handle: Int,
+ _ request: String,
+ _ function: (OpaquePointer?, UnsafePointer?, UnsafeMutablePointer?>?) -> UnsafeMutablePointer?
+ ) throws -> String {
+ guard let compiler = compilers[handle] else {
+ throw Exception(name: "PrismaQueryCompilerError", description: "Invalid query compiler")
+ }
+ var error: UnsafeMutablePointer?
+ guard let result = function(compiler, request, &error) else {
+ throw nativeError(error)
+ }
+ defer { prisma_query_compiler_free_string(result) }
+ return String(cString: result)
+ }
+
+ private func nativeError(_ value: UnsafeMutablePointer?) -> Exception {
+ defer { prisma_query_compiler_free_string(value) }
+ return Exception(
+ name: "PrismaQueryCompilerError",
+ description: value.map { String(cString: $0) } ?? "Unknown query compiler error"
+ )
+ }
+}
diff --git a/lefthook.yml b/lefthook.yml
deleted file mode 100644
index 5168c9ae..00000000
--- a/lefthook.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-pre-commit:
- parallel: true
- commands:
- lint:
- glob: './src/*.{js,ts,jsx,tsx}'
- run: npx eslint {staged_files}
- types:
- glob: './src/*.{js,ts, jsx, tsx}'
- run: npx tsc --noEmit
- cpp-linter:
- run: clang-format -i ./cpp/*.cpp ./cpp/*.h && git add .
diff --git a/native/include/prisma_query_compiler.h b/native/include/prisma_query_compiler.h
new file mode 100644
index 00000000..4429b362
--- /dev/null
+++ b/native/include/prisma_query_compiler.h
@@ -0,0 +1,17 @@
+#pragma once
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef struct Compiler PrismaQueryCompiler;
+
+PrismaQueryCompiler *prisma_query_compiler_create(const char *params, char **error);
+char *prisma_query_compiler_compile(const PrismaQueryCompiler *compiler, const char *request, char **error);
+char *prisma_query_compiler_compile_batch(const PrismaQueryCompiler *compiler, const char *request, char **error);
+void prisma_query_compiler_destroy(PrismaQueryCompiler *compiler);
+void prisma_query_compiler_free_string(char *value);
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/native/query-compiler/Cargo.lock b/native/query-compiler/Cargo.lock
new file mode 100644
index 00000000..5e2588be
--- /dev/null
+++ b/native/query-compiler/Cargo.lock
@@ -0,0 +1,1918 @@
+# This file is automatically @generated by Cargo.
+# It is not intended for manual editing.
+version = 4
+
+[[package]]
+name = "ahash"
+version = "0.8.12"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5a15f179cd60c4584b8a8c596927aadc462e27f2ca70c04e0071964a73ba7a75"
+dependencies = [
+ "cfg-if",
+ "getrandom 0.3.4",
+ "once_cell",
+ "version_check",
+ "zerocopy",
+]
+
+[[package]]
+name = "aho-corasick"
+version = "1.1.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c982642fa9e8606056828ee9a8505737230110bb1099153c79efe865c59d12ba"
+dependencies = [
+ "memchr",
+]
+
+[[package]]
+name = "android_system_properties"
+version = "0.1.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc"
+dependencies = [
+ "libc",
+]
+
+[[package]]
+name = "arrayvec"
+version = "0.5.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "23b62fc65de8e4e7f52534fb52b0f3ed04746ae267519eef2a83941e8085068b"
+
+[[package]]
+name = "async-trait"
+version = "0.1.92"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "82f6aeea286b8eb4dd3431a1be1b59d290ace00f5bfd8e2a159bc2a05e2c1667"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "autocfg"
+version = "1.5.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53"
+
+[[package]]
+name = "base64"
+version = "0.22.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6"
+
+[[package]]
+name = "bigdecimal"
+version = "0.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a6773ddc0eafc0e509fb60e48dff7f450f8e674a0686ae8605e8d9901bd5eefa"
+dependencies = [
+ "num-bigint",
+ "num-integer",
+ "num-traits",
+]
+
+[[package]]
+name = "bitflags"
+version = "1.3.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"
+
+[[package]]
+name = "bon"
+version = "3.10.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9e3fac94a66da67200398458a25412bcc3f9b6443b5119a6cad9cf3ccfcd8cc6"
+dependencies = [
+ "bon-macros",
+]
+
+[[package]]
+name = "bon-macros"
+version = "3.10.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d4654961ad0494e4774c5c60b4cb4cd0ae9b9d92d039d901638b1dba97ebebf5"
+dependencies = [
+ "darling",
+ "ident_case",
+ "prettyplease",
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "bumpalo"
+version = "3.20.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649"
+
+[[package]]
+name = "cc"
+version = "1.4.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0ad534f4357a5264cce5019c989cf66a4f0dc4e0d1b1d15f8aacec0ff7360273"
+dependencies = [
+ "find-msvc-tools",
+ "shlex",
+]
+
+[[package]]
+name = "cfg-if"
+version = "1.0.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801"
+
+[[package]]
+name = "cfg_aliases"
+version = "0.2.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f079e83a288787bcd14a6aea84cee5c87a67c5a3e660c30f557a3d24761b3527"
+
+[[package]]
+name = "chrono"
+version = "0.4.45"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327"
+dependencies = [
+ "iana-time-zone",
+ "js-sys",
+ "num-traits",
+ "serde",
+ "wasm-bindgen",
+ "windows-link",
+]
+
+[[package]]
+name = "colored"
+version = "3.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "faf9468729b8cbcea668e36183cb69d317348c2e08e994829fb56ebfdfbaac34"
+dependencies = [
+ "windows-sys",
+]
+
+[[package]]
+name = "concat-idents"
+version = "1.1.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f76990911f2267d837d9d0ad060aa63aaad170af40904b29461734c339030d4d"
+dependencies = [
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "connection-string"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "510ca239cf13b7f8d16a2b48f263de7b4f8c566f0af58d901031473c76afb1e3"
+
+[[package]]
+name = "convert_case"
+version = "0.10.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "633458d4ef8c78b72454de2d54fd6ab2e60f9e02be22f3c6104cdc8a4e0fceb9"
+dependencies = [
+ "unicode-segmentation",
+]
+
+[[package]]
+name = "core-foundation-sys"
+version = "0.8.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"
+
+[[package]]
+name = "crosstarget-utils"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "chrono",
+ "derive_more",
+ "enumflags2",
+ "futures",
+ "js-sys",
+ "pin-project",
+ "regex",
+ "tokio",
+ "wasm-bindgen",
+ "wasm-bindgen-futures",
+]
+
+[[package]]
+name = "cruet"
+version = "0.15.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b7a9ae414b9768aada1b316493261653e41af05c9d2ccc9c504a8fc051c6a790"
+dependencies = [
+ "once_cell",
+ "regex",
+]
+
+[[package]]
+name = "darling"
+version = "0.24.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ed17f5901b6630b993ca003def43f2f8ef4014fc13b047b57aad617ff32bc2ec"
+dependencies = [
+ "darling_core",
+ "darling_macro",
+]
+
+[[package]]
+name = "darling_core"
+version = "0.24.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6837e2cf7485aaae18f86181d2f0e9a7ed297a025e220aeabf63fdebd3a2ddff"
+dependencies = [
+ "ident_case",
+ "proc-macro2",
+ "quote",
+ "strsim",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "darling_macro"
+version = "0.24.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2ac7135c3ef02b2f7833bbeb1be5ba7f966dcde8a87c6b87f65a778d71a02785"
+dependencies = [
+ "darling_core",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "derive_more"
+version = "2.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134"
+dependencies = [
+ "derive_more-impl",
+]
+
+[[package]]
+name = "derive_more-impl"
+version = "2.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb"
+dependencies = [
+ "convert_case",
+ "proc-macro2",
+ "quote",
+ "rustc_version",
+ "syn 2.0.119",
+ "unicode-xid",
+]
+
+[[package]]
+name = "diagnostics"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "colored",
+ "indoc",
+ "pest",
+]
+
+[[package]]
+name = "displaydoc"
+version = "0.2.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "either"
+version = "1.18.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "252afb9ae5eaa683babdc6a068b3f5726eb19e05070c731f9b2a23a7c3e8ed34"
+
+[[package]]
+name = "enumflags2"
+version = "0.7.12"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef"
+dependencies = [
+ "enumflags2_derive",
+]
+
+[[package]]
+name = "enumflags2_derive"
+version = "0.7.12"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "equivalent"
+version = "1.0.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"
+
+[[package]]
+name = "find-msvc-tools"
+version = "0.1.11"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d45db016d36b838f563236e9193d0ee6ce38f3f68b6c94e914b4929c96bbb890"
+
+[[package]]
+name = "fixedbitset"
+version = "0.5.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1d674e81391d1e1ab681a28d99df07927c6d4aa5b027d7da16ba32d1d21ecd99"
+
+[[package]]
+name = "foldhash"
+version = "0.1.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2"
+
+[[package]]
+name = "form_urlencoded"
+version = "1.2.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf"
+dependencies = [
+ "percent-encoding",
+]
+
+[[package]]
+name = "futures"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9a31d2a3fbaaeb2af2368bbdd904aa8e812d3c04a1ee10d3171f52d556e5d0a3"
+dependencies = [
+ "futures-channel",
+ "futures-core",
+ "futures-executor",
+ "futures-io",
+ "futures-sink",
+ "futures-task",
+ "futures-util",
+]
+
+[[package]]
+name = "futures-channel"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b1f9e3d69d39e4862ffed03ed071a76f9a13ba1d9109d355b0f0aa6b15e393c4"
+dependencies = [
+ "futures-core",
+ "futures-sink",
+]
+
+[[package]]
+name = "futures-core"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "92d699e522242e69e3003b94ecc1f960f3a5e015aa7c5d7486e65ad01dd94f5e"
+
+[[package]]
+name = "futures-executor"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "031b47cf1a3c6cc8bc2fc76cd437f521619387907d469316e7c0bc278f1f5432"
+dependencies = [
+ "futures-core",
+ "futures-task",
+ "futures-util",
+]
+
+[[package]]
+name = "futures-io"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "53c0fa8157de1303bfffdaa1cc2a673bfffb60102f76b0ef4441659124373fed"
+
+[[package]]
+name = "futures-macro"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9fb9654ba8355388abeb8dcb4fc62f511300867002afc858860463bdd9fe0c44"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "futures-sink"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1944426bf7d03f1d14f708785e4b33efd750b36d48a157b836b3efc15ede8e1d"
+
+[[package]]
+name = "futures-task"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cd417de3d1d015fc3bfd2b1ea46dfc7bab72ef86f1cc7cc9c78e728b34a6d1fd"
+
+[[package]]
+name = "futures-util"
+version = "0.3.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0d50a92467f8ba5dd6e3ee5d4bd04d73ab2e4e1c44474a0674821dfce14b79bc"
+dependencies = [
+ "futures-channel",
+ "futures-core",
+ "futures-io",
+ "futures-macro",
+ "futures-sink",
+ "futures-task",
+ "memchr",
+ "pin-project-lite",
+ "slab",
+]
+
+[[package]]
+name = "getrandom"
+version = "0.2.17"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0"
+dependencies = [
+ "cfg-if",
+ "libc",
+ "wasi",
+]
+
+[[package]]
+name = "getrandom"
+version = "0.3.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd"
+dependencies = [
+ "cfg-if",
+ "libc",
+ "r-efi 5.3.0",
+ "wasip2",
+]
+
+[[package]]
+name = "getrandom"
+version = "0.4.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099"
+dependencies = [
+ "cfg-if",
+ "libc",
+ "r-efi 6.0.0",
+]
+
+[[package]]
+name = "hashbrown"
+version = "0.15.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1"
+dependencies = [
+ "foldhash",
+]
+
+[[package]]
+name = "hashbrown"
+version = "0.17.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a"
+
+[[package]]
+name = "hermit-abi"
+version = "0.5.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fc0fef456e4baa96da950455cd02c081ca953b141298e41db3fc7e36b1da849c"
+
+[[package]]
+name = "hex"
+version = "0.4.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70"
+
+[[package]]
+name = "iana-time-zone"
+version = "0.1.65"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470"
+dependencies = [
+ "android_system_properties",
+ "core-foundation-sys",
+ "iana-time-zone-haiku",
+ "js-sys",
+ "log",
+ "wasm-bindgen",
+ "windows-core",
+]
+
+[[package]]
+name = "iana-time-zone-haiku"
+version = "0.1.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f"
+dependencies = [
+ "cc",
+]
+
+[[package]]
+name = "icu_collections"
+version = "2.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fa68d21081c4a05d5a901a1c62add574c77048b6a1c67be3b50ce0b60d4ca513"
+dependencies = [
+ "displaydoc",
+ "potential_utf",
+ "utf8_iter",
+ "yoke",
+ "zerofrom",
+ "zerovec",
+]
+
+[[package]]
+name = "icu_locale_core"
+version = "2.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d56e28588da92eee5c3201a6eff33fabdd49b62269c8938d4ff050ce4d900deb"
+dependencies = [
+ "displaydoc",
+ "litemap",
+ "tinystr",
+ "writeable",
+ "zerovec",
+]
+
+[[package]]
+name = "icu_normalizer"
+version = "2.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "12f9cf5f235641ed274641dd81c3f28d870e276763d0797aeeab72317b1c646f"
+dependencies = [
+ "icu_collections",
+ "icu_normalizer_data",
+ "icu_properties",
+ "icu_provider",
+ "smallvec",
+ "zerovec",
+]
+
+[[package]]
+name = "icu_normalizer_data"
+version = "2.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1563da1ed3e0b3bf3d74c9b85917ac9c56464d2f57242270c09c9e752f8021a0"
+
+[[package]]
+name = "icu_properties"
+version = "2.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7e7ca276ad3145661a65914e6daf131ca5120cd3dcee8f8f3214b8875184a148"
+dependencies = [
+ "displaydoc",
+ "icu_collections",
+ "icu_locale_core",
+ "icu_properties_data",
+ "icu_provider",
+ "zerotrie",
+ "zerovec",
+]
+
+[[package]]
+name = "icu_properties_data"
+version = "2.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e590f038c1464a96894fd6d10127e90a8be4509f56ff7ecef851b15cee0b7caa"
+
+[[package]]
+name = "icu_provider"
+version = "2.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d27bbb9d3abbefac45d55f647c9de1d44aafcd1186eb91879afef17c396c3e73"
+dependencies = [
+ "displaydoc",
+ "icu_locale_core",
+ "writeable",
+ "yoke",
+ "zerofrom",
+ "zerotrie",
+ "zerovec",
+]
+
+[[package]]
+name = "ident_case"
+version = "1.0.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39"
+
+[[package]]
+name = "idna"
+version = "1.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de"
+dependencies = [
+ "idna_adapter",
+ "smallvec",
+ "utf8_iter",
+]
+
+[[package]]
+name = "idna_adapter"
+version = "1.2.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714"
+dependencies = [
+ "icu_normalizer",
+ "icu_properties",
+]
+
+[[package]]
+name = "indexmap"
+version = "2.14.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9"
+dependencies = [
+ "equivalent",
+ "hashbrown 0.17.1",
+ "serde",
+ "serde_core",
+]
+
+[[package]]
+name = "indoc"
+version = "2.0.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "79cf5c93f93228cf8efb3ba362535fb11199ac548a09ce117c9b1adc3030d706"
+dependencies = [
+ "rustversion",
+]
+
+[[package]]
+name = "itertools"
+version = "0.14.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285"
+dependencies = [
+ "either",
+]
+
+[[package]]
+name = "itoa"
+version = "1.0.18"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"
+
+[[package]]
+name = "js-sys"
+version = "0.3.104"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0e0c1080212aad755ea003d18543e8768dd432c48819efd73a7bf1e39b7a5a3a"
+dependencies = [
+ "cfg-if",
+ "futures-util",
+ "wasm-bindgen",
+]
+
+[[package]]
+name = "lazy_static"
+version = "1.5.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe"
+
+[[package]]
+name = "libc"
+version = "0.2.189"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2"
+
+[[package]]
+name = "litemap"
+version = "0.8.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae"
+
+[[package]]
+name = "log"
+version = "0.4.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f9f8bd3e56ce4dfc153cf470fffbfa98c7620958b312ca5c3a4b8d5181fd13c6"
+
+[[package]]
+name = "lsp-types"
+version = "0.95.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8e34d33a8e9b006cd3fc4fe69a921affa097bae4bb65f76271f4644f9a334365"
+dependencies = [
+ "bitflags",
+ "serde",
+ "serde_json",
+ "serde_repr",
+ "url",
+]
+
+[[package]]
+name = "matchers"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d1525a2a28c7f4fa0fc98bb91ae755d1e2d1505079e05539e35bc876b5d65ae9"
+dependencies = [
+ "regex-automata",
+]
+
+[[package]]
+name = "memchr"
+version = "2.8.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98"
+
+[[package]]
+name = "nu-ansi-term"
+version = "0.50.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5"
+dependencies = [
+ "windows-sys",
+]
+
+[[package]]
+name = "num-bigint"
+version = "0.4.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c89e69e7e0f03bea5ef08013795c25018e101932225a656383bd384495ecc367"
+dependencies = [
+ "num-integer",
+ "num-traits",
+]
+
+[[package]]
+name = "num-integer"
+version = "0.1.47"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7ce2d95d4b3734dc35aa2f45e1aa22cd416814592a4f9d9205e11affd5b8e10b"
+dependencies = [
+ "num-traits",
+]
+
+[[package]]
+name = "num-traits"
+version = "0.2.19"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841"
+dependencies = [
+ "autocfg",
+]
+
+[[package]]
+name = "num_cpus"
+version = "1.17.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "91df4bbde75afed763b708b7eee1e8e7651e02d97f6d5dd763e89367e957b23b"
+dependencies = [
+ "hermit-abi",
+ "libc",
+]
+
+[[package]]
+name = "once_cell"
+version = "1.21.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"
+
+[[package]]
+name = "panic-utils"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+
+[[package]]
+name = "parser-database"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "diagnostics",
+ "either",
+ "enumflags2",
+ "indexmap",
+ "itertools",
+ "rustc-hash",
+ "schema-ast",
+]
+
+[[package]]
+name = "percent-encoding"
+version = "2.3.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"
+
+[[package]]
+name = "pest"
+version = "2.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5a07a60cc7a4d00c91f95c685609d1d2f79050e6804b70ebedd7650f0b839bcf"
+dependencies = [
+ "memchr",
+ "ucd-trie",
+]
+
+[[package]]
+name = "pest_derive"
+version = "2.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b3a83744a5c8455b8b3e0dc5031362780a347c878bdd11584d1a8984228cc88d"
+dependencies = [
+ "pest",
+ "pest_generator",
+]
+
+[[package]]
+name = "pest_generator"
+version = "2.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e0cd3451aa3de60d4b9a1e736885e4dea6b31617598026f12256ad566d63304a"
+dependencies = [
+ "pest",
+ "pest_meta",
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "pest_meta"
+version = "2.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e04d3a0849e241d7dfce834c83b1c5edc8622009e8dd51a12ba1927c32f05496"
+dependencies = [
+ "pest",
+]
+
+[[package]]
+name = "petgraph"
+version = "0.8.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8701b58ea97060d5e5b155d383a69952a60943f0e6dfe30b04c287beb0b27455"
+dependencies = [
+ "fixedbitset",
+ "hashbrown 0.15.5",
+ "indexmap",
+ "serde",
+]
+
+[[package]]
+name = "pin-project"
+version = "1.1.13"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2466b2336ed02bcdca6b294417127b90ec92038d1d5c4fbeac971a922e0e0924"
+dependencies = [
+ "pin-project-internal",
+]
+
+[[package]]
+name = "pin-project-internal"
+version = "1.1.13"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c96395f0a926bc13b1c17622aaddda1ecb55d49c8f1bf9777e4d877800a43f8b"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "pin-project-lite"
+version = "0.2.17"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd"
+
+[[package]]
+name = "potential_utf"
+version = "0.1.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661"
+dependencies = [
+ "zerovec",
+]
+
+[[package]]
+name = "ppv-lite86"
+version = "0.2.21"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9"
+dependencies = [
+ "zerocopy",
+]
+
+[[package]]
+name = "pretty"
+version = "0.12.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0d22152487193190344590e4f30e219cf3fe140d9e7a3fdb683d82aa2c5f4156"
+dependencies = [
+ "arrayvec",
+ "termcolor",
+ "typed-arena",
+ "unicode-width",
+]
+
+[[package]]
+name = "prettyplease"
+version = "0.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2bfe0f4c752e450fc2faf62654f1c134747922825d5b04ca717b8874f41a40c0"
+dependencies = [
+ "proc-macro2",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "prisma-query-compiler-native"
+version = "7.9.1"
+dependencies = [
+ "psl",
+ "quaint",
+ "query-compiler",
+ "query-core",
+ "request-handlers",
+ "schema",
+ "serde",
+ "serde_json",
+]
+
+[[package]]
+name = "prisma-value"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "base64",
+ "bigdecimal",
+ "chrono",
+ "serde",
+ "serde_json",
+ "uuid",
+]
+
+[[package]]
+name = "proc-macro2"
+version = "1.0.107"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9"
+dependencies = [
+ "unicode-ident",
+]
+
+[[package]]
+name = "psl"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "psl-core",
+]
+
+[[package]]
+name = "psl-core"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "bigdecimal",
+ "cfg-if",
+ "chrono",
+ "cruet",
+ "diagnostics",
+ "enumflags2",
+ "hex",
+ "indoc",
+ "itertools",
+ "lsp-types",
+ "parser-database",
+ "prisma-value",
+ "regex",
+ "schema-ast",
+ "serde",
+ "serde_json",
+ "url",
+]
+
+[[package]]
+name = "quaint"
+version = "0.2.0-alpha.13"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "async-trait",
+ "base64",
+ "bigdecimal",
+ "cfg_aliases",
+ "chrono",
+ "concat-idents",
+ "connection-string",
+ "crosstarget-utils",
+ "either",
+ "enumflags2",
+ "futures",
+ "hex",
+ "itertools",
+ "num_cpus",
+ "percent-encoding",
+ "pin-project",
+ "query-template",
+ "serde",
+ "serde_json",
+ "telemetry",
+ "thiserror",
+ "tracing",
+ "tracing-futures",
+ "url",
+ "uuid",
+]
+
+[[package]]
+name = "query-builder"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "query-structure",
+ "query-template",
+ "serde",
+]
+
+[[package]]
+name = "query-compiler"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "bon",
+ "indexmap",
+ "itertools",
+ "pretty",
+ "psl",
+ "quaint",
+ "query-builder",
+ "query-core",
+ "query-structure",
+ "serde",
+ "serde_json",
+ "sql-query-builder",
+ "thiserror",
+]
+
+[[package]]
+name = "query-core"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "bigdecimal",
+ "bon",
+ "chrono",
+ "enumflags2",
+ "indexmap",
+ "itertools",
+ "petgraph",
+ "psl",
+ "query-structure",
+ "schema",
+ "serde",
+ "serde_json",
+ "smallvec",
+ "thiserror",
+ "tokio",
+ "tracing",
+ "user-facing-errors",
+ "uuid",
+]
+
+[[package]]
+name = "query-structure"
+version = "0.0.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "bigdecimal",
+ "chrono",
+ "indexmap",
+ "itertools",
+ "prisma-value",
+ "psl",
+ "thiserror",
+]
+
+[[package]]
+name = "query-template"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "serde",
+]
+
+[[package]]
+name = "quote"
+version = "1.0.47"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001"
+dependencies = [
+ "proc-macro2",
+]
+
+[[package]]
+name = "r-efi"
+version = "5.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f"
+
+[[package]]
+name = "r-efi"
+version = "6.0.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf"
+
+[[package]]
+name = "rand"
+version = "0.8.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e058c7de0b26af77780c769414d6257830bb240f3c38477dbc2c16e5f54d6d4c"
+dependencies = [
+ "libc",
+ "rand_chacha",
+ "rand_core",
+]
+
+[[package]]
+name = "rand_chacha"
+version = "0.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88"
+dependencies = [
+ "ppv-lite86",
+ "rand_core",
+]
+
+[[package]]
+name = "rand_core"
+version = "0.6.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c"
+dependencies = [
+ "getrandom 0.2.17",
+]
+
+[[package]]
+name = "regex"
+version = "1.13.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d"
+dependencies = [
+ "aho-corasick",
+ "memchr",
+ "regex-automata",
+ "regex-syntax",
+]
+
+[[package]]
+name = "regex-automata"
+version = "0.4.18"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ad8553b9b26413251cbf30e620595c7a41b3887f03da04579c0e6b0d6a06b4b2"
+dependencies = [
+ "aho-corasick",
+ "memchr",
+ "regex-syntax",
+]
+
+[[package]]
+name = "regex-syntax"
+version = "0.8.11"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"
+
+[[package]]
+name = "request-handlers"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "bigdecimal",
+ "cfg_aliases",
+ "indexmap",
+ "psl",
+ "query-core",
+ "query-structure",
+ "serde",
+ "serde_json",
+ "thiserror",
+ "tracing",
+ "user-facing-errors",
+]
+
+[[package]]
+name = "rustc-hash"
+version = "2.1.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d"
+
+[[package]]
+name = "rustc_version"
+version = "0.4.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92"
+dependencies = [
+ "semver",
+]
+
+[[package]]
+name = "rustversion"
+version = "1.0.23"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f"
+
+[[package]]
+name = "schema"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "psl",
+ "query-structure",
+]
+
+[[package]]
+name = "schema-ast"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "diagnostics",
+ "pest",
+ "pest_derive",
+ "serde",
+]
+
+[[package]]
+name = "semver"
+version = "1.0.28"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd"
+
+[[package]]
+name = "serde"
+version = "1.0.229"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba"
+dependencies = [
+ "serde_core",
+ "serde_derive",
+]
+
+[[package]]
+name = "serde_core"
+version = "1.0.229"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48"
+dependencies = [
+ "serde_derive",
+]
+
+[[package]]
+name = "serde_derive"
+version = "1.0.229"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "serde_json"
+version = "1.0.151"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14"
+dependencies = [
+ "indexmap",
+ "itoa",
+ "memchr",
+ "serde",
+ "serde_core",
+ "zmij",
+]
+
+[[package]]
+name = "serde_repr"
+version = "0.1.21"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8d3b1629de253c70a0508c3899572da79ca359fdab27c7920ff00406df418906"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "sharded-slab"
+version = "0.1.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6"
+dependencies = [
+ "lazy_static",
+]
+
+[[package]]
+name = "shlex"
+version = "2.0.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba"
+
+[[package]]
+name = "slab"
+version = "0.4.12"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5"
+
+[[package]]
+name = "smallvec"
+version = "1.15.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90"
+
+[[package]]
+name = "sql-query-builder"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "bigdecimal",
+ "chrono",
+ "itertools",
+ "prisma-value",
+ "psl",
+ "quaint",
+ "query-builder",
+ "query-structure",
+ "schema",
+ "serde_json",
+ "telemetry",
+]
+
+[[package]]
+name = "stable_deref_trait"
+version = "1.2.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596"
+
+[[package]]
+name = "strsim"
+version = "0.11.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f"
+
+[[package]]
+name = "syn"
+version = "2.0.119"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "unicode-ident",
+]
+
+[[package]]
+name = "syn"
+version = "3.0.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e6275cddf4610d1775e6d1fe9469b2e77d0f39fd98fb7450901b821e0c53649f"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "unicode-ident",
+]
+
+[[package]]
+name = "synstructure"
+version = "0.13.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "telemetry"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "ahash",
+ "crosstarget-utils",
+ "derive_more",
+ "enumflags2",
+ "rand",
+ "serde",
+ "serde_json",
+ "thiserror",
+ "tokio",
+ "tracing",
+ "tracing-subscriber",
+]
+
+[[package]]
+name = "termcolor"
+version = "1.4.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755"
+dependencies = [
+ "winapi-util",
+]
+
+[[package]]
+name = "thiserror"
+version = "2.0.20"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ec86235f5fcc2a73650310756d2ac5b138a5780bbbdfae3eeccec992c435ba4f"
+dependencies = [
+ "thiserror-impl",
+]
+
+[[package]]
+name = "thiserror-impl"
+version = "2.0.20"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bc04cd3e1236dd4a98afca4569f2deb3f120e5422a4023be2cb683f8486292af"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "thread_local"
+version = "1.1.10"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1ad99c4c6d32803332c548b1af0540b357b3f5fc0be8f6c6bfe8b2e6ae784070"
+dependencies = [
+ "cfg-if",
+]
+
+[[package]]
+name = "tinystr"
+version = "0.8.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b1e27c91459209c2986af3dcf603a5a74a4368754ce37414f59acc971167f643"
+dependencies = [
+ "displaydoc",
+ "zerovec",
+]
+
+[[package]]
+name = "tokio"
+version = "1.53.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "202caea871b69668250d242070849eb495be178ed697a3e98aebce5bc81a0bed"
+dependencies = [
+ "pin-project-lite",
+ "tokio-macros",
+]
+
+[[package]]
+name = "tokio-macros"
+version = "2.7.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "78773a2a397f451582ce068015985c33193cf6dea8b74d2a639fe457b2f07b0e"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "tracing"
+version = "0.1.44"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100"
+dependencies = [
+ "pin-project-lite",
+ "tracing-attributes",
+ "tracing-core",
+]
+
+[[package]]
+name = "tracing-attributes"
+version = "0.1.31"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "tracing-core"
+version = "0.1.36"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a"
+dependencies = [
+ "once_cell",
+ "valuable",
+]
+
+[[package]]
+name = "tracing-futures"
+version = "0.2.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2"
+dependencies = [
+ "pin-project",
+ "tracing",
+]
+
+[[package]]
+name = "tracing-log"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3"
+dependencies = [
+ "log",
+ "once_cell",
+ "tracing-core",
+]
+
+[[package]]
+name = "tracing-subscriber"
+version = "0.3.23"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cb7f578e5945fb242538965c2d0b04418d38ec25c79d160cd279bf0731c8d319"
+dependencies = [
+ "matchers",
+ "nu-ansi-term",
+ "once_cell",
+ "regex-automata",
+ "sharded-slab",
+ "smallvec",
+ "thread_local",
+ "tracing",
+ "tracing-core",
+ "tracing-log",
+]
+
+[[package]]
+name = "typed-arena"
+version = "2.0.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6af6ae20167a9ece4bcb41af5b80f8a1f1df981f6391189ce00fd257af04126a"
+
+[[package]]
+name = "ucd-trie"
+version = "0.1.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2896d95c02a80c6d6a5d6e953d479f5ddf2dfdb6a244441010e373ac0fb88971"
+
+[[package]]
+name = "unicode-ident"
+version = "1.0.24"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"
+
+[[package]]
+name = "unicode-segmentation"
+version = "1.13.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8"
+
+[[package]]
+name = "unicode-width"
+version = "0.2.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254"
+
+[[package]]
+name = "unicode-xid"
+version = "0.2.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853"
+
+[[package]]
+name = "url"
+version = "2.5.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed"
+dependencies = [
+ "form_urlencoded",
+ "idna",
+ "percent-encoding",
+ "serde",
+ "serde_derive",
+]
+
+[[package]]
+name = "user-facing-error-macros"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "user-facing-errors"
+version = "0.1.0"
+source = "git+https://github.com/prisma/prisma-engines.git?rev=e922089b7d7502aff4249d5da3420f6fa55fc6ad#e922089b7d7502aff4249d5da3420f6fa55fc6ad"
+dependencies = [
+ "indoc",
+ "itertools",
+ "panic-utils",
+ "serde",
+ "serde_json",
+ "tracing",
+ "user-facing-error-macros",
+]
+
+[[package]]
+name = "utf8_iter"
+version = "1.0.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"
+
+[[package]]
+name = "uuid"
+version = "1.25.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f053576934f05a761a402421fbbe3d425d9366f75f978806a037b3ca481abecc"
+dependencies = [
+ "getrandom 0.4.3",
+ "js-sys",
+ "serde_core",
+ "wasm-bindgen",
+]
+
+[[package]]
+name = "valuable"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65"
+
+[[package]]
+name = "version_check"
+version = "0.9.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a"
+
+[[package]]
+name = "wasi"
+version = "0.11.1+wasi-snapshot-preview1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b"
+
+[[package]]
+name = "wasip2"
+version = "1.0.4+wasi-0.2.12"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487"
+dependencies = [
+ "wit-bindgen",
+]
+
+[[package]]
+name = "wasm-bindgen"
+version = "0.2.127"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1b70935747edd64d89de3efa29d73789b806c15798f8e7dca4d8ac356b50ce70"
+dependencies = [
+ "cfg-if",
+ "once_cell",
+ "rustversion",
+ "wasm-bindgen-macro",
+ "wasm-bindgen-shared",
+]
+
+[[package]]
+name = "wasm-bindgen-futures"
+version = "0.4.77"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6b7777d5cc23d0e91404e53ce2d5e8ec7acae3026b16233dba62cd3246457950"
+dependencies = [
+ "js-sys",
+ "wasm-bindgen",
+]
+
+[[package]]
+name = "wasm-bindgen-macro"
+version = "0.2.127"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "77775f8f3f7217702089053b94958f8f54061a3f663417df76e19cbdcca29bc1"
+dependencies = [
+ "quote",
+ "wasm-bindgen-macro-support",
+]
+
+[[package]]
+name = "wasm-bindgen-macro-support"
+version = "0.2.127"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e11d33f857dc2fb11b8bc75aee111aa9cbeb12cd9f25efd3d4c2a3dd4e235284"
+dependencies = [
+ "bumpalo",
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+ "wasm-bindgen-shared",
+]
+
+[[package]]
+name = "wasm-bindgen-shared"
+version = "0.2.127"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7ef64dbcc55df09c7e5a46182d181c2cfa3e925f3da937ea764728b4bbb9dcbf"
+dependencies = [
+ "unicode-ident",
+]
+
+[[package]]
+name = "winapi-util"
+version = "0.1.11"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"
+dependencies = [
+ "windows-sys",
+]
+
+[[package]]
+name = "windows-core"
+version = "0.62.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb"
+dependencies = [
+ "windows-implement",
+ "windows-interface",
+ "windows-link",
+ "windows-result",
+ "windows-strings",
+]
+
+[[package]]
+name = "windows-implement"
+version = "0.60.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "windows-interface"
+version = "0.59.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "windows-link"
+version = "0.2.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5"
+
+[[package]]
+name = "windows-result"
+version = "0.4.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5"
+dependencies = [
+ "windows-link",
+]
+
+[[package]]
+name = "windows-strings"
+version = "0.5.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091"
+dependencies = [
+ "windows-link",
+]
+
+[[package]]
+name = "windows-sys"
+version = "0.61.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc"
+dependencies = [
+ "windows-link",
+]
+
+[[package]]
+name = "wit-bindgen"
+version = "0.57.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e"
+
+[[package]]
+name = "writeable"
+version = "0.6.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc"
+
+[[package]]
+name = "yoke"
+version = "0.8.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5"
+dependencies = [
+ "stable_deref_trait",
+ "yoke-derive",
+ "zerofrom",
+]
+
+[[package]]
+name = "yoke-derive"
+version = "0.8.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+ "synstructure",
+]
+
+[[package]]
+name = "zerocopy"
+version = "0.8.56"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "556764e583adb45a9f8d413c2a147fa7e8d821e48e12b14fd560b607998b75eb"
+dependencies = [
+ "zerocopy-derive",
+]
+
+[[package]]
+name = "zerocopy-derive"
+version = "0.8.56"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f2ab42fc20575779bd240faa45f94a74256f755c0fa9e89f0ede20d91d0cdfc1"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
+[[package]]
+name = "zerofrom"
+version = "0.1.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272"
+dependencies = [
+ "zerofrom-derive",
+]
+
+[[package]]
+name = "zerofrom-derive"
+version = "0.1.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+ "synstructure",
+]
+
+[[package]]
+name = "zerotrie"
+version = "0.2.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f"
+dependencies = [
+ "displaydoc",
+ "yoke",
+ "zerofrom",
+]
+
+[[package]]
+name = "zerovec"
+version = "0.11.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bb0464e17806c1d976d5cba29399c7f08e516e279e2ba493f63123b5fca67dd8"
+dependencies = [
+ "yoke",
+ "zerofrom",
+ "zerovec-derive",
+]
+
+[[package]]
+name = "zerovec-derive"
+version = "0.11.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "34df6fc39dbd26ddc9c10e6a2984476e13acce22e64e4487636ef494369225da"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 3.0.4",
+]
+
+[[package]]
+name = "zmij"
+version = "1.0.23"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"
diff --git a/native/query-compiler/Cargo.toml b/native/query-compiler/Cargo.toml
new file mode 100644
index 00000000..956defa4
--- /dev/null
+++ b/native/query-compiler/Cargo.toml
@@ -0,0 +1,24 @@
+[package]
+name = "prisma-query-compiler-native"
+version = "7.9.1"
+edition = "2024"
+
+[lib]
+crate-type = ["staticlib", "cdylib"]
+
+[dependencies]
+psl = { git = "https://github.com/prisma/prisma-engines.git", rev = "e922089b7d7502aff4249d5da3420f6fa55fc6ad", features = ["sqlite"] }
+quaint = { git = "https://github.com/prisma/prisma-engines.git", rev = "e922089b7d7502aff4249d5da3420f6fa55fc6ad", features = ["sqlite"] }
+query-compiler = { git = "https://github.com/prisma/prisma-engines.git", rev = "e922089b7d7502aff4249d5da3420f6fa55fc6ad", default-features = false, features = ["sqlite"] }
+query-core = { git = "https://github.com/prisma/prisma-engines.git", rev = "e922089b7d7502aff4249d5da3420f6fa55fc6ad" }
+request-handlers = { git = "https://github.com/prisma/prisma-engines.git", rev = "e922089b7d7502aff4249d5da3420f6fa55fc6ad", features = ["sqlite"] }
+schema = { git = "https://github.com/prisma/prisma-engines.git", rev = "e922089b7d7502aff4249d5da3420f6fa55fc6ad" }
+serde = { version = "1", features = ["derive"] }
+serde_json = "1"
+
+[profile.release]
+codegen-units = 1
+lto = true
+opt-level = "z"
+panic = "abort"
+strip = true
diff --git a/native/query-compiler/src/lib.rs b/native/query-compiler/src/lib.rs
new file mode 100644
index 00000000..18a1efb6
--- /dev/null
+++ b/native/query-compiler/src/lib.rs
@@ -0,0 +1,260 @@
+use psl::{ConnectorRegistry, parser_database::NoExtensionTypes};
+use quaint::prelude::{ConnectionInfo, ExternalConnectionInfo, SqlFamily};
+use query_compiler::Expression;
+use query_core::{
+ BatchDocument, QueryDocument, protocol::EngineProtocol, with_sync_unevaluated_request_context,
+};
+use request_handlers::RequestBody;
+use serde::{Deserialize, Serialize};
+use std::{
+ ffi::{CStr, CString, c_char},
+ ptr,
+ sync::Arc,
+};
+
+const CONNECTORS: ConnectorRegistry<'_> = &[psl::builtin_connectors::SQLITE];
+
+#[derive(Deserialize)]
+#[serde(rename_all = "camelCase")]
+struct Params {
+ datamodel: String,
+ provider: String,
+ connection_info: Connection,
+}
+
+#[derive(Deserialize)]
+#[serde(rename_all = "camelCase")]
+struct Connection {
+ max_bind_values: Option,
+ supports_relation_joins: bool,
+}
+
+pub struct Compiler {
+ schema: Arc,
+ connection: ConnectionInfo,
+}
+
+impl Compiler {
+ fn new(params: Params) -> Result {
+ if params.provider != "sqlite" {
+ return Err(format!("Unsupported provider: {}", params.provider));
+ }
+ let schema =
+ psl::parse_without_validation(params.datamodel.into(), CONNECTORS, &NoExtensionTypes);
+ let schema = Arc::new(
+ schema::build(Arc::new(schema), true).with_db_version_supports_join_strategy(
+ params.connection_info.supports_relation_joins,
+ ),
+ );
+ Ok(Self {
+ schema,
+ connection: ConnectionInfo::External(ExternalConnectionInfo::new(
+ SqlFamily::Sqlite,
+ Some("main".to_owned()),
+ params
+ .connection_info
+ .max_bind_values
+ .map(|value| value as usize),
+ params.connection_info.supports_relation_joins,
+ )),
+ })
+ }
+
+ fn compile(&self, request: &str) -> Result {
+ with_sync_unevaluated_request_context(|| {
+ let request = RequestBody::try_from_str(request, EngineProtocol::Json)
+ .map_err(|error| error.to_string())?;
+ let QueryDocument::Single(operation) = request
+ .into_doc(&self.schema)
+ .map_err(|error| error.to_string())?
+ else {
+ return Err("Unexpected batch request".to_owned());
+ };
+ serde_json::to_string(
+ &query_compiler::compile(&self.schema, operation, &self.connection)
+ .map_err(|error| error.to_string())?,
+ )
+ .map_err(|error| error.to_string())
+ })
+ }
+
+ fn compile_batch(&self, request: &str) -> Result {
+ with_sync_unevaluated_request_context(|| {
+ let request = RequestBody::try_from_str(request, EngineProtocol::Json)
+ .map_err(|error| error.to_string())?;
+ let response = match request
+ .into_doc(&self.schema)
+ .map_err(|error| error.to_string())?
+ {
+ QueryDocument::Single(operation) => BatchResponse::Multi {
+ plans: vec![
+ query_compiler::compile(&self.schema, operation, &self.connection)
+ .map_err(|error| error.to_string())?,
+ ],
+ },
+ QueryDocument::Multi(batch) => match batch.compact(&self.schema) {
+ BatchDocument::Multi(operations, _) => BatchResponse::Multi {
+ plans: operations
+ .into_iter()
+ .map(|operation| {
+ query_compiler::compile(&self.schema, operation, &self.connection)
+ })
+ .collect::>()
+ .map_err(|error| error.to_string())?,
+ },
+ BatchDocument::Compact(compacted) => {
+ let expect_non_empty = compacted.throw_on_empty();
+ BatchResponse::Compacted {
+ plan: query_compiler::compile(
+ &self.schema,
+ compacted.operation,
+ &self.connection,
+ )
+ .map_err(|error| error.to_string())?
+ .into(),
+ arguments: compacted.arguments,
+ nested_selection: compacted.nested_selection,
+ keys: compacted.keys,
+ expect_non_empty,
+ }
+ }
+ },
+ };
+ serde_json::to_string(&response).map_err(|error| error.to_string())
+ })
+ }
+}
+
+#[derive(Serialize)]
+#[serde(tag = "type", rename_all = "camelCase")]
+enum BatchResponse {
+ Multi {
+ plans: Vec,
+ },
+ #[serde(rename_all = "camelCase")]
+ Compacted {
+ plan: Box,
+ arguments: Vec>,
+ nested_selection: Vec,
+ keys: Vec,
+ expect_non_empty: bool,
+ },
+}
+
+unsafe fn string(value: *const c_char) -> Result<&'static str, String> {
+ if value.is_null() {
+ return Err("Missing string argument".to_owned());
+ }
+ unsafe { CStr::from_ptr(value) }
+ .to_str()
+ .map_err(|error| error.to_string())
+}
+
+fn output(value: Result, error: *mut *mut c_char) -> *mut c_char {
+ match value {
+ Ok(value) => CString::new(value).unwrap().into_raw(),
+ Err(message) => {
+ if !error.is_null() {
+ unsafe { *error = CString::new(message).unwrap().into_raw() };
+ }
+ ptr::null_mut()
+ }
+ }
+}
+
+#[unsafe(no_mangle)]
+pub unsafe extern "C" fn prisma_query_compiler_create(
+ params: *const c_char,
+ error: *mut *mut c_char,
+) -> *mut Compiler {
+ let result = unsafe { string(params) }
+ .and_then(|params| serde_json::from_str(params).map_err(|error| error.to_string()))
+ .and_then(Compiler::new);
+ match result {
+ Ok(compiler) => Box::into_raw(Box::new(compiler)),
+ Err(message) => {
+ output(Err(message), error);
+ ptr::null_mut()
+ }
+ }
+}
+
+#[unsafe(no_mangle)]
+pub unsafe extern "C" fn prisma_query_compiler_compile(
+ compiler: *const Compiler,
+ request: *const c_char,
+ error: *mut *mut c_char,
+) -> *mut c_char {
+ output(
+ if compiler.is_null() {
+ Err("Invalid query compiler".to_owned())
+ } else {
+ unsafe { string(request) }.and_then(|request| unsafe { &*compiler }.compile(request))
+ },
+ error,
+ )
+}
+
+#[unsafe(no_mangle)]
+pub unsafe extern "C" fn prisma_query_compiler_compile_batch(
+ compiler: *const Compiler,
+ request: *const c_char,
+ error: *mut *mut c_char,
+) -> *mut c_char {
+ output(
+ if compiler.is_null() {
+ Err("Invalid query compiler".to_owned())
+ } else {
+ unsafe { string(request) }
+ .and_then(|request| unsafe { &*compiler }.compile_batch(request))
+ },
+ error,
+ )
+}
+
+#[unsafe(no_mangle)]
+pub unsafe extern "C" fn prisma_query_compiler_destroy(compiler: *mut Compiler) {
+ if !compiler.is_null() {
+ drop(unsafe { Box::from_raw(compiler) });
+ }
+}
+
+#[unsafe(no_mangle)]
+pub unsafe extern "C" fn prisma_query_compiler_free_string(value: *mut c_char) {
+ if !value.is_null() {
+ drop(unsafe { CString::from_raw(value) });
+ }
+}
+
+#[cfg(test)]
+mod tests {
+ use super::*;
+
+ #[test]
+ fn compiles_sqlite_query() {
+ let compiler = Compiler::new(Params {
+ datamodel: r#"
+ datasource db {
+ provider = "sqlite"
+ }
+ model User {
+ id Int @id @default(autoincrement())
+ name String
+ }
+ "#
+ .to_owned(),
+ provider: "sqlite".to_owned(),
+ connection_info: Connection {
+ max_bind_values: Some(999),
+ supports_relation_joins: false,
+ },
+ })
+ .unwrap();
+ let plan = compiler
+ .compile(
+ r#"{"modelName":"User","action":"findMany","query":{"arguments":{},"selection":{"$composites":true,"$scalars":true}}}"#,
+ )
+ .unwrap();
+ assert!(plan.contains("SELECT"));
+ }
+}
diff --git a/package.json b/package.json
index 3845e2ca..21a43b27 100644
--- a/package.json
+++ b/package.json
@@ -1,182 +1,114 @@
{
"name": "@prisma/react-native",
- "version": "6.1.0-dev.17",
- "description": "Prisma for react-native",
+ "version": "7.9.1",
+ "description": "Synchronous Prisma 7 client for React Native and Expo SQLite",
"main": "lib/commonjs/index",
"module": "lib/module/index",
- "types": "lib/typescript/src/index.d.ts",
+ "types": "lib/typescript/commonjs/index.d.ts",
"react-native": "src/index",
"source": "src/index",
+ "bin": {
+ "prisma-react-native": "scripts/prepare-client.cjs"
+ },
+ "exports": {
+ ".": {
+ "react-native": "./src/index.ts",
+ "import": {
+ "types": "./lib/typescript/module/index.d.ts",
+ "default": "./lib/module/index.js"
+ },
+ "require": {
+ "types": "./lib/typescript/commonjs/index.d.ts",
+ "default": "./lib/commonjs/index.js"
+ }
+ }
+ },
"files": [
"src",
"lib",
- "android",
- "ios",
- "cpp",
- "*.podspec",
- "engines",
- "!ios/build",
- "!android/build",
- "!android/gradle",
- "!android/gradlew",
- "!android/gradlew.bat",
- "!android/local.properties",
"!**/__tests__",
"!**/__fixtures__",
"!**/__mocks__",
"!**/.*",
- "copy-migrations.sh",
- "react-native-prisma.gradle",
- "plugin",
- "app.plugin.js",
- "expo.d.ts",
- "expo.js"
+ "scripts/patch-prisma-runtime.cjs",
+ "scripts/prepare-client.cjs",
+ "scripts/build-native-ios.sh",
+ "expo-module.config.json",
+ "PrismaReactNative.podspec",
+ "ios",
+ "native/include",
+ "native/PrismaQueryCompiler.xcframework"
],
"scripts": {
- "example": "yarn workspace react-native-prisma-example",
- "test": "jest",
- "check-updates": "tsx scripts/check-updates.ts",
- "bump-client": "tsx scripts/bump-client.ts",
- "download-engine": "tsx scripts/download-engine.ts",
"typecheck": "tsc --noEmit",
- "lint": "eslint \"**/*.{js,ts,tsx}\"",
- "clean": "del-cli android/build example/android/build example/android/app/build example/ios/build lib",
- "prepare": "yarn download-engine && bob build",
- "ios:full": "yarn qe:sim && cd example && yarn ios",
- "clang": "clang-format -i ./cpp/*.cpp ./cpp/*.h && git add .",
- "ios": "cd example && yarn ios",
- "android": "cd example && yarn android"
+ "prepare": "bob build",
+ "build:native:ios": "scripts/build-native-ios.sh",
+ "build:release": "bob build && node scripts/obfuscate.cjs lib",
+ "postinstall": "node ./scripts/patch-prisma-runtime.cjs"
},
"keywords": [
"react-native",
- "ios",
- "android"
+ "expo",
+ "prisma",
+ "sqlite",
+ "ios"
],
"repository": {
"type": "git",
- "url": "git+https://github.com/prisma/react-native-prisma.git"
+ "url": "git+https://github.com/song-react/react-native-prisma.git"
},
"author": "Oscar Franco (https://github.com/ospfranco)",
"license": "Apache-2.0",
"bugs": {
- "url": "https://github.com/prisma/react-native-prisma/issues"
- },
- "homepage": "https://github.com/prisma/react-native-prisma#readme",
- "publishConfig": {
- "registry": "https://registry.npmjs.org/",
- "access": "public"
+ "url": "https://github.com/song-react/react-native-prisma/issues"
},
+ "homepage": "https://github.com/song-react/react-native-prisma#readme",
"devDependencies": {
- "@evilmartians/lefthook": "^1.5.0",
- "@prisma/client": "6.1.0-dev.17",
- "@react-native/eslint-config": "^0.72.2",
- "@tsconfig/react-native": "^3.0.5",
- "@types/jest": "^28.1.2",
- "@types/react": "~17.0.21",
- "@types/unzipper": "^0.10.9",
- "clang-format": "^1.8.0",
- "del-cli": "^5.0.0",
- "eslint": "^8.4.1",
- "eslint-config-prettier": "^8.5.0",
- "eslint-plugin-prettier": "^4.0.0",
- "expo": "50.0.0",
- "expo-module-scripts": "^3.4.1",
- "jest": "^28.1.1",
- "p-retry": "^6.2.0",
- "pod-install": "0.2.0",
- "prettier": "^2.0.5",
- "prisma": "6.1.0-dev.17",
- "react": "18.2.0",
- "react-native": "0.73.2",
- "react-native-builder-bob": "0.23.2",
- "react-native-quick-base64": "2.0.8",
- "react-native-url-polyfill": "2.0.0",
- "tsx": "^4.7.3",
- "typescript": "^5.4.5",
- "unzipper": "^0.11.4",
- "zx": "^7.2.3"
- },
- "resolutions": {
- "@types/react": "17.0.21"
+ "@prisma/client": "7.9.1",
+ "expo": "58.0.0-canary-20260812-27f94d4",
+ "expo-sqlite": "58.0.0-canary-20260812-27f94d4",
+ "prisma": "7.9.1",
+ "react-native": "0.87.0",
+ "react-native-builder-bob": "0.40.13",
+ "terser": "5.50.0",
+ "typescript": "^5.4.5"
},
"peerDependencies": {
- "@prisma/client": "*",
- "expo": ">=49.0.0",
- "react": "*",
- "react-native": "*",
- "react-native-quick-base64": "*"
+ "@prisma/client": "^7.9.1",
+ "expo": ">=52.0.0 || >=58.0.0-0 <59.0.0",
+ "expo-sqlite": ">=15.0.0 || >=58.0.0-0 <59.0.0",
+ "react-native": ">=0.76.0"
},
- "workspaces": [
- "example"
- ],
"packageManager": "yarn@4.1.1",
"engines": {
- "node": ">= 18.0.0"
- },
- "jest": {
- "preset": "react-native",
- "modulePathIgnorePatterns": [
- "/example/node_modules",
- "/lib/"
- ]
- },
- "eslintConfig": {
- "root": true,
- "extends": [
- "@react-native",
- "prettier"
- ],
- "rules": {
- "prettier/prettier": [
- "error",
- {
- "quoteProps": "consistent",
- "singleQuote": true,
- "tabWidth": 2,
- "trailingComma": "es5",
- "useTabs": false
- }
- ]
- }
- },
- "eslintIgnore": [
- "node_modules/",
- "lib/",
- "plugin/build"
- ],
- "prettier": {
- "quoteProps": "consistent",
- "singleQuote": true,
- "tabWidth": 2,
- "trailingComma": "es5",
- "useTabs": false
+ "node": ">=22.12.0"
},
"react-native-builder-bob": {
"source": "src",
"output": "lib",
"targets": [
- "commonjs",
- "module",
+ [
+ "commonjs",
+ {
+ "esm": true
+ }
+ ],
+ [
+ "module",
+ {
+ "esm": true
+ }
+ ],
[
"typescript",
{
- "project": "tsconfig.build.json"
+ "project": "tsconfig.json"
}
]
]
},
- "codegenConfig": {
- "name": "RNPrismaSpec",
- "type": "modules",
- "jsSrcsDir": "src"
- },
- "peerDependenciesMeta": {
- "expo": {
- "optional": true
- }
- },
"dependencies": {
- "react-native-quick-base64": "^2.0.8",
- "react-native-url-polyfill": "^2.0.0"
+ "@prisma/driver-adapter-utils": "7.9.1",
+ "buffer": "^6.0.3"
}
}
diff --git a/plugin/build/index.d.ts b/plugin/build/index.d.ts
deleted file mode 100644
index ac6cb97b..00000000
--- a/plugin/build/index.d.ts
+++ /dev/null
@@ -1,3 +0,0 @@
-import { withPrisma } from './withPrisma';
-export { withPrisma };
-export default withPrisma;
diff --git a/plugin/build/index.js b/plugin/build/index.js
deleted file mode 100644
index 52aac753..00000000
--- a/plugin/build/index.js
+++ /dev/null
@@ -1,11 +0,0 @@
-'use strict';
-Object.defineProperty(exports, '__esModule', { value: true });
-exports.withPrisma = void 0;
-const withPrisma_1 = require('./withPrisma');
-Object.defineProperty(exports, 'withPrisma', {
- enumerable: true,
- get() {
- return withPrisma_1.withPrisma;
- },
-});
-exports.default = withPrisma_1.withPrisma;
diff --git a/plugin/build/withPrisma.d.ts b/plugin/build/withPrisma.d.ts
deleted file mode 100644
index fd779ae8..00000000
--- a/plugin/build/withPrisma.d.ts
+++ /dev/null
@@ -1,3 +0,0 @@
-import type { ConfigPlugin } from 'expo/config-plugins';
-declare const withPrisma: ConfigPlugin;
-export { withPrisma };
diff --git a/plugin/build/withPrisma.js b/plugin/build/withPrisma.js
deleted file mode 100644
index 45c2a2bd..00000000
--- a/plugin/build/withPrisma.js
+++ /dev/null
@@ -1,34 +0,0 @@
-'use strict';
-Object.defineProperty(exports, '__esModule', { value: true });
-exports.withPrisma = void 0;
-const config_plugins_1 = require('expo/config-plugins');
-
-const withPrismaAndroid_1 = require('./withPrismaAndroid');
-const withPrismaIOS_1 = require('./withPrismaIOS');
-const pkg = require('../../package.json');
-const withPrismaPlugin = (config) => {
- let cfg = config;
- try {
- cfg = (0, withPrismaAndroid_1.withPrismaAndroid)(cfg);
- } catch (e) {
- config_plugins_1.WarningAggregator.addWarningAndroid(
- 'prisma-expo',
- `There was a problem configuring prisma for expo in your native Android project ${e}`
- );
- }
- try {
- cfg = (0, withPrismaIOS_1.withPrismaIOS)(cfg);
- } catch (e) {
- config_plugins_1.WarningAggregator.addWarningAndroid(
- 'prisma-expo',
- `There was a problem configuring prisma for expo in your native iOS project ${e}`
- );
- }
- return cfg;
-};
-const withPrisma = (0, config_plugins_1.createRunOncePlugin)(
- withPrismaPlugin,
- pkg.name,
- pkg.version
-);
-exports.withPrisma = withPrisma;
diff --git a/plugin/build/withPrismaAndroid.d.ts b/plugin/build/withPrismaAndroid.d.ts
deleted file mode 100644
index c2a06bff..00000000
--- a/plugin/build/withPrismaAndroid.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-import type { ConfigPlugin } from 'expo/config-plugins';
-export declare const withPrismaAndroid: ConfigPlugin;
diff --git a/plugin/build/withPrismaAndroid.js b/plugin/build/withPrismaAndroid.js
deleted file mode 100644
index d85cbd1a..00000000
--- a/plugin/build/withPrismaAndroid.js
+++ /dev/null
@@ -1,28 +0,0 @@
-'use strict';
-Object.defineProperty(exports, '__esModule', { value: true });
-exports.withPrismaAndroid = void 0;
-const config_plugins_1 = require('expo/config-plugins');
-const SCRIPT_LINE =
- 'apply from: "../../node_modules/@prisma/react-native/react-native-prisma.gradle"';
-const withPrismaAndroid = (config) => {
- const cfg = (0, config_plugins_1.withAppBuildGradle)(config, (config) => {
- if (config.modResults.language === 'groovy') {
- config.modResults.contents = modifyAppBuildGradle(
- config.modResults.contents
- );
- } else {
- throw new Error(
- 'Cannot configure prisma because app/Build.gradle because it is not groovy'
- );
- }
- return config;
- });
- return cfg;
-};
-exports.withPrismaAndroid = withPrismaAndroid;
-function modifyAppBuildGradle(gradleContent) {
- if (gradleContent.includes('react-native-prisma.gradle')) {
- return gradleContent;
- }
- return gradleContent + '\n' + SCRIPT_LINE;
-}
diff --git a/plugin/build/withPrismaIOS.d.ts b/plugin/build/withPrismaIOS.d.ts
deleted file mode 100644
index 61bff35d..00000000
--- a/plugin/build/withPrismaIOS.d.ts
+++ /dev/null
@@ -1,10 +0,0 @@
-import type { ConfigPlugin } from 'expo/config-plugins';
-type BuildPhase = {
- shellScript: string;
-};
-export declare const withPrismaIOS: ConfigPlugin;
-export declare function modifyExistingXcodeBuildScript(
- script: BuildPhase
-): void;
-export declare function addPrismMigrationScriptCopy(script: string): string;
-export {};
diff --git a/plugin/build/withPrismaIOS.js b/plugin/build/withPrismaIOS.js
deleted file mode 100644
index f69a6252..00000000
--- a/plugin/build/withPrismaIOS.js
+++ /dev/null
@@ -1,37 +0,0 @@
-'use strict';
-Object.defineProperty(exports, '__esModule', { value: true });
-exports.addPrismMigrationScriptCopy =
- exports.modifyExistingXcodeBuildScript =
- exports.withPrismaIOS =
- void 0;
-const config_plugins_1 = require('expo/config-plugins');
-const withPrismaIOS = (config) => {
- const cfg = (0, config_plugins_1.withXcodeProject)(config, (config) => {
- const xcodeProject = config.modResults;
- const bundleReactNativePhase = xcodeProject.pbxItemByComment(
- 'Bundle React Native code and images',
- 'PBXShellScriptBuildPhase'
- );
- modifyExistingXcodeBuildScript(bundleReactNativePhase);
- return config;
- });
- return cfg;
-};
-exports.withPrismaIOS = withPrismaIOS;
-function modifyExistingXcodeBuildScript(script) {
- const code = JSON.parse(script.shellScript);
- script.shellScript = JSON.stringify(addPrismMigrationScriptCopy(code));
-}
-exports.modifyExistingXcodeBuildScript = modifyExistingXcodeBuildScript;
-function addPrismMigrationScriptCopy(script) {
- return (
- script +
- `
-
- PRISMA_MIGRATIONS="../node_modules/@prisma/react-native/copy-migrations.sh"
- chmod a+x ../node_modules/@prisma/react-native/copy-migrations.sh
-
- /bin/sh -c "$PRISMA_MIGRATIONS"`
- );
-}
-exports.addPrismMigrationScriptCopy = addPrismMigrationScriptCopy;
diff --git a/plugin/src/index.ts b/plugin/src/index.ts
deleted file mode 100644
index 509161f9..00000000
--- a/plugin/src/index.ts
+++ /dev/null
@@ -1,5 +0,0 @@
-import { withPrisma } from './withPrisma';
-
-export { withPrisma };
-
-export default withPrisma;
diff --git a/plugin/src/withPrisma.ts b/plugin/src/withPrisma.ts
deleted file mode 100644
index 9c63f265..00000000
--- a/plugin/src/withPrisma.ts
+++ /dev/null
@@ -1,34 +0,0 @@
-import type { ConfigPlugin } from 'expo/config-plugins';
-import { createRunOncePlugin, WarningAggregator } from 'expo/config-plugins';
-
-import { withPrismaAndroid } from './withPrismaAndroid';
-import { withPrismaIOS } from './withPrismaIOS';
-
-const pkg = require('../../package.json');
-
-const withPrismaPlugin: ConfigPlugin = (config) => {
- let cfg = config;
- try {
- cfg = withPrismaAndroid(cfg);
- } catch (e) {
- WarningAggregator.addWarningAndroid(
- 'prisma-expo',
- `There was a problem configuring prisma for expo in your native Android project ${e}`
- );
- }
-
- try {
- cfg = withPrismaIOS(cfg);
- } catch (e) {
- WarningAggregator.addWarningIOS(
- 'prisma-expo',
- `There was a problem configuring prisma for expo in your native iOS project ${e}`
- );
- }
-
- return cfg;
-};
-
-const withPrisma = createRunOncePlugin(withPrismaPlugin, pkg.name, pkg.version);
-
-export { withPrisma };
diff --git a/plugin/src/withPrismaAndroid.ts b/plugin/src/withPrismaAndroid.ts
deleted file mode 100644
index 6d1ba5a0..00000000
--- a/plugin/src/withPrismaAndroid.ts
+++ /dev/null
@@ -1,29 +0,0 @@
-import type { ConfigPlugin } from 'expo/config-plugins';
-import { withAppBuildGradle } from 'expo/config-plugins';
-
-const SCRIPT_LINE =
- 'apply from: "../../node_modules/@prisma/react-native/react-native-prisma.gradle"';
-
-export const withPrismaAndroid: ConfigPlugin = (config) => {
- const cfg = withAppBuildGradle(config, (config) => {
- if (config.modResults.language === 'groovy') {
- config.modResults.contents = modifyAppBuildGradle(
- config.modResults.contents
- );
- } else {
- throw new Error(
- 'Cannot configure prisma because app/Build.gradle because it is not groovy'
- );
- }
- return config;
- });
- return cfg;
-};
-
-function modifyAppBuildGradle(gradleContent: string): string {
- if (gradleContent.includes('react-native-prisma.gradle')) {
- return gradleContent;
- }
-
- return gradleContent + '\n' + SCRIPT_LINE;
-}
diff --git a/plugin/src/withPrismaIOS.ts b/plugin/src/withPrismaIOS.ts
deleted file mode 100644
index d79b0ef0..00000000
--- a/plugin/src/withPrismaIOS.ts
+++ /dev/null
@@ -1,38 +0,0 @@
-/* eslint-disable @typescript-eslint/no-unsafe-member-access */
-import type { ConfigPlugin, XcodeProject } from 'expo/config-plugins';
-import { withXcodeProject } from 'expo/config-plugins';
-
-type BuildPhase = { shellScript: string };
-
-export const withPrismaIOS: ConfigPlugin = (config) => {
- const cfg = withXcodeProject(config, (config) => {
- const xcodeProject: XcodeProject = config.modResults;
-
- const bundleReactNativePhase = xcodeProject.pbxItemByComment(
- 'Bundle React Native code and images',
- 'PBXShellScriptBuildPhase'
- );
- modifyExistingXcodeBuildScript(bundleReactNativePhase);
-
- return config;
- });
-
- return cfg;
-};
-
-export function modifyExistingXcodeBuildScript(script: BuildPhase): void {
- const code = JSON.parse(script.shellScript);
- script.shellScript = JSON.stringify(addPrismMigrationScriptCopy(code));
-}
-
-export function addPrismMigrationScriptCopy(script: string): string {
- return (
- script +
- `
-
- PRISMA_MIGRATIONS="../node_modules/@prisma/react-native/copy-migrations.sh"
- chmod a+x ../node_modules/@prisma/react-native/copy-migrations.sh
-
- /bin/sh -c "$PRISMA_MIGRATIONS"`
- );
-}
diff --git a/plugin/tsconfig.json b/plugin/tsconfig.json
deleted file mode 100644
index 059701cf..00000000
--- a/plugin/tsconfig.json
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- "extends": "expo-module-scripts/tsconfig.plugin",
- "compilerOptions": {
- "outDir": "build",
- "rootDir": "src"
- },
- "include": ["./src"],
- "exclude": ["**/__mocks__/*", "**/__tests__/*"]
-}
\ No newline at end of file
diff --git a/react-native-prisma.gradle b/react-native-prisma.gradle
deleted file mode 100644
index 69e31ace..00000000
--- a/react-native-prisma.gradle
+++ /dev/null
@@ -1,6 +0,0 @@
-tasks.register('copyFolder', Copy) {
- from "../../migrations"
- into "src/main/assets/migrations"
-}
-
-preBuild.dependsOn(copyFolder)
\ No newline at end of file
diff --git a/react-native-prisma.podspec b/react-native-prisma.podspec
deleted file mode 100644
index d8ce79fe..00000000
--- a/react-native-prisma.podspec
+++ /dev/null
@@ -1,45 +0,0 @@
-require "json"
-
-package = JSON.parse(File.read(File.join(__dir__, "package.json")))
-folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'
-
-Pod::Spec.new do |s|
- s.name = "react-native-prisma"
- s.version = package["version"]
- s.summary = package["description"]
- s.homepage = package["homepage"]
- s.license = package["license"]
- s.authors = package["author"]
-
- s.platforms = { :ios => "11.0" }
- s.source = { :git => "https://github.com/prisma/react-native-prisma.git", :tag => "#{s.version}" }
-
- s.source_files = "ios/**/*.{h,m,mm}", "cpp/**/*.{hpp,cpp,c,h}"
-
- s.vendored_frameworks = "engines/ios/QueryEngine.xcframework"
-
- s.dependency "React-callinvoker"
- s.dependency "React"
- # Use install_modules_dependencies helper to install the dependencies if React Native version >=0.71.0.
- # See https://github.com/facebook/react-native/blob/febf6b7f33fdb4904669f99d795eba4c0f95d7bf/scripts/cocoapods/new_architecture.rb#L79.
- if respond_to?(:install_modules_dependencies, true)
- install_modules_dependencies(s)
- else
- s.dependency "React-Core"
-
- # Don't install the dependencies when we run `pod install` in the old architecture.
- if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
- s.compiler_flags = folly_compiler_flags + " -DRCT_NEW_ARCH_ENABLED=1"
- s.pod_target_xcconfig = {
- "HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\"",
- "OTHER_CPLUSPLUSFLAGS" => "-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1",
- "CLANG_CXX_LANGUAGE_STANDARD" => "c++17"
- }
- s.dependency "React-Codegen"
- s.dependency "RCT-Folly"
- s.dependency "RCTRequired"
- s.dependency "RCTTypeSafety"
- s.dependency "ReactCommon/turbomodule/core"
- end
- end
-end
diff --git a/scripts/build-native-ios.sh b/scripts/build-native-ios.sh
new file mode 100755
index 00000000..165f7467
--- /dev/null
+++ b/scripts/build-native-ios.sh
@@ -0,0 +1,21 @@
+#!/bin/sh
+set -eu
+
+root=$(CDPATH= cd -- "$(dirname "$0")/.." && pwd)
+cargo="$HOME/.cargo/bin/cargo"
+rustup="$HOME/.cargo/bin/rustup"
+
+"$rustup" target add aarch64-apple-ios aarch64-apple-ios-sim x86_64-apple-ios
+"$cargo" build --release --manifest-path "$root/native/query-compiler/Cargo.toml" --target aarch64-apple-ios
+"$cargo" build --release --manifest-path "$root/native/query-compiler/Cargo.toml" --target aarch64-apple-ios-sim
+"$cargo" build --release --manifest-path "$root/native/query-compiler/Cargo.toml" --target x86_64-apple-ios
+mkdir -p "$root/native/query-compiler/target/universal-ios-sim/release"
+lipo -create \
+ "$root/native/query-compiler/target/aarch64-apple-ios-sim/release/libprisma_query_compiler_native.a" \
+ "$root/native/query-compiler/target/x86_64-apple-ios/release/libprisma_query_compiler_native.a" \
+ -output "$root/native/query-compiler/target/universal-ios-sim/release/libprisma_query_compiler_native.a"
+rm -rf "$root/native/PrismaQueryCompiler.xcframework"
+xcodebuild -create-xcframework \
+ -library "$root/native/query-compiler/target/aarch64-apple-ios/release/libprisma_query_compiler_native.a" -headers "$root/native/include" \
+ -library "$root/native/query-compiler/target/universal-ios-sim/release/libprisma_query_compiler_native.a" -headers "$root/native/include" \
+ -output "$root/native/PrismaQueryCompiler.xcframework"
diff --git a/scripts/bump-client.ts b/scripts/bump-client.ts
deleted file mode 100644
index db8a30a4..00000000
--- a/scripts/bump-client.ts
+++ /dev/null
@@ -1,33 +0,0 @@
-import fs from 'node:fs/promises';
-import path from 'node:path';
-import { $ } from 'zx';
-import { downloadEngine, ensureNpmTag, writeVersionFile } from './utils';
-
-async function main() {
- const tag = process.argv[2];
- ensureNpmTag(tag);
- const version = process.argv[3];
- if (!version) {
- console.error(`Usage: bump-engines `);
- process.exitCode = 1;
- return;
- }
- await updatePkgJsonVersion(version);
- await $`yarn up prisma@${version} @prisma/client@${version}`;
- const enginesVersion = require('@prisma/engines-version').enginesVersion;
-
- await writeVersionFile('engine', enginesVersion);
- await writeVersionFile(`prisma-${tag}`, version);
- // downloading updated engine
- await downloadEngine();
-}
-
-async function updatePkgJsonVersion(version: string) {
- const pkgJsonPath = path.resolve(__dirname, '..', 'package.json');
- const content = JSON.parse(await fs.readFile(pkgJsonPath, 'utf8'));
- content.version = version;
-
- await fs.writeFile(pkgJsonPath, JSON.stringify(content, null, 2));
-}
-
-main();
diff --git a/scripts/check-updates.ts b/scripts/check-updates.ts
deleted file mode 100644
index d4a5a4a4..00000000
--- a/scripts/check-updates.ts
+++ /dev/null
@@ -1,45 +0,0 @@
-import fs from 'node:fs/promises';
-import pRetry from 'p-retry';
-import { $ } from 'zx';
-
-import { NPM_TAGS, type NpmTag, readVersionFile } from './utils';
-
-async function main() {
- for (const tag of NPM_TAGS.filter((tag) => tag !== 'integration')) {
- await checkUpdate(tag);
- }
-}
-
-async function checkUpdate(tag: NpmTag) {
- console.log(`Checking update for npm tag: ${tag}`);
- const currentVersion = await readVersionFile(`prisma-${tag}`);
- const npmVersion = await getNpmVersion(tag);
- console.log(`Current version ${currentVersion}`);
- console.log(`npm version ${npmVersion}`);
- if (currentVersion !== npmVersion) {
- console.log('Update needed');
- const ghOut = process.env.GITHUB_OUTPUT;
- if (ghOut) {
- await fs.appendFile(ghOut, `${tag}=${npmVersion}\n`);
- }
- } else {
- console.log('Up to date');
- }
-}
-
-async function getNpmVersion(tag: NpmTag) {
- const content = await pRetry(
- () => $`yarn npm info prisma@${tag} --json -f version`,
- {
- retries: 3,
- }
- );
-
- const parsed = JSON.parse(content.stdout);
- if (typeof parsed?.version !== 'string') {
- throw new Error(`Can not get npm version for prisma@${tag}`);
- }
- return parsed.version;
-}
-
-main();
diff --git a/scripts/download-engine.ts b/scripts/download-engine.ts
deleted file mode 100644
index 312a8595..00000000
--- a/scripts/download-engine.ts
+++ /dev/null
@@ -1,3 +0,0 @@
-import { downloadEngine } from './utils';
-
-downloadEngine();
diff --git a/scripts/obfuscate.cjs b/scripts/obfuscate.cjs
new file mode 100755
index 00000000..abea72bc
--- /dev/null
+++ b/scripts/obfuscate.cjs
@@ -0,0 +1,32 @@
+#!/usr/bin/env node
+
+const fs = require('node:fs');
+const path = require('node:path');
+const { minify } = require('terser');
+
+const files = [];
+const collect = (target) => {
+ const stat = fs.statSync(target);
+ if (stat.isDirectory()) {
+ for (const name of fs.readdirSync(target)) collect(path.join(target, name));
+ } else if (/\.(?:c?js|mjs)$/.test(target)) {
+ files.push(target);
+ } else if (target.endsWith('.map')) {
+ fs.unlinkSync(target);
+ }
+};
+
+for (const target of process.argv.slice(2)) collect(path.resolve(target));
+
+Promise.all(
+ files.map(async (file) => {
+ const result = await minify(fs.readFileSync(file, 'utf8'), {
+ compress: { passes: 2 },
+ mangle: { toplevel: true },
+ module: file.includes(`${path.sep}module${path.sep}`),
+ format: { comments: false },
+ });
+ if (!result.code) throw new Error(`Failed to obfuscate ${file}`);
+ fs.writeFileSync(file, result.code);
+ })
+).then(() => console.log(`Obfuscated ${files.length} JavaScript files`));
diff --git a/scripts/patch-prisma-runtime.cjs b/scripts/patch-prisma-runtime.cjs
new file mode 100644
index 00000000..30f8bde6
--- /dev/null
+++ b/scripts/patch-prisma-runtime.cjs
@@ -0,0 +1,199 @@
+#!/usr/bin/env node
+
+const fs = require('node:fs');
+
+const runtimeFiles = [...new Set(
+ [process.env.INIT_CWD, process.cwd()].filter(Boolean).flatMap((root) =>
+ ['client.js', 'client.mjs'].flatMap((file) => {
+ try {
+ return [require.resolve(`@prisma/client/runtime/${file}`, { paths: [root] })];
+ } catch {
+ return [];
+ }
+ })
+ )
+)];
+
+const cryptoShim = `var PrismaReactNativeCrypto=(()=>{let getRandomValues=value=>{if(globalThis.crypto?.getRandomValues)return globalThis.crypto.getRandomValues(value);for(let i=0;igetRandomValues(Buffer.allocUnsafe(size));return{getRandomValues,randomBytes,randomUUID:globalThis.crypto?.randomUUID?.bind(globalThis.crypto)??(()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,value=>{let random=Math.random()*16|0;return(value==="x"?random:random&3|8).toString(16)})),webcrypto:{getRandomValues}}})();`;
+const legacyProcess = 'var process=globalThis.process??{env:{},pid:0,stdout:{isTTY:false},release:{},cwd:()=>"/"};';
+const processShim = 'var PrismaReactNativeProcess=globalThis.process??{},process={env:PrismaReactNativeProcess.env??{},pid:PrismaReactNativeProcess.pid??0,stdout:PrismaReactNativeProcess.stdout??{isTTY:false},release:PrismaReactNativeProcess.release??{},cwd:typeof PrismaReactNativeProcess.cwd==="function"?PrismaReactNativeProcess.cwd.bind(PrismaReactNativeProcess):()=>"/"};';
+const legacyCjsPrefix = `var {Buffer}=require("buffer");${legacyProcess}${cryptoShim}`;
+const cjsPrefix = `var {Buffer}=require("buffer");${processShim}${cryptoShim}`;
+const asyncResource = 'class{runInAsyncScope(callback){return callback()}}';
+const eventEmitter = 'class{constructor(){this.listeners={}}on(name,listener){(this.listeners[name]??=[]).push(listener);return this}emit(name,...args){for(let listener of this.listeners[name]??[])listener(...args)}}';
+
+function patchPortability(source, runtimePath) {
+ if (runtimePath.endsWith('.mjs')) {
+ source = source
+ .replace(
+ /^import \* as __banner_node_module from "node:module";\nimport \* as __banner_node_path from "node:path";\nimport \* as process from "node:process";\nimport \* as __banner_node_url from "node:url";\nconst __filename = __banner_node_url\.fileURLToPath\(import\.meta\.url\);\nglobalThis\['__dirname'\] = __banner_node_path\.dirname\(__filename\);\nconst require = __banner_node_module\.createRequire\(import\.meta\.url\);\n/,
+ `import { Buffer } from "buffer";\n${processShim}\nglobalThis['__dirname']='/';\n${cryptoShim}\nconst require=()=>PrismaReactNativeCrypto;\n`
+ )
+ .replace(/import ([A-Za-z_$][\w$]*) from"node:path";/g, 'var $1={sep:"/",posix:{sep:"/"}};')
+ .replace(/import ([A-Za-z_$][\w$]*) from"node:fs";/g, 'var $1={readFileSync:()=>{throw new Error("File access is unavailable")}};')
+ .replace(/import ([A-Za-z_$][\w$]*) from"node:os";/g, 'var $1={hostname:()=>"react-native"};')
+ .replace(
+ /import\{AsyncResource as ([A-Za-z_$][\w$]*)\}from"node:async_hooks";import\{EventEmitter as ([A-Za-z_$][\w$]*)\}from"node:events";/g,
+ `var $1=${asyncResource},$2=${eventEmitter};`
+ )
+ .replace(/import\{webcrypto as ([A-Za-z_$][\w$]*)\}from"node:crypto";/g, 'var $1=PrismaReactNativeCrypto.webcrypto;')
+ .replace(/import ([A-Za-z_$][\w$]*) from"node:crypto";/g, 'var $1=PrismaReactNativeCrypto;');
+ source = source.replace(
+ 'const process=globalThis.process??{env:{},pid:0,stdout:{isTTY:false},release:{},cwd:()=>"/"};',
+ processShim
+ );
+ } else {
+ let body = source.replace(/^"use strict";/, '');
+ for (const prefix of [legacyCjsPrefix, cjsPrefix]) {
+ while (body.startsWith(prefix)) body = body.slice(prefix.length);
+ }
+ source = `"use strict";${cjsPrefix}${body}`;
+ source = source
+ .replace(/var ([A-Za-z_$][\w$]*)=[A-Za-z_$][\w$]*\(require\("node:path"\)(?:,1)?\);/g, 'var $1={default:{sep:"/",posix:{sep:"/"}}};')
+ .replace(/var ([A-Za-z_$][\w$]*)=[A-Za-z_$][\w$]*\(require\("node:fs"\)(?:,1)?\);/g, 'var $1={default:{readFileSync:()=>{throw new Error("File access is unavailable")}}};')
+ .replace(/var ([A-Za-z_$][\w$]*)=[A-Za-z_$][\w$]*\(require\("node:os"\)(?:,1)?\);/g, 'var $1={default:{hostname:()=>"react-native"}};')
+ .replace(
+ /var ([A-Za-z_$][\w$]*)=require\("node:async_hooks"\),([A-Za-z_$][\w$]*)=require\("node:events"\);/g,
+ `var $1={AsyncResource:${asyncResource}},$2={EventEmitter:${eventEmitter}};`
+ );
+ }
+
+ source = source
+ .replace(/[A-Za-z_$][\w$]*\("node:crypto"\)/g, 'PrismaReactNativeCrypto')
+ .replace(/import\("node:crypto"\)/g, 'PrismaReactNativeCrypto')
+ .replace('globalThis.crypto??await PrismaReactNativeCrypto', 'PrismaReactNativeCrypto')
+ .replace(
+ /Buffer\.from\(([A-Za-z_$][\w$]*),"base64url"\)/g,
+ 'Buffer.from($1.replace(/-/g,"+").replace(/_/g,"/"),"base64")'
+ );
+ const unsupported = source.match(/["']node:(?:module|path|process|url|crypto|fs|os|async_hooks|events)["']/)?.[0];
+ if (unsupported) throw new Error(`Unsupported Node runtime import ${unsupported}: ${runtimePath}`);
+ return source;
+}
+
+function patchRuntime(runtimePath) {
+ let source = fs.readFileSync(runtimePath, 'utf8');
+ const original = source;
+ if (!source.includes('7.9.1')) {
+ throw new Error(`Unsupported @prisma/client runtime: ${runtimePath}`);
+ }
+ const portableSource = patchPortability(source, runtimePath);
+ source = portableSource;
+ if (!source.includes('getNativeQueryCompiler')) {
+ source = source.replace(
+ 'async loadQueryCompiler(e){let{clientVersion:t,compilerWasm:r}=e;if(r===void 0)',
+ 'async loadQueryCompiler(e){let{clientVersion:t,compilerWasm:r}=e;if(r?.getNativeQueryCompiler)return r.getNativeQueryCompiler();if(r===void 0)'
+ );
+ }
+ if (!source.includes('r?.getNativeQueryCompiler')) {
+ throw new Error(`Could not patch Prisma native query compiler: ${runtimePath}`);
+ }
+ const changed = source !== original;
+ if (source.includes('sending synchronous request')) {
+ if (changed) fs.writeFileSync(runtimePath, source);
+ return changed;
+ }
+
+ const queryStart = source.search(
+ /var [A-Za-z_$][\w$]*=class e\{#e;#t=new [A-Za-z_$][\w$]*;#r;#n;#i;#o;#s;constructor/
+ );
+ const queryEnd = source.indexOf('};function', queryStart) + 2;
+ if (queryStart < 0 || queryEnd < 2) {
+ throw new Error(`Could not locate Prisma QueryInterpreter: ${runtimePath}`);
+ }
+
+ const queryClass = source.slice(queryStart, queryEnd);
+ let syncClass = queryClass
+ .replace(/^var [A-Za-z_$][\w$]*=class e\{/, 'var PrismaSyncQueryInterpreter=class PrismaSyncQueryInterpreter{')
+ .replace(/static forSql\(t\)\{return new e\(/, 'static forSql(t){return new PrismaSyncQueryInterpreter(');
+
+ const runStart = syncClass.indexOf('async run(t,r){');
+ const runEnd = syncClass.indexOf('async interpretNode(t,r){', runStart);
+ const errorMapper = syncClass.slice(runStart, runEnd).match(/\.catch\(i=>([A-Za-z_$][\w$]*)\(i\)\)/)?.[1];
+ if (!errorMapper) {
+ throw new Error(`Could not patch Prisma QueryInterpreter.run: ${runtimePath}`);
+ }
+ syncClass =
+ syncClass.slice(0, runStart) +
+ `run(t,r){try{let{value:n}=this.interpretNode(t,{...r,generators:this.#t.snapshot()});return n}catch(i){throw ${errorMapper}(i)}}` +
+ syncClass.slice(runEnd).replace('async interpretNode(t,r){', 'interpretNode(t,r){');
+
+ syncClass = syncClass
+ .replace(
+ /await Promise\.all\(t\.args\.map\(i=>this\.interpretNode\(i,r\)\.then\(o=>o\.value\)\)\)/g,
+ 't.args.map(i=>this.interpretNode(i,r).value)'
+ )
+ .replace(
+ /await Promise\.all\(t\.args\.children\.map\(async s=>\(\{joinExpr:s,childRecords:\(await this\.interpretNode\(s\.child,r\)\)\.value\}\)\)\)/g,
+ 't.args.children.map(s=>({joinExpr:s,childRecords:this.interpretNode(s.child,r).value}))'
+ )
+ .replaceAll('await ', '')
+ .replace(
+ /#u\(t,r,n\)\{return [A-Za-z_$][\w$]*\(\{query:t,execute:n,provider:this\.#o\?\?r\.provider,tracingHelper:this\.#r,onQuery:this\.#e\}\)\}/,
+ '#u(t,r,n){let i=new Date,o=performance.now(),s=n();return this.#e?.({timestamp:i,duration:performance.now()-o,query:t.sql,params:t.args}),s}'
+ );
+
+ if (syncClass.includes('await ') || syncClass.includes('Promise.all(')) {
+ throw new Error(`Prisma synchronous interpreter still contains async work: ${runtimePath}`);
+ }
+ source = source.slice(0, queryEnd) + syncClass + source.slice(queryEnd);
+
+ const localStart = source.search(
+ /var [A-Za-z_$][\w$]*=class e\{#e;#t;#r;#n;#i;constructor\(t,r,n\)/
+ );
+ const transactionMarker = source.indexOf('async startTransaction(t){', localStart);
+ if (localStart < 0 || transactionMarker < 0) {
+ throw new Error(`Could not locate Prisma LocalExecutor: ${runtimePath}`);
+ }
+ const executeSync =
+ 'executeSync({plan:t,placeholderValues:r,transaction:n,queryInfo:i}){' +
+ 'if(n)throw new Error("Synchronous queries cannot run inside an interactive transaction");' +
+ 'let o=this.#t;if(typeof o.queryRawSync!=="function"||typeof o.executeRawSync!=="function")throw new Error("The Prisma driver adapter does not support synchronous queries");' +
+ 'let s=t=>({provider:t.provider,queryRaw:r=>({catch:n=>{try{return t.queryRawSync(r)}catch(i){return n(i)}}}),executeRaw:r=>({catch:n=>{try{return t.executeRawSync(r)}catch(i){return n(i)}}})}),a,l={startInternalTransaction:()=>{if(typeof o.startTransactionSync!=="function")throw new Error("The Prisma driver adapter does not support synchronous transactions");return a=o.startTransactionSync(),{id:"sync"}},getTransaction:()=>s(a),commitTransaction:()=>{a.commitSync();a=void 0},rollbackTransaction:()=>{a.rollbackSync();a=void 0}};' +
+ 'return PrismaSyncQueryInterpreter.forSql({onQuery:this.#e.onQuery,tracingHelper:this.#e.tracingHelper,provider:this.#e.provider,connectionInfo:this.#n}).run(t,{queryable:s(o),transactionManager:{enabled:!0,manager:l},scope:r,sqlCommenter:this.#e.sqlCommenters&&{plugins:this.#e.sqlCommenters,queryInfo:i}})}';
+ source = source.slice(0, transactionMarker) + executeSync + source.slice(transactionMarker);
+
+ const requestStart = source.indexOf(
+ 'async request(t,{interactiveTransaction:r,customDataProxyFetch:n}){'
+ );
+ const requestEnd = source.indexOf('async requestBatch(', requestStart);
+ if (requestStart < 0 || requestEnd < 0) {
+ throw new Error(`Could not locate Prisma ClientEngine.request: ${runtimePath}`);
+ }
+ const request = source.slice(requestStart, requestEnd);
+ const requestPrefix = request.match(
+ /^async request\(t,\{interactiveTransaction:r,customDataProxyFetch:n\}\)\{([A-Za-z_$][\w$]*)\("sending request"\);let\{executor:i,queryCompiler:o\}=await this\.#a\(\)\.catch\(u=>\{throw this\.#c\(u,JSON\.stringify\(t\)\)\}\),s,a=\{\},l=t\.query;/
+ );
+ if (!requestPrefix) {
+ throw new Error(`Could not patch Prisma ClientEngine.request: ${runtimePath}`);
+ }
+ const debug = requestPrefix[1];
+ const syncRequest = request
+ .replace(
+ requestPrefix[0],
+ `requestSync(t,{interactiveTransaction:r}={}){${debug}("sending synchronous request");if(r)throw new Error("Synchronous queries require a connected Prisma client");if(this.#t.type!=="connected")throw new Error("Connect Prisma before using synchronous queries");let{executor:i,queryCompiler:o}=this.#t.engine,s,a={},l=t.query;`
+ )
+ .replace('let u=await i.execute({', 'let u=i.executeSync({')
+ .replace('customFetch:n?.(globalThis.fetch),', '');
+ if (syncRequest.includes('await ') || syncRequest.includes('customDataProxyFetch')) {
+ throw new Error(
+ `Prisma synchronous request still contains async work: ${runtimePath}: ${
+ syncRequest.match(/.{0,40}(?:await |customDataProxyFetch).{0,80}/g)?.join(' | ')
+ }`
+ );
+ }
+ source = source.slice(0, requestStart) + syncRequest + source.slice(requestStart);
+
+ fs.writeFileSync(runtimePath, source);
+ return true;
+}
+
+if (runtimeFiles.length === 0) {
+ console.warn('Could not find @prisma/client 7 runtime to patch');
+} else {
+ for (const runtimePath of runtimeFiles) {
+ if (patchRuntime(runtimePath)) {
+ console.log(`Patched Prisma 7 synchronous runtime: ${runtimePath}`);
+ }
+ }
+}
diff --git a/scripts/prepare-client.cjs b/scripts/prepare-client.cjs
new file mode 100755
index 00000000..05517fe4
--- /dev/null
+++ b/scripts/prepare-client.cjs
@@ -0,0 +1,120 @@
+#!/usr/bin/env node
+
+const crypto = require('node:crypto');
+const fs = require('node:fs');
+const path = require('node:path');
+
+require('./patch-prisma-runtime.cjs');
+
+const directory = path.resolve(process.argv[2] ?? 'generated/prisma');
+const migrationsDirectory = path.resolve(
+ process.argv[3] ?? 'prisma/migrations'
+);
+const clientPath = path.join(directory, 'client.ts');
+const classPath = path.join(directory, 'internal/class.ts');
+const migrations = fs.existsSync(migrationsDirectory)
+ ? fs
+ .readdirSync(migrationsDirectory, { withFileTypes: true })
+ .filter((entry) => entry.isDirectory())
+ .sort((a, b) => a.name.localeCompare(b.name))
+ .map((entry) => {
+ const source = fs.readFileSync(
+ path.join(migrationsDirectory, entry.name, 'migration.sql')
+ );
+ return {
+ name: entry.name,
+ checksum: crypto.createHash('sha256').update(source).digest('hex'),
+ sql: source.toString(),
+ };
+ })
+ : [];
+
+let client = fs.readFileSync(clientPath, 'utf8');
+client = client.replace(
+ /import \* as process from 'node:process'\nimport \* as path from 'node:path'\nimport \{ fileURLToPath \} from 'node:url'\nglobalThis\['__dirname'\] = path\.dirname\(fileURLToPath\(import\.meta\.url\)\)/,
+ "globalThis['__dirname'] = '/'"
+);
+if (/from 'node:/.test(client)) {
+ throw new Error(`Unsupported Node import in Prisma client: ${clientPath}`);
+}
+fs.writeFileSync(clientPath, client);
+
+let runtime = fs
+ .readFileSync(classPath, 'utf8')
+ .replace('import { Buffer } from "buffer"\n', '');
+if (!runtime.includes('import { NativeQueryCompiler }')) {
+ runtime = runtime.replace(
+ 'import * as runtime from "@prisma/client/runtime/client"',
+ 'import * as runtime from "@prisma/client/runtime/client"\nimport { NativeQueryCompiler } from "@prisma/react-native"'
+ );
+}
+if (!runtime.includes('getNativeQueryCompiler')) {
+ const functionStart = runtime.indexOf('function decodeBase64AsWasm');
+ const start = runtime.lastIndexOf('\n', functionStart) + 1;
+ const end = runtime.indexOf('\n\n\nexport type ', start);
+ if (functionStart < 0 || end < 0) {
+ throw new Error(`Unsupported Prisma client: ${classPath}`);
+ }
+ runtime =
+ runtime.slice(0, start) +
+ `config.compilerWasm = {
+ getNativeQueryCompiler: async () => NativeQueryCompiler
+} as any` +
+ runtime.slice(end);
+}
+const migrationBlock = `// @prisma/react-native migrations:start
+const migrations = ${JSON.stringify(migrations)}
+// @prisma/react-native migrations:end`;
+runtime = runtime.replace(
+ /\/\/ @prisma\/react-native migrations:start[\s\S]*?\/\/ @prisma\/react-native migrations:end\n*/,
+ ''
+);
+runtime = runtime.replace(
+ 'config.compilerWasm = {',
+ `${migrationBlock}\n\nconfig.compilerWasm = {`
+);
+
+if (!runtime.includes('$applyPendingMigrations():')) {
+ runtime = runtime.replace(
+ ' $connect(): runtime.Types.Utils.JsPromise;',
+ ` $connect(): runtime.Types.Utils.JsPromise;
+
+ $applyPendingMigrations(): runtime.Types.Utils.JsPromise;`
+ );
+}
+if (!runtime.includes('adapter?.setMigrations?.(migrations)')) {
+ runtime = runtime.replace(
+ `export function getPrismaClientClass(): PrismaClientConstructor {
+ return runtime.getPrismaClient(config) as unknown as PrismaClientConstructor
+}`,
+ `export function getPrismaClientClass(): PrismaClientConstructor {
+ const PrismaClient = runtime.getPrismaClient(config)
+ return class extends PrismaClient {
+ constructor(options: any) {
+ options?.adapter?.setMigrations?.(migrations)
+ super(options)
+ }
+
+ async $applyPendingMigrations() {
+ await this.$connect()
+ const adapter = this._engineConfig.adapter
+ if (typeof adapter?.applyPendingMigrations !== 'function') {
+ throw new Error('The Prisma adapter does not support migrations')
+ }
+ adapter.applyPendingMigrations()
+ }
+ } as unknown as PrismaClientConstructor
+}`
+ );
+}
+if (
+ !runtime.includes('getNativeQueryCompiler') ||
+ !runtime.includes('adapter?.setMigrations?.(migrations)')
+) {
+ throw new Error(`Unsupported Prisma client: ${classPath}`);
+}
+fs.writeFileSync(classPath, runtime);
+
+console.log(
+ `Prepared generated Prisma 7 client with ${migrations.length} migration(s): ${directory}`
+);
diff --git a/scripts/utils.ts b/scripts/utils.ts
deleted file mode 100644
index 6f57b136..00000000
--- a/scripts/utils.ts
+++ /dev/null
@@ -1,49 +0,0 @@
-import fs from 'node:fs/promises';
-import path from 'node:path';
-import { pipeline } from 'node:stream/promises';
-import { Extract } from 'unzipper';
-
-export const NPM_TAGS = ['dev', 'latest', 'integration'] as const;
-export type NpmTag = (typeof NPM_TAGS)[number];
-
-type VersionFile = `prisma-${NpmTag}` | 'engine';
-
-export function ensureNpmTag(str: string): asserts str is NpmTag {
- if (!(NPM_TAGS as readonly string[]).includes(str)) {
- throw new Error(`${str} is not supported npm tag`);
- }
-}
-
-export async function readVersionFile(file: VersionFile): Promise {
- const version = await fs.readFile(versionFilePath(file), 'utf8');
- return version.trim();
-}
-
-export function writeVersionFile(
- file: VersionFile,
- version: string
-): Promise {
- return fs.writeFile(versionFilePath(file), version);
-}
-
-export async function downloadEngine() {
- const version = await readVersionFile('engine');
-
- console.log(`Downloading engine ${version}`);
-
- const url = `https://binaries.prisma.sh/all_commits/${version}/react-native/binaries.zip`;
-
- const resp = await fetch(url);
- if (!resp.body) {
- throw new Error('Failed to read the response from binaries server');
- }
- await pipeline(
- resp.body,
- Extract({ path: path.resolve(__dirname, '..', 'engines') })
- );
-
- console.log('Download complete');
-}
-function versionFilePath(file: VersionFile): string {
- return path.resolve(__dirname, '..', '.versions', file);
-}
diff --git a/src/ExpoSQLiteAdapter.ts b/src/ExpoSQLiteAdapter.ts
new file mode 100644
index 00000000..13cc0e33
--- /dev/null
+++ b/src/ExpoSQLiteAdapter.ts
@@ -0,0 +1,324 @@
+import {
+ ColumnTypeEnum,
+ DriverAdapterError,
+ type ArgType,
+ type IsolationLevel,
+ type SqlDriverAdapter,
+ type SqlDriverAdapterFactory,
+ type SqlQuery,
+ type SqlResultSet,
+ type Transaction,
+} from '@prisma/driver-adapter-utils';
+import {
+ openDatabaseSync,
+ type SQLiteBindValue,
+ type SQLiteDatabase,
+} from 'expo-sqlite';
+
+type Config = { url: string; directory?: string };
+type Migration = { name: string; checksum: string; sql: string };
+
+interface QueryableDriver {
+ queryRawSync(query: SqlQuery): SqlResultSet;
+ executeRawSync(query: SqlQuery): number;
+}
+
+interface DriverTransaction extends Transaction, QueryableDriver {
+ commitSync(): void;
+ rollbackSync(): void;
+}
+
+interface DriverAdapter extends SqlDriverAdapter, QueryableDriver {
+ startTransactionSync(isolationLevel?: IsolationLevel): DriverTransaction;
+}
+
+const mapArg = (value: unknown, type: ArgType): SQLiteBindValue => {
+ if (value == null) return null;
+ if (typeof value === 'boolean') return value;
+ if (value instanceof Uint8Array || value instanceof ArrayBuffer) return value;
+ if (value instanceof Date) return value.toISOString().replace('Z', '+00:00');
+ if (typeof value === 'bigint') {
+ const number = Number(value);
+ return Number.isSafeInteger(number) ? number : value.toString();
+ }
+ if (typeof value === 'string') {
+ if (type.scalarType === 'int' || type.scalarType === 'float') {
+ return Number(value);
+ }
+ if (type.scalarType === 'bigint') {
+ const number = Number(value);
+ return Number.isSafeInteger(number) ? number : value;
+ }
+ if (type.scalarType === 'datetime') {
+ return new Date(value).toISOString().replace('Z', '+00:00');
+ }
+ if (type.scalarType === 'bytes') {
+ return Uint8Array.from(atob(value), (char) => char.charCodeAt(0));
+ }
+ return value;
+ }
+ if (typeof value === 'number') return value;
+ throw new TypeError(`Unsupported SQLite argument: ${typeof value}`);
+};
+
+const inferType = (rows: unknown[][], column: number) => {
+ const value = rows.find((row) => row[column] != null)?.[column];
+ if (value instanceof Uint8Array || value instanceof ArrayBuffer) {
+ return ColumnTypeEnum.Bytes;
+ }
+ switch (typeof value) {
+ case 'boolean':
+ return ColumnTypeEnum.Boolean;
+ case 'number':
+ case 'bigint':
+ return ColumnTypeEnum.UnknownNumber;
+ default:
+ return ColumnTypeEnum.Text;
+ }
+};
+
+const convertError = (error: any) => {
+ const message = String(error?.message ?? error);
+ if (message.includes('UNIQUE constraint failed')) {
+ return new DriverAdapterError({
+ kind: 'UniqueConstraintViolation',
+ constraint: {
+ fields:
+ message
+ .split(': ')
+ .at(1)
+ ?.split(', ')
+ .map((field) => field.split('.').at(-1)!) ?? [],
+ },
+ });
+ }
+ if (message.includes('NOT NULL constraint failed')) {
+ return new DriverAdapterError({
+ kind: 'NullConstraintViolation',
+ constraint: {
+ fields:
+ message
+ .split(': ')
+ .at(1)
+ ?.split(', ')
+ .map((field) => field.split('.').at(-1)!) ?? [],
+ },
+ });
+ }
+ if (message.includes('FOREIGN KEY constraint failed')) {
+ return new DriverAdapterError({
+ kind: 'ForeignKeyConstraintViolation',
+ constraint: { foreignKey: {} },
+ });
+ }
+ if (message.includes('no such table:')) {
+ return new DriverAdapterError({
+ kind: 'TableDoesNotExist',
+ table: message.split('no such table:').at(1)!.trim(),
+ });
+ }
+ return error;
+};
+
+class Queryable {
+ readonly provider = 'sqlite' as const;
+ readonly adapterName = '@prisma/react-native';
+
+ constructor(protected readonly db: SQLiteDatabase) {}
+
+ queryRawSync(query: SqlQuery): SqlResultSet {
+ const statement = this.db.prepareSync(query.sql);
+ try {
+ const result = statement.executeForRawResultSync(
+ query.args.map((arg, index) => mapArg(arg, query.argTypes[index]))
+ );
+ const rows = result.getAllSync() as unknown[][];
+ const columnNames = statement.getColumnNamesSync();
+ return {
+ columnNames,
+ columnTypes: columnNames.map((_, index) => inferType(rows, index)),
+ rows,
+ lastInsertId: String(result.lastInsertRowId),
+ };
+ } catch (error) {
+ throw convertError(error);
+ } finally {
+ statement.finalizeSync();
+ }
+ }
+
+ executeRawSync(query: SqlQuery): number {
+ try {
+ return this.db.runSync(
+ query.sql,
+ query.args.map((arg, index) => mapArg(arg, query.argTypes[index]))
+ ).changes;
+ } catch (error) {
+ throw convertError(error);
+ }
+ }
+
+ queryRaw(query: SqlQuery) {
+ return Promise.resolve(this.queryRawSync(query));
+ }
+
+ executeRaw(query: SqlQuery) {
+ return Promise.resolve(this.executeRawSync(query));
+ }
+}
+
+class ExpoSQLiteTransaction
+ extends Queryable
+ implements DriverTransaction
+{
+ readonly options = { usePhantomQuery: false };
+
+ commitSync() {
+ this.db.execSync('COMMIT');
+ }
+
+ commit() {
+ this.commitSync();
+ return Promise.resolve();
+ }
+
+ rollbackSync() {
+ this.db.execSync('ROLLBACK');
+ }
+
+ rollback() {
+ this.rollbackSync();
+ return Promise.resolve();
+ }
+}
+
+class ExpoSQLiteAdapter
+ extends Queryable
+ implements DriverAdapter
+{
+ constructor(db: SQLiteDatabase, private readonly onDispose: () => void) {
+ super(db);
+ }
+
+ executeScript(script: string) {
+ this.db.execSync(script);
+ return Promise.resolve();
+ }
+
+ startTransactionSync(isolationLevel?: IsolationLevel) {
+ if (isolationLevel && isolationLevel !== 'SERIALIZABLE') {
+ throw new DriverAdapterError({
+ kind: 'InvalidIsolationLevel',
+ level: isolationLevel,
+ });
+ }
+ this.db.execSync('BEGIN IMMEDIATE');
+ return new ExpoSQLiteTransaction(this.db);
+ }
+
+ startTransaction(isolationLevel?: IsolationLevel) {
+ try {
+ return Promise.resolve(this.startTransactionSync(isolationLevel));
+ } catch (error) {
+ return Promise.reject(error);
+ }
+ }
+
+ getConnectionInfo() {
+ return { maxBindValues: 999, supportsRelationJoins: false };
+ }
+
+ applyPendingMigrations(migrations: readonly Migration[]) {
+ this.db.execSync(`
+ CREATE TABLE IF NOT EXISTS "_prisma_migrations" (
+ "id" TEXT NOT NULL PRIMARY KEY,
+ "checksum" TEXT NOT NULL,
+ "finished_at" DATETIME,
+ "migration_name" TEXT NOT NULL,
+ "logs" TEXT,
+ "rolled_back_at" DATETIME,
+ "started_at" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
+ "applied_steps_count" INTEGER UNSIGNED NOT NULL DEFAULT 0
+ )
+ `);
+
+ for (const migration of migrations) {
+ const applied = this.db.getFirstSync<{ checksum: string }>(
+ `SELECT "checksum" FROM "_prisma_migrations"
+ WHERE "migration_name" = ?
+ AND "finished_at" IS NOT NULL
+ AND "rolled_back_at" IS NULL`,
+ migration.name
+ );
+ if (applied) {
+ if (applied.checksum !== migration.checksum) {
+ throw new Error(`Migration ${migration.name} was modified after applying`);
+ }
+ continue;
+ }
+
+ this.db.execSync('BEGIN IMMEDIATE');
+ try {
+ this.db.execSync(migration.sql);
+ this.db.runSync(
+ `INSERT INTO "_prisma_migrations"
+ ("id", "checksum", "finished_at", "migration_name", "applied_steps_count")
+ VALUES (?, ?, CURRENT_TIMESTAMP, ?, 1)`,
+ [migration.name, migration.checksum, migration.name]
+ );
+ this.db.execSync('COMMIT');
+ } catch (error) {
+ this.db.execSync('ROLLBACK');
+ throw error;
+ }
+ }
+ }
+
+ dispose() {
+ this.db.closeSync();
+ this.onDispose();
+ return Promise.resolve();
+ }
+}
+
+export class PrismaExpoSQLite implements SqlDriverAdapterFactory {
+ readonly provider = 'sqlite' as const;
+ readonly adapterName = '@prisma/react-native';
+ #adapter?: ExpoSQLiteAdapter;
+ #migrations: readonly Migration[] = [];
+
+ constructor(private readonly config: Config | string) {}
+
+ private connectAdapter() {
+ if (this.#adapter) return this.#adapter;
+ const url = typeof this.config === 'string' ? this.config : this.config.url;
+ const directory =
+ typeof this.config === 'string' ? undefined : this.config.directory;
+ const path = url.replace(/^file:/, '');
+ const slash = path.lastIndexOf('/');
+ const databaseName = slash < 0 ? path : path.slice(slash + 1);
+ this.#adapter = new ExpoSQLiteAdapter(
+ openDatabaseSync(
+ databaseName || 'app.db',
+ {},
+ directory ?? (slash < 0 ? undefined : path.slice(0, slash))
+ ),
+ () => {
+ this.#adapter = undefined;
+ }
+ );
+ return this.#adapter;
+ }
+
+ setMigrations(migrations: readonly Migration[]) {
+ this.#migrations = migrations;
+ }
+
+ applyPendingMigrations() {
+ this.connectAdapter().applyPendingMigrations(this.#migrations);
+ }
+
+ connect() {
+ return Promise.resolve(this.connectAdapter());
+ }
+}
diff --git a/src/NativePrisma.ts b/src/NativePrisma.ts
deleted file mode 100644
index 4476acb6..00000000
--- a/src/NativePrisma.ts
+++ /dev/null
@@ -1,8 +0,0 @@
-import type { TurboModule } from 'react-native';
-import { TurboModuleRegistry } from 'react-native';
-
-export interface Spec extends TurboModule {
- install(): void;
-}
-
-export default TurboModuleRegistry.getEnforcing('Prisma');
diff --git a/src/QueriesExtension.ts b/src/QueriesExtension.ts
new file mode 100644
index 00000000..995c2c2d
--- /dev/null
+++ b/src/QueriesExtension.ts
@@ -0,0 +1,327 @@
+import { Prisma } from '@prisma/client/extension';
+import {
+ type Action,
+ serializeJsonQuery,
+} from '@prisma/client/runtime/client';
+
+const request = (
+ client: any,
+ modelName: string,
+ action: Action,
+ args: any,
+ protocolArgs = args,
+ unpacker?: (data: any) => any
+) => {
+ const engine = client._engine;
+ if (!engine?.requestSync) {
+ throw new Error(
+ 'Prisma synchronous runtime is unavailable. Install @prisma/react-native after @prisma/client.'
+ );
+ }
+
+ const clientMethod = `${modelName}.${action}`;
+ const protocolQuery = serializeJsonQuery({
+ modelName,
+ runtimeDataModel: client._runtimeDataModel,
+ action,
+ args: protocolArgs,
+ clientMethod,
+ callsite: undefined,
+ extensions: client._extensions,
+ errorFormat: client._errorFormat,
+ clientVersion: client._clientVersion,
+ previewFeatures: client._previewFeatures,
+ globalOmit: client._globalOmit,
+ });
+ const response = engine.requestSync(protocolQuery, {
+ traceparent: client._tracingHelper.getTraceParent(),
+ });
+
+ return client._requestHandler.mapQueryEngineResult(
+ {
+ protocolQuery,
+ modelName,
+ action,
+ clientMethod,
+ dataPath: [],
+ args,
+ extensions: client._extensions,
+ transaction: undefined,
+ unpacker,
+ otelParentCtx: undefined,
+ otelChildCtx: client._tracingHelper.getActiveContext(),
+ globalOmit: client._globalOmit,
+ customDataProxyFetch: undefined,
+ },
+ response
+ );
+};
+
+const aggregateKeys = new Set(['_avg', '_count', '_sum', '_min', '_max']);
+
+const normalizeCount = (args: any = {}) =>
+ typeof args._count === 'boolean'
+ ? { ...args, _count: { _all: args._count } }
+ : args;
+
+const mapAggregateArgs = (args: any = {}) =>
+ Object.entries(normalizeCount(args)).reduce(
+ (mapped, [key, value]) => {
+ if (aggregateKeys.has(key)) {
+ mapped.select[key] = { select: value };
+ } else {
+ mapped[key] = value;
+ }
+ return mapped;
+ },
+ { select: {} }
+ );
+
+const unpackAggregate =
+ (args: any = {}) =>
+ (data: any) => {
+ if (typeof args._count === 'boolean') {
+ data._count = data._count._all;
+ }
+ return data;
+ };
+
+const mapCountArgs = (args: any = {}) => {
+ const { select, ...rest } = args;
+ return mapAggregateArgs({
+ ...rest,
+ _count: typeof select === 'object' ? select : { _all: true },
+ });
+};
+
+const unpackCount =
+ (args: any = {}) =>
+ (data: any) => {
+ const count = unpackAggregate(args)(data)._count;
+ return typeof args.select === 'object' ? count : count._all;
+ };
+
+const mapGroupByArgs = (args: any = {}) => {
+ const mapped = mapAggregateArgs(args);
+ const by = Array.isArray(mapped.by) ? mapped.by : [mapped.by];
+ for (const field of by) {
+ if (typeof field === 'string') {
+ mapped.select[field] = true;
+ }
+ }
+ return mapped;
+};
+
+const unpackGroupBy =
+ (args: any = {}) =>
+ (data: any[]) => {
+ if (typeof args._count === 'boolean') {
+ data.forEach((row) => {
+ row._count = row._count._all;
+ });
+ }
+ return data;
+ };
+
+const modelNameOf = (client: any, model: unknown) => {
+ const context = Prisma.getExtensionContext(model as never) as {
+ $name?: string;
+ };
+ const name = context.$name;
+ const modelName = Object.keys(client._runtimeDataModel.models).find(
+ (candidate) => candidate.toLowerCase() === name?.toLowerCase()
+ );
+ if (!modelName) {
+ throw new Error(`Unknown Prisma model: ${name ?? 'undefined'}`);
+ }
+ return modelName;
+};
+
+export const queriesExtension = () =>
+ Prisma.defineExtension((client) =>
+ client.$extends({
+ name: 'prisma-react-native-queries',
+ client: {
+ $applyPendingMigrations: (): Promise =>
+ (client as any).$applyPendingMigrations(),
+ },
+ model: {
+ $allModels: {
+ findUnique(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'findUnique',
+ args
+ );
+ },
+ findUniqueOrThrow(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'findUniqueOrThrow',
+ args
+ );
+ },
+ findFirst(
+ this: T,
+ args?: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'findFirst',
+ args
+ );
+ },
+ findFirstOrThrow(
+ this: T,
+ args?: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'findFirstOrThrow',
+ args
+ );
+ },
+ findMany(
+ this: T,
+ args?: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'findMany',
+ args
+ );
+ },
+ create(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(client, modelNameOf(client, this), 'create', args);
+ },
+ createMany(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'createMany',
+ args
+ );
+ },
+ createManyAndReturn(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'createManyAndReturn',
+ args
+ );
+ },
+ update(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(client, modelNameOf(client, this), 'update', args);
+ },
+ updateMany(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'updateMany',
+ args
+ );
+ },
+ updateManyAndReturn(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'updateManyAndReturn',
+ args
+ );
+ },
+ upsert(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(client, modelNameOf(client, this), 'upsert', args);
+ },
+ delete(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(client, modelNameOf(client, this), 'delete', args);
+ },
+ deleteMany(
+ this: T,
+ args?: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'deleteMany',
+ args
+ );
+ },
+ count(
+ this: T,
+ args?: Prisma.Exact>
+ ): Prisma.Result {
+ const modelName = modelNameOf(client, this);
+ return request(
+ client,
+ modelName,
+ 'count',
+ args,
+ mapCountArgs(args),
+ unpackCount(args)
+ );
+ },
+ aggregate(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'aggregate',
+ args,
+ mapAggregateArgs(args),
+ unpackAggregate(args)
+ );
+ },
+ groupBy(
+ this: T,
+ args: Prisma.Exact>
+ ): Prisma.Result {
+ return request(
+ client,
+ modelNameOf(client, this),
+ 'groupBy',
+ args,
+ mapGroupByArgs(args),
+ unpackGroupBy(args)
+ );
+ },
+ },
+ },
+ })
+ );
diff --git a/src/ReactiveHooksExtension.ts b/src/ReactiveHooksExtension.ts
deleted file mode 100644
index e56bc9e1..00000000
--- a/src/ReactiveHooksExtension.ts
+++ /dev/null
@@ -1,305 +0,0 @@
-import { Prisma } from '@prisma/client/extension';
-import { useEffect, useState } from 'react';
-
-export const reactiveHooksExtension = () =>
- Prisma.defineExtension((client) => {
- const subscribedQueries: Record<
- string,
- {
- callbacks: Record void>;
- query: () => Promise;
- }
- > = {};
-
- const refreshSubscriptions = async () => {
- for (const key in subscribedQueries) {
- const subscription = subscribedQueries[key]!;
-
- const data = await subscription.query();
-
- for (const callbackKey in subscription.callbacks) {
- const callback = subscription.callbacks[callbackKey]!;
- callback(data);
- }
- }
- };
-
- return client.$extends({
- name: 'prisma-reactive-hooks-extension',
- client: {
- $refreshSubscriptions: async () => {
- await refreshSubscriptions();
- }
- },
- model: {
- $allModels: {
- useFindMany(
- this: T,
- args?: Prisma.Exact>
- ): Prisma.Result {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.findMany(args);
-
- const [engineResponse, setEngineResponse] = useState<
- Prisma.Result
- >([] as any);
-
- useEffect(() => {
- const key = `${model} :: findMany :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: findMany :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] =
- setEngineResponse;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: setEngineResponse,
- },
- query: () => model.findMany(args),
- };
- }
-
- prismaPromise.then(setEngineResponse);
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- }, []);
-
- return engineResponse;
- },
- useFindUnique(
- this: T,
- args?: Prisma.Exact>
- ): Prisma.Result {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.findUnique(args);
-
- const [engineResponse, setEngineResponse] = useState();
-
- useEffect(() => {
- const key = `${model} :: findUnique :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: findUnique :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] =
- setEngineResponse;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: setEngineResponse,
- },
- query: () => model.findUnique(args),
- };
- }
-
- prismaPromise.then(setEngineResponse);
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- }, []);
-
- return engineResponse;
- },
- useFindFirst(
- this: T,
- args?: Prisma.Exact>
- ): Prisma.Result {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.findFirst(args);
-
- const [engineResponse, setEngineResponse] = useState();
-
- useEffect(() => {
- const key = `${model} :: findFirst :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: findFirst :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] =
- setEngineResponse;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: setEngineResponse,
- },
- query: () => model.findFirst(args),
- };
- }
-
- prismaPromise.then(setEngineResponse);
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- }, []);
-
- return engineResponse;
- },
- useAggregate(
- this: T,
- args?: Prisma.Exact>
- ): Prisma.Result {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.aggregate(args);
-
- const [engineResponse, setEngineResponse] = useState();
-
- useEffect(() => {
- const key = `${model} :: aggregate :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: aggregate :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] =
- setEngineResponse;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: setEngineResponse,
- },
- query: () => model.aggregate(args),
- };
- }
-
- prismaPromise.then(setEngineResponse);
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- }, []);
-
- return engineResponse;
- },
- useGroupBy(
- this: T,
- args?: Prisma.Exact>
- ): Prisma.Result {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.groupBy(args);
-
- const [engineResponse, setEngineResponse] = useState();
-
- useEffect(() => {
- const key = `${model} :: groupBy :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: groupBy :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] =
- setEngineResponse;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: setEngineResponse,
- },
- query: () => model.groupBy(args),
- };
- }
-
- prismaPromise.then(setEngineResponse);
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- }, []);
-
- return engineResponse;
- },
- async create(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.create(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- async createMany(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.createMany(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- async delete(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.delete(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- async deleteMany(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.deleteMany(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- async update(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.update(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- async updateMany(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.updateMany(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- async upsert(
- this: T,
- args?: Prisma.Exact>
- ): Promise> {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
- const prismaPromise = model.upsert(args);
- const data = await prismaPromise;
- await refreshSubscriptions();
-
- return data;
- },
- },
- },
- });
- });
diff --git a/src/ReactiveQueriesExtension.ts b/src/ReactiveQueriesExtension.ts
deleted file mode 100644
index 68bf3e23..00000000
--- a/src/ReactiveQueriesExtension.ts
+++ /dev/null
@@ -1,262 +0,0 @@
-import { Prisma } from '@prisma/client/extension';
-
-export const reactiveQueriesExtension = () =>
- Prisma.defineExtension((client) => {
- const subscribedQueries: Record<
- string,
- {
- callbacks: Record void>;
- query: () => Promise;
- }
- > = {};
-
- const refreshSubscriptions = async () => {
- for (const key in subscribedQueries) {
- const subscription = subscribedQueries[key]!;
-
- const data = await subscription.query();
-
- for (const callbackKey in subscription.callbacks) {
- const callback = subscription.callbacks[callbackKey]!;
- callback(data);
- }
- }
- };
-
- return client.$extends({
- name: 'prisma-reactive-queries-extension',
- client: {
- $refreshSubscriptions: async () => {
- await refreshSubscriptions();
- }
- },
- model: {
- $allModels: {
- findMany(
- this: T,
- cb: (data: Prisma.Result) => void,
- args?: Prisma.Exact>
- ): () => void {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
-
- const key = `${model} :: findMany :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: findMany :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
-
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] = cb;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: cb,
- },
- query: () => model.findMany(args),
- };
- }
-
- refreshSubscriptions();
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- },
- aggregate(
- this: T,
- cb: (data: Prisma.Result) => void,
- args?: Prisma.Exact>
- ): () => void {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
-
- const key = `${model} :: aggregate :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: aggregate :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
-
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] = cb;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: cb,
- },
- query: () => model.aggregate(args),
- };
- }
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- },
- groupBy(
- this: T,
- cb: (data: Prisma.Result) => void,
- args?: Prisma.Exact>
- ): () => void {
- const ctx = Prisma.getExtensionContext(this);
- const model = (ctx.$parent as any)[ctx.$name!];
-
- const key = `${model} :: groupBy :: ${JSON.stringify(args)}`;
- const callbackKey = `${model} :: groupBy :: ${JSON.stringify(
- args
- )} :: ${Math.random()}`;
-
- if (subscribedQueries[key] != null) {
- subscribedQueries[key]!.callbacks[callbackKey] = cb;
- } else {
- subscribedQueries[key] = {
- callbacks: {
- [callbackKey]: cb,
- },
- query: () => model.groupBy(args),
- };
- }
-
- return () => {
- delete subscribedQueries[key]!.callbacks[callbackKey];
- };
- },
- findUnique(
- this: T,
- cb: (data: Prisma.Result) => void,
- args?: Prisma.Exact