Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added sample app with new architecture #424

Merged
merged 31 commits into from
Jan 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
cf383c6
Merge pull request #416 from adobe/main
namArora3112 Jan 7, 2025
310b4f1
Aep sample app with new arch enabled (#388)
namArora3112 Nov 4, 2024
c357026
navigation structure fixes (#395)
namArora3112 Nov 8, 2024
762d01a
optimise integration (#393)
namArora3112 Nov 11, 2024
e173e5d
Lifecycle implementation (#396)
namArora3112 Nov 16, 2024
235697a
identity integration with fixes (#397)
namArora3112 Nov 19, 2024
63653c5
Target view integration build fixes (#399)
namArora3112 Nov 26, 2024
980f4a8
Update README.md
namArora3112 Dec 2, 2024
fc03b0d
Update README.md
namArora3112 Dec 2, 2024
a9ca8b3
CI CD fixes (#403)
namArora3112 Dec 9, 2024
c1b87b0
Messaging view (#405)
namArora3112 Dec 16, 2024
ec18c73
Places fixes (#404)
namArora3112 Dec 19, 2024
e114409
Update README.md
namArora3112 Dec 19, 2024
b799b2a
Update README.md
namArora3112 Dec 19, 2024
4bc5e33
Update README.md
namArora3112 Dec 19, 2024
845ceb8
Read me updated for AEPSampleNewArcEnabled (#394)
namArora3112 Jan 7, 2025
dfcbe23
removed main readme
namArora3112 Jan 8, 2025
673e4be
Merge pull request #419 from adobe/new_arc
namArora3112 Jan 8, 2025
0b4b483
native places module fixes
namArora3112 Jan 9, 2025
251102d
Added places target navigation on main home page
namArora3112 Jan 9, 2025
e8e1940
Merge pull request #420 from namArora3112/android/places-fixes-staging
cacheung Jan 9, 2025
ab5b2b7
Merge pull request #421 from namArora3112/entry-points/places-target
namArora3112 Jan 10, 2025
f666265
added new arch read me
namArora3112 Jan 9, 2025
4eca9ec
bump version from 6.0.2 to 6.0.3 (#423)
namArora3112 Jan 10, 2025
7d69327
Align extension view names with older arc sample app for consistency
namArora3112 Jan 13, 2025
76b9b6c
Update README.md
namArora3112 Jan 13, 2025
5e1e61c
Merge pull request #422 from namArora3112/update-read-me
cacheung Jan 13, 2025
11465c4
Update AEPSampleApp Readme
cacheung Jan 14, 2025
9514709
update readme with yarn install
cacheung Jan 14, 2025
976d4a4
Merge pull request #425 from namArora3112/extension-views
namArora3112 Jan 14, 2025
f0ce20e
Merge pull request #426 from cacheung/AEPSampleAppReadme
cacheung Jan 14, 2025
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
50 changes: 38 additions & 12 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ orbs:
jobs:
unit-test:
docker:
# switch to use node v18.x becaseu of the error: the engine "node" is incompatible with this module. Expected version "^16.10.0 || ^18.0.0 || >=20.0.0". Got "19.7.0"
# Use Node.js 18.x for compatibility with the project dependencies
- image: cimg/node:18.20

steps:
Expand All @@ -18,13 +18,19 @@ jobs:
keys:
- yarn-cache-{{ checksum "yarn.lock" }}

- run: yarn install
- run:
name: Install Node.js and Yarn Dependencies
command: yarn install

- run:
name: Build the Project
command: yarn run build

- save_cache:
key: yarn-cache-{{ checksum "yarn.lock" }}
paths:
- ./node_modules
- ./apps/AEPSampleApp/node_modules
- ./apps/AEPSampleAppNewArchEnabled/node_modules

- run:
name: Unit Tests
Expand All @@ -33,20 +39,23 @@ jobs:
build-sample-app-android:
executor:
name: rn/linux_android
# the installed tools within the image: https://hub.docker.com/r/reactnativecommunity/react-native-android/tags
build_image_version: v13.0
resource_class: large

steps:
- checkout

- run:
name: yarn install
name: Install Node.js and Yarn Dependencies
command: yarn install

- run:
name: Build the Project
command: yarn run build

- run:
name: Building Android Sample App
command: yarn sampleapp:android:build
command: yarn sampleappnewarchenabled:android:build

environment:
_JAVA_OPTIONS: "-Xmx4096M -XX:MaxMetaspaceSize=512m"
Expand All @@ -62,25 +71,42 @@ jobs:
keys:
- ios-yarn-cache-{{ checksum "yarn.lock" }}

- run: yarn install
- run:
name: Set Xcode Path
command: sudo xcode-select -s /Applications/Xcode.app

- run:
name: Install Node.js and Yarn Dependencies
command: yarn install

- run:
name: Build the Project
command: yarn run build

- save_cache:
key: ios-yarn-cache-{{ checksum "yarn.lock" }}
paths:
- ./node_modules
- ./apps/AEPSampleApp/node_modules
- ./apps/AEPSampleAppNewArchEnabled/node_modules

- run:
name: Install latest Cocoapods
name: Install Cocoapods
command: sudo gem install cocoapods

- run:
name: Install pods
command: yarn sampleapp:ios:pod:install
name: Install Pods
command: yarn sampleappnewarchenabled:ios:pod:install

- run:
name: Building iOS Sample App
command: cd apps/AEPSampleApp && npx react-native run-ios --verbose --terminal terminal
command: |
cd apps/AEPSampleAppNewArchEnabled/ios
xcodebuild \
-workspace AEPSampleAppNewArchEnabled.xcworkspace \
-scheme AEPSampleAppNewArchEnabled \
-sdk iphonesimulator \
-destination "generic/platform=iOS Simulator" \
clean build

workflows:
version: 2.1
Expand Down
39 changes: 37 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and *not* Next.js
# Comment in the public line below if your project uses Gatsby and *not* Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

Expand All @@ -103,12 +103,47 @@ dist
# TernJS port file
.tern-port

# Build output
build/

## User settings
xcuserdata/
packages/.DS_Store

dist/
test/.DS_Store

.yarn/
.yarn/

# Ignore all .properties, .lock, .bin, and other build output files inside the .gradle directory
**/android/gradle/**/*.lock
**/android/gradle/**/*.bin

# Ignore Gradle build directories and cache files
.gradle/
**/build/
**/.gradle/

# Ignore all Eclipse settings and metadata files
**/.settings/

# IntelliJ IDEA project files
.idea/

# File-based project format
*.iws

# IntelliJ
out/

# Exclude all Android Studio/IntelliJ generated files
**/android/.idea/
**/android/.gradle/
**/android/build/

# Ignore all .idea directories across the project
**/.idea/

# Ignore VSCode settings
.vscode/
.vscode/settings.json
33 changes: 19 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,29 @@
## About this project

This repository is a monorepo and contains a collection of React Native modules for Adobe Experience Platform Mobile SDK as listed below. These modules can be found in the [packages](./packages) directory.
| Package Name | Latest Version | Native Extension |
| ---- | ---- | ---- |
| [@adobe/react-native-aepcore (required)](./packages/core) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepcore.svg)](https://www.npmjs.com/package/@adobe/react-native-aepcore) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepcore)](https://www.npmjs.com/package/@adobe/react-native-aepcore) | [Mobile Core](https://developer.adobe.com/client-sdks/documentation/mobile-core)
| [@adobe/react-native-aepuserprofile](./packages/userprofile) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepuserprofile.svg)](https://www.npmjs.com/package/@adobe/react-native-aepuserprofile) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepuserprofile)](https://www.npmjs.com/package/@adobe/react-native-aepuserprofile)| [Profile](https://developer.adobe.com/client-sdks/documentation/profile)
| [@adobe/react-native-aepedge](./packages/edge) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedge.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedge) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedge)](https://www.npmjs.com/package/@adobe/react-native-aepedge) | [Edge](https://developer.adobe.com/client-sdks/documentation/edge-network)
| [@adobe/react-native-aepedgeidentity](./packages/edgeidentity) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedgeidentity.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedgeidentity) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedgeidentity)](https://www.npmjs.com/package/@adobe/react-native-aepedgeidentity) |[EdgeIdentity](https://developer.adobe.com/client-sdks/documentation/identity-for-edge-network)
| [@adobe/react-native-aepedgeconsent](./packages/edgeconsent) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedgeconsent.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedgeconsent) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedgeconsent)](https://www.npmjs.com/package/@adobe/react-native-aepedgeconsent) | [EdgeConsent](https://developer.adobe.com/client-sdks/documentation/consent-for-edge-network)
| [@adobe/react-native-aepedgebridge](./packages/edgebridge) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedgebridge.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedgebridge) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedgebridge)](https://www.npmjs.com/package/@adobe/react-native-aepedgebridge) | EdgeBridge
| [@adobe/react-native-aepmessaging](./packages/messaging) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepmessaging.svg)](https://www.npmjs.com/package/@adobe/react-native-aepmessaging) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepmessaging)](https://www.npmjs.com/package/@adobe/react-native-aepmessaging) | [Messaging](https://developer.adobe.com/client-sdks/documentation/iam/)
| [@adobe/react-native-aepassurance](./packages/assurance) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepassurance.svg)](https://www.npmjs.com/package/@adobe/react-native-aepassurance) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepassurance)](https://www.npmjs.com/package/@adobe/react-native-aepassurance) | [Assurance](https://developer.adobe.com/client-sdks/documentation/platform-assurance-sdk)
| [@adobe/react-native-aepoptimize](./packages/optimize) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepoptimize.svg)](https://www.npmjs.com/package/@adobe/react-native-aepoptimize) ![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepoptimize) | [Optimize](https://developer.adobe.com/client-sdks/documentation/adobe-journey-optimizer-decisioning)
| [@adobe/react-native-aepplaces](./packages/places) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepplaces.svg)](https://www.npmjs.com/package/@adobe/react-native-aepplaces) ![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepplaces) | [Places](https://developer.adobe.com/client-sdks/documentation/places)
| [@adobe/react-native-aeptarget](./packages/target) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aeptarget.svg)](https://www.npmjs.com/package/@adobe/react-native-aeptarget) ![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aeptarget) | [Target](https://developer.adobe.com/client-sdks/documentation/adobe-target)
| [@adobe/react-native-aepcampaignclassic](./packages/campaignclassic) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepcampaignclassic.svg)](https://www.npmjs.com/package/@adobe/react-native-aepcampaignclassic) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepcampaignclassic)](https://www.npmjs.com/package/@adobe/react-native-aepcampaignclassic) |[CampaignClassic](https://developer.adobe.com/client-sdks/documentation/adobe-campaign-classic)
| Package Name | Latest Version | Native Extension | New Architecture Compatibility |
| ---- | ---- | ---- | ---- |
| [@adobe/react-native-aepcore (required)](./packages/core) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepcore.svg)](https://www.npmjs.com/package/@adobe/react-native-aepcore) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepcore)](https://www.npmjs.com/package/@adobe/react-native-aepcore) | [Mobile Core](https://developer.adobe.com/client-sdks/documentation/mobile-core) | Supported |
| [@adobe/react-native-aepuserprofile](./packages/userprofile) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepuserprofile.svg)](https://www.npmjs.com/package/@adobe/react-native-aepuserprofile) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepuserprofile)](https://www.npmjs.com/package/@adobe/react-native-aepuserprofile)| [Profile](https://developer.adobe.com/client-sdks/documentation/profile) | Supported |
| [@adobe/react-native-aepedge](./packages/edge) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedge.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedge) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedge)](https://www.npmjs.com/package/@adobe/react-native-aepedge) | [Edge](https://developer.adobe.com/client-sdks/documentation/edge-network) | Supported |
| [@adobe/react-native-aepedgeidentity](./packages/edgeidentity) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedgeidentity.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedgeidentity) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedgeidentity)](https://www.npmjs.com/package/@adobe/react-native-aepedgeidentity) |[EdgeIdentity](https://developer.adobe.com/client-sdks/documentation/identity-for-edge-network) | Supported |
| [@adobe/react-native-aepedgeconsent](./packages/edgeconsent) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedgeconsent.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedgeconsent) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedgeconsent)](https://www.npmjs.com/package/@adobe/react-native-aepedgeconsent) | [EdgeConsent](https://developer.adobe.com/client-sdks/documentation/consent-for-edge-network) | Supported |
| [@adobe/react-native-aepedgebridge](./packages/edgebridge) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepedgebridge.svg)](https://www.npmjs.com/package/@adobe/react-native-aepedgebridge) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepedgebridge)](https://www.npmjs.com/package/@adobe/react-native-aepedgebridge) | EdgeBridge | Supported |
| [@adobe/react-native-aepmessaging](./packages/messaging) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepmessaging.svg)](https://www.npmjs.com/package/@adobe/react-native-aepmessaging) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepmessaging)](https://www.npmjs.com/package/@adobe/react-native-aepmessaging) | [Messaging](https://developer.adobe.com/client-sdks/documentation/iam/) | Supported |
| [@adobe/react-native-aepassurance](./packages/assurance) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepassurance.svg)](https://www.npmjs.com/package/@adobe/react-native-aepassurance) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepassurance)](https://www.npmjs.com/package/@adobe/react-native-aepassurance) | [Assurance](https://developer.adobe.com/client-sdks/documentation/platform-assurance-sdk) | Supported |
| [@adobe/react-native-aepoptimize](./packages/optimize) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepoptimize.svg)](https://www.npmjs.com/package/@adobe/react-native-aepoptimize) ![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepoptimize) | [Optimize](https://developer.adobe.com/client-sdks/documentation/adobe-journey-optimizer-decisioning) | Supported |
| [@adobe/react-native-aepplaces](./packages/places) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepplaces.svg)](https://www.npmjs.com/package/@adobe/react-native-aepplaces) ![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepplaces) | [Places](https://developer.adobe.com/client-sdks/documentation/places) | Supported |
| [@adobe/react-native-aeptarget](./packages/target) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aeptarget.svg)](https://www.npmjs.com/package/@adobe/react-native-aeptarget) ![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aeptarget) | [Target](https://developer.adobe.com/client-sdks/documentation/adobe-target) | Supported |
| [@adobe/react-native-aepcampaignclassic](./packages/campaignclassic) | [![npm version](https://badge.fury.io/js/%40adobe%2Freact-native-aepcampaignclassic.svg)](https://www.npmjs.com/package/@adobe/react-native-aepcampaignclassic) [![npm downloads](https://img.shields.io/npm/dm/@adobe/react-native-aepcampaignclassic)](https://www.npmjs.com/package/@adobe/react-native-aepcampaignclassic) |[CampaignClassic](https://developer.adobe.com/client-sdks/documentation/adobe-campaign-classic) | Not Supported |

> [!NOTE]
> Since version 5.0.0 of the Adobe React Native SDK, all React Native libraries that share the same major version are compatible with each other.

> [!NOTE]
> The React Native libraries within this repository are specifically designed to support the Android and iOS platforms only.

> [!IMPORTANT]
> The Adobe React Native SDK utilizes the React Native interop layer to ensure compatibility with new architecture.

## Requirements

Expand Down Expand Up @@ -311,6 +313,9 @@ Underlying Objective-C module 'AEPRulesEngine' not found
```
Refer to the solution [here](https://github.com/adobe/aepsdk-react-native/issues/263#issuecomment-1498393770).

## Sample Apps
Refer to the [sample apps](https://github.com/adobe/aepsdk-react-native/tree/main/apps) for example implementations.

## Contributing

Contributions are welcomed! See [CONTRIBUTING](CONTRIBUTING.md) and [development.md](./docs/development.md) guides for more information.
Expand Down
20 changes: 19 additions & 1 deletion apps/AEPSampleApp/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,18 @@
# AEPSampleApp

## Table of Contents
- [Introduction](#introduction)
- [Prerequisites](#prerequisites)
- [Get Started](#how-to-run-the-sample-app)
- [Validate with Assurance](#validate-with-assurance)
- [Resources and Troubleshooting](#resources-and-troubleshooting)

## Introduction
This project is a React Native app set up using `react-native-cli`. It serves as a demonstrates of the integration Adobe SDKs with a React Native application.

## Prerequisites

* If you are new to React Native we suggest you follow the [React Native Setting up development environment](https://reactnative.dev/docs/environment-setup) React Native CLI Quickstart page before continuing.
* If you are new to React Native we suggest you follow the older version [React Native Setting up development environment](https://reactnative.dev/docs/0.74/getting-started-without-a-framework) React Native CLI before continuing.
* Cocoapods version >= 1.11.3
* Node version >= 18

Expand All @@ -17,6 +27,14 @@ In `apps/AEPSampleApp/android/app/src/main/java/com/aepsampleapp/MainApplication
> Note: App id is configured in a mobile property in Data Collection UI, in Tags. Refer to [configure with App ID per environment](https://developer.adobe.com/client-sdks/home/base/mobile-core/configuration/#configure-with-app-id-per-environment) page for more information.

### Install dependencies
Go to the **AEPSampleApp** folder and run

```
yarn install
```

Go to the **root directory** and run scripts

> Note: Commands are assuming you're in the root directory of the repository.

```
Expand Down
Loading