Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
61271cb
chore: bootstrapped demo Expo app
artus9033 Jan 15, 2026
0282537
chore: use expo config plugin in expo demo app
artus9033 Jan 15, 2026
a9dbb08
chore: reset Expo project
artus9033 Jan 16, 2026
9c92eaa
chore: use workspace specifier for monorepo deps
artus9033 Jan 16, 2026
4a5702a
fix: do not toss up source sets in Gradle plugin
artus9033 Jan 16, 2026
4893be4
feat: base implementation for brownfield Expo config plugin
artus9033 Jan 22, 2026
a65a9f1
chore: update lock files
artus9033 Jan 22, 2026
6aba560
chore: update app.json in ExpoApp
artus9033 Jan 22, 2026
f30f055
chore: enable debug logging in app.json in ExpoApp
artus9033 Jan 22, 2026
594aaf5
feat: use new logging system in the plugin
artus9033 Jan 22, 2026
9e0ba69
feat: templates engine for project modifications
artus9033 Jan 22, 2026
a5840e9
feat: patch for Expo SDK pre v55, fix source file paths
artus9033 Jan 23, 2026
b544e47
feat: implemented Android brownfield plugin
artus9033 Jan 23, 2026
af69bca
chore: update ExpoApp scripts
artus9033 Jan 23, 2026
2afa209
fix: dedent gradle script insertion
artus9033 Jan 23, 2026
64eb48d
fix: depend on Material in AndroidApp; fix typo in gradle scripting c…
artus9033 Jan 23, 2026
23e4c8e
fix: package name in ExpoApp
artus9033 Jan 23, 2026
95b580c
chore: use debug signing config for AndroidApp release variant - for …
artus9033 Jan 23, 2026
a066b02
chore: missing indent in gradleHelpers insertion
artus9033 Jan 23, 2026
0f34957
fix: add missing expo modifications to template build.gradle.kts
artus9033 Jan 23, 2026
0a9c3ca
chore: use the Expo classes in template ReactNativeHostManager.kt
artus9033 Jan 23, 2026
080a124
fix: iOS xcode project processing of target UUID
artus9033 Jan 23, 2026
834d850
fix: make Android Expo config explicitly specify versions of RN Andro…
artus9033 Jan 23, 2026
a4c0913
fix: running package:ios again
thymikee Jan 23, 2026
ccf8f48
chore: udpate rock to 0.12.8
thymikee Jan 23, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions apps/AndroidApp/app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ android {
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
signingConfig = signingConfigs.getByName("debug")
}
}
compileOptions {
Expand All @@ -53,6 +54,7 @@ dependencies {
implementation(libs.androidx.core.ktx)
implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.activity.compose)
implementation(libs.material)
implementation(platform(libs.androidx.compose.bom))
implementation(libs.androidx.compose.ui)
implementation(libs.androidx.compose.ui.graphics)
Expand Down
4 changes: 3 additions & 1 deletion apps/AndroidApp/gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@ activityCompose = "1.8.0"
composeBom = "2024.09.00"
appcompat = "1.7.1"
fragmentCompose = "1.8.9"
material = "1.13.0"

[libraries]
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "coreKtx" }
brownfieldlib = { module = "com.rnapp:brownfieldlib", version.ref = "brownfieldlib" }
brownfieldlib = { module = "com.callstack.rnbrownfield.demo.expoapp:brownfield-expo-app", version.ref = "brownfieldlib" }
junit = { group = "junit", name = "junit", version.ref = "junit" }
androidx-junit = { group = "androidx.test.ext", name = "junit", version.ref = "junitVersion" }
androidx-espresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "espressoCore" }
Expand All @@ -30,6 +31,7 @@ androidx-compose-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-te
androidx-compose-material3 = { group = "androidx.compose.material3", name = "material3" }
androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }
androidx-fragment-compose = { group = "androidx.fragment", name = "fragment-compose", version.ref = "fragmentCompose" }
material = { module = "com.google.android.material:material", version.ref = "material" }

[plugins]
android-application = { id = "com.android.application", version.ref = "agp" }
Expand Down
43 changes: 43 additions & 0 deletions apps/ExpoApp/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Learn more https://docs.github.com/en/get-started/getting-started-with-git/ignoring-files

# dependencies
node_modules/

# Expo
.expo/
dist/
web-build/
expo-env.d.ts

# Native
.kotlin/
*.orig.*
*.jks
*.p8
*.p12
*.key
*.mobileprovision

# Metro
.metro-health-check*

# debug
npm-debug.*
yarn-debug.*
yarn-error.*

# macOS
.DS_Store
*.pem

# local env files
.env*.local

# typescript
*.tsbuildinfo

app-example

# generated native folders
/ios
/android
50 changes: 50 additions & 0 deletions apps/ExpoApp/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Welcome to your Expo app 👋

This is an [Expo](https://expo.dev) project created with [`create-expo-app`](https://www.npmjs.com/package/create-expo-app).

## Get started

1. Install dependencies

```bash
npm install
```

2. Start the app

```bash
npx expo start
```

In the output, you'll find options to open the app in a

- [development build](https://docs.expo.dev/develop/development-builds/introduction/)
- [Android emulator](https://docs.expo.dev/workflow/android-studio-emulator/)
- [iOS simulator](https://docs.expo.dev/workflow/ios-simulator/)
- [Expo Go](https://expo.dev/go), a limited sandbox for trying out app development with Expo

You can start developing by editing the files inside the **app** directory. This project uses [file-based routing](https://docs.expo.dev/router/introduction).

## Get a fresh project

When you're ready, run:

```bash
npm run reset-project
```

This command will move the starter code to the **app-example** directory and create a blank **app** directory where you can start developing.

## Learn more

To learn more about developing your project with Expo, look at the following resources:

- [Expo documentation](https://docs.expo.dev/): Learn fundamentals, or go into advanced topics with our [guides](https://docs.expo.dev/guides).
- [Learn Expo tutorial](https://docs.expo.dev/tutorial/introduction/): Follow a step-by-step tutorial where you'll create a project that runs on Android, iOS, and the web.

## Join the community

Join our community of developers creating universal apps.

- [Expo on GitHub](https://github.com/expo/expo): View our open source platform and contribute.
- [Discord community](https://chat.expo.dev): Chat with Expo users and ask questions.
62 changes: 62 additions & 0 deletions apps/ExpoApp/app.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{
"expo": {
"name": "ExpoApp",
"slug": "ExpoApp",
"version": "1.0.0",
"orientation": "portrait",
"icon": "./assets/images/icon.png",
"scheme": "expoapp",
"userInterfaceStyle": "automatic",
"newArchEnabled": true,
"ios": {
"supportsTablet": true,
"bundleIdentifier": "com.callstack.rnbrownfield.demo.expoapp"
},
"android": {
"adaptiveIcon": {
"backgroundColor": "#E6F4FE",
"foregroundImage": "./assets/images/android-icon-foreground.png",
"backgroundImage": "./assets/images/android-icon-background.png",
"monochromeImage": "./assets/images/android-icon-monochrome.png"
},
"edgeToEdgeEnabled": true,
"predictiveBackGestureEnabled": false,
"package": "com.callstack.rnbrownfield.demo.expoapp"
},
"web": {
"output": "static",
"favicon": "./assets/images/favicon.png"
},
"plugins": [
"expo-router",
[
"expo-splash-screen",
{
"image": "./assets/images/splash-icon.png",
"imageWidth": 200,
"resizeMode": "contain",
"backgroundColor": "#ffffff",
"dark": {
"backgroundColor": "#000000"
}
}
],
[
"@callstack/react-native-brownfield",
{
"ios": {
"frameworkName": "BrownfieldExpoApp"
},
"android": {
"moduleName": "brownfield-expo-app"
},
"debug": true
}
]
],
"experiments": {
"typedRoutes": true,
"reactCompiler": true
}
}
}
15 changes: 15 additions & 0 deletions apps/ExpoApp/app/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import { Text, View } from 'react-native';

export default function Index() {
return (
<View
style={{
flex: 1,
justifyContent: 'center',
alignItems: 'center',
}}
>
<Text>Edit app/index.tsx to edit this screen.</Text>
</View>
);
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/partial-react-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/react-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/react-logo@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/react-logo@3x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/ExpoApp/assets/images/splash-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions apps/ExpoApp/eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import eslintRnConfig from '../../eslint.config.rn.mjs';

/** @type {import('eslint').Linter.Config[]} */
export default [
...eslintRnConfig,
{
rules: {
'react/no-unstable-nested-components': 'off',
'react-native/no-inline-styles': 'off',
'no-alert': 'off',
},
},
];
47 changes: 47 additions & 0 deletions apps/ExpoApp/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
"name": "expoapp",
"main": "expo-router/entry",
"version": "1.0.0",
"scripts": {
"start": "expo start",
"reset-project": "node ./scripts/reset-project.js",
"android": "expo run:android",
"ios": "expo run:ios",
"web": "expo start --web",
"lint": "expo lint",
"prebuild": "expo prebuild",
"brownfield:ios": "expo prebuild --platform ios --no-install && brownfield package:ios --scheme BrownfieldExpoApp --configuration Release --verbose",
"brownfield:android": "expo prebuild --platform android && brownfield package:android --module-name brownfield-expo-app --variant release --verbose && brownfield publish:android --module-name brownfield-expo-app --verbose"
},
"dependencies": {
"@callstack/react-native-brownfield": "workspace:^",
"@expo/vector-icons": "^15.0.3",
"@react-navigation/bottom-tabs": "^7.4.0",
"@react-navigation/elements": "^2.6.3",
"@react-navigation/native": "^7.1.8",
"expo": "~54.0.31",
"expo-constants": "~18.0.13",
"expo-font": "~14.0.10",
"expo-haptics": "~15.0.8",
"expo-image": "~3.0.11",
"expo-linking": "~8.0.11",
"expo-router": "~6.0.21",
"expo-splash-screen": "~31.0.13",
"expo-status-bar": "~3.0.9",
"expo-symbols": "~1.0.8",
"expo-system-ui": "~6.0.9",
"expo-web-browser": "~15.0.10",
"react": "19.1.0",
"react-dom": "19.1.0",
"react-native": "0.81.5",
"react-native-safe-area-context": "~5.6.0",
"react-native-screens": "~4.16.0"
},
"devDependencies": {
"@types/react": "~19.1.0",
"eslint": "^9.25.0",
"eslint-config-expo": "~10.0.0",
"typescript": "~5.9.2"
},
"private": true
}
10 changes: 10 additions & 0 deletions apps/ExpoApp/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"extends": "expo/tsconfig.base.json",
"compilerOptions": {
"strict": true,
"paths": {
"@/*": ["./*"]
}
},
"include": ["**/*.ts", "**/*.tsx", ".expo/types/**/*.ts", "expo-env.d.ts"]
}
4 changes: 2 additions & 2 deletions apps/RNApp/android/BrownfieldLib/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ publishing {
pom {
withXml {
/**
* As a result of `from(components.getByName("default")` all of the project
* As a result of `from(components.getByName("default"))` all of the project
* dependencies are added to `pom.xml` file. We do not need the react-native
* third party dependencies to be a part of it as we embed those dependencies.
*/
Expand All @@ -45,7 +45,7 @@ publishing {
val moduleBuildDir: Directory = layout.buildDirectory.get()

/**
* As a result of `from(components.getByName("default")` all of the project
* As a result of `from(components.getByName("default"))` all of the project
* dependencies are added to `module.json` file. We do not need the react-native
* third party dependencies to be a part of it as we embed those dependencies.
*/
Expand Down
4 changes: 2 additions & 2 deletions apps/RNApp/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2848,8 +2848,8 @@ SPEC CHECKSUMS:
ReactCommon: 801eff8cb9c940c04d3a89ce399c343ee3eff654
RNScreens: d6413aeb1878cdafd3c721e2c5218faf5d5d3b13
SocketRocket: d4aabe649be1e368d1318fdf28a022d714d65748
Yoga: 526f25666395d30c297d53154398ffd249eaf9e1
Yoga: 46ff53afcbeda2bae19c85b65e17487c3e3984dd

PODFILE CHECKSUM: 7c116a16dd0744063c8c6293dbfc638c9d447c19

COCOAPODS: 1.15.2
COCOAPODS: 1.16.2
4 changes: 2 additions & 2 deletions apps/RNApp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
"codegen": "brownfield codegen"
},
"dependencies": {
"@callstack/brownie": "*",
"@callstack/react-native-brownfield": "*",
"@callstack/brownie": "workspace:^",
"@callstack/react-native-brownfield": "workspace:^",
"@react-native/new-app-screen": "0.82.1",
"@react-navigation/native": "^7.0.15",
"@react-navigation/native-stack": "^7.2.1",
Expand Down
4 changes: 2 additions & 2 deletions apps/TesterIntegrated/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
"lint": "eslint ."
},
"dependencies": {
"@callstack/brownie": "*",
"@callstack/react-native-brownfield": "*",
"@callstack/brownie": "workspace:^",
"@callstack/react-native-brownfield": "workspace:^",
"@react-navigation/native": "^7.0.15",
"@react-navigation/native-stack": "^7.2.1",
"react": "19.1.1",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ object RNSourceSets {
val capitalizedVariantName = variant.name.replaceFirstChar(Char::titlecase)

androidExtension.sourceSets.getByName("main") { sourceSet ->
sourceSet.java.srcDirs("$moduleBuildDir/generated/autolinking/src/main/java")
}

androidExtension.sourceSets.getByName(variant.name) { sourceSet ->
for (bundlePathSegment in listOf(
// outputs for RN <= 0.81
"createBundle${capitalizedVariantName}JsAndAssets",
Expand All @@ -57,8 +61,6 @@ object RNSourceSets {
sourceSet.assets.srcDirs("$appBuildDir/generated/assets/$bundlePathSegment")
sourceSet.res.srcDirs("$appBuildDir/generated/res/$bundlePathSegment")
}

sourceSet.java.srcDirs("$moduleBuildDir/generated/autolinking/src/main/java")
}
}

Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,15 @@
"dependencies": {
"@changesets/changelog-github": "^0.5.2",
"@changesets/cli": "^2.29.8",
"@expo/config-plugins": "^54.0.4",
"quicktype-core": "^23.2.6",
"quicktype-typescript-input": "^23.2.6"
},
"devDependencies": {
"@commitlint/cli": "^20.3.1",
"@commitlint/config-conventional": "^20.3.1",
"@eslint/compat": "^2.0.1",
"@expo/config-types": "^54.0.10",
"@react-native/eslint-config": "0.82.1",
"babel-plugin-module-resolver": "5.0.2",
"eslint": "^9.28.0",
Expand Down
Loading