Skip to content

Commit

Permalink
Merge pull request #8 from drone/FFM-1424
Browse files Browse the repository at this point in the history
Ffm 1424
  • Loading branch information
milos85vasic-harness authored Oct 28, 2021
2 parents 4452952 + 3ab2822 commit 5bda987
Show file tree
Hide file tree
Showing 13 changed files with 454 additions and 278 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -319,4 +319,4 @@ Temporary Items
.idea
package-lock.json

.DS_Store
yarn.lock
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@ To sign up, https://app.harness.io/auth/#/signup/
## _Setup_

To install SDK, declare a dependency to project's `package.json` file:
```JSON
"ff-react-native-client-sdk": "1.0.0",
```
"ff-react-native-client-sdk": "1.0.0"
```

Or using npm install:
```shell
$ npm install --save ff-react-native-client-sdk
Expand Down Expand Up @@ -76,7 +77,7 @@ The Public API exposes a few methods that you can utilize:

* `jsonVariation(evalutionId: string, defaultValue: any)`

* `registerEventsListener(listener: (type: string, flags: any) => void) `
* `registerListener(listener: (type: string, flags: any) => void) `

* `unregisterListener(listener: (type: string, flags: any) => void)`

Expand Down Expand Up @@ -116,7 +117,7 @@ let jsonEvaluation = await client.jsonVariation("demo_json_evaluation", {});
This method provides a way to register a listener for different events that might be triggered by SDK, indicating specific change in SDK itself.

```JavaScript
client.registerEventsListener((type, flags) => {
client.registerListener((type, flags) => {

});
```
Expand Down
3 changes: 1 addition & 2 deletions android/.idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions android/.idea/jarRepositories.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions android/.idea/modules.xml

This file was deleted.

70 changes: 49 additions & 21 deletions android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,23 +1,55 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {

ext {

buildToolsVersion = "29.0.2"
minSdkVersion = 19
compileSdkVersion = 29
targetSdkVersion = 29
}

repositories {

google()
jcenter()
mavenCentral()
maven { url 'https://www.jitpack.io' }
}

dependencies {
classpath("com.android.tools.build:gradle:3.5.3")

classpath("com.android.tools.build:gradle:3.5.4")
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}

allprojects {

repositories {

mavenLocal()

maven {

// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url("$rootDir/../node_modules/react-native/android")
}

maven {

// Android JSC is installed from npm
url("$rootDir/../node_modules/jsc-android/dist")
}

mavenCentral()
google()
maven { url 'https://www.jitpack.io' }
jcenter()
}
}

apply plugin: 'com.android.library'

android {
Expand All @@ -38,31 +70,27 @@ android {
versionCode 1
versionName "1.0"
}

buildTypes {

debug {

debuggable true
}

release {

debuggable true
}
}
}

dependencies {

implementation fileTree(dir: "libs", include: ["*.jar"])
// noinspection GradleDynamicVersion

implementation "com.facebook.react:react-native:+" // From node_modules
implementation 'io.harness:ff-android-client-sdk:1.0.3'
api "com.facebook.react:react-native:0.63.2" // From node_modules
api "io.harness:ff-android-client-sdk:1.0.3"
}

allprojects {
repositories {
mavenLocal()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url("$rootDir/../node_modules/react-native/android")
}
maven {
// Android JSC is installed from npm
url("$rootDir/../node_modules/jsc-android/dist")
}

google()
jcenter()
maven { url 'https://www.jitpack.io' }
}
}
Loading

0 comments on commit 5bda987

Please sign in to comment.