├── .gitattributes
├── android
├── .settings
│ └── org.eclipse.buildship.core.prefs
├── gradle
│ └── wrapper
│ │ ├── gradle-wrapper.jar
│ │ └── gradle-wrapper.properties
├── src
│ └── main
│ │ ├── AndroidManifest.xml
│ │ └── java
│ │ └── com
│ │ └── fidme
│ │ └── faststorage
│ │ ├── RNFastStoragePackage.java
│ │ └── RNFastStorageModule.java
├── .classpath
├── .project
├── build.gradle
├── gradlew.bat
└── gradlew
├── ios
├── MMKV.framework
│ ├── MMKV
│ ├── Info.plist
│ ├── Modules
│ │ └── module.modulemap
│ └── Headers
│ │ └── MMKV.h
├── RNFastStorage.h
├── RNFastStorage.m
└── RNFastStorage.xcodeproj
│ └── project.pbxproj
├── index.js
├── package.json
├── .gitignore
├── react-native-fast-storage.podspec
└── README.md
/.gitattributes:
--------------------------------------------------------------------------------
1 | *.pbxproj -text
--------------------------------------------------------------------------------
/android/.settings/org.eclipse.buildship.core.prefs:
--------------------------------------------------------------------------------
1 | connection.project.dir=
2 | eclipse.preferences.version=1
3 |
--------------------------------------------------------------------------------
/ios/MMKV.framework/MMKV:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FidMe/react-native-fast-storage/HEAD/ios/MMKV.framework/MMKV
--------------------------------------------------------------------------------
/ios/MMKV.framework/Info.plist:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FidMe/react-native-fast-storage/HEAD/ios/MMKV.framework/Info.plist
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FidMe/react-native-fast-storage/HEAD/android/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/ios/MMKV.framework/Modules/module.modulemap:
--------------------------------------------------------------------------------
1 | framework module MMKV {
2 | umbrella header "MMKV.h"
3 |
4 | export *
5 | module * { export * }
6 | }
7 |
--------------------------------------------------------------------------------
/android/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/ios/RNFastStorage.h:
--------------------------------------------------------------------------------
1 |
2 | #if __has_include("RCTBridgeModule.h")
3 | #import "RCTBridgeModule.h"
4 | #else
5 | #import
6 | #endif
7 |
8 | @interface RNFastStorage : NSObject
9 |
10 | @end
11 |
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionBase=GRADLE_USER_HOME
2 | distributionPath=wrapper/dists
3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-all.zip
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 |
--------------------------------------------------------------------------------
/android/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/index.js:
--------------------------------------------------------------------------------
1 | import {NativeModules} from 'react-native';
2 |
3 | const {RNFastStorage} = NativeModules;
4 |
5 | if (RNFastStorage.setupLibrary) RNFastStorage.setupLibrary();
6 |
7 | export default {
8 | ...RNFastStorage,
9 | multiGet: (keys) =>
10 | Promise.all(
11 | keys.map(async (key) => [key, await RNFastStorage.getItem(key)]),
12 | ),
13 | multiSet: (keyValuePairs) =>
14 | Promise.all(
15 | keyValuePairs.map(([key, value]) => RNFastStorage.setItem(key, value)),
16 | ),
17 | multiRemove: (keys) =>
18 | Promise.all(keys.map((key) => RNFastStorage.removeItem(key))),
19 | };
20 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-native-fast-storage",
3 | "version": "0.1.6",
4 | "description": "react-native-fast-storage is a drop in replacement for AsyncStorage",
5 | "main": "index.js",
6 | "scripts": {
7 | "test": "echo \"Error: no test specified\" && exit 1"
8 | },
9 | "keywords": [
10 | "react-native"
11 | ],
12 | "repository": {
13 | "type": "git",
14 | "url": "https://github.com/FidMe/react-native-fast-storage"
15 | },
16 | "author": "Michaël Villeneuve for @FidMe",
17 | "license": "MIT",
18 | "peerDependencies": {
19 | "react-native": "^0.56.3"
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 |
2 | # OSX
3 | #
4 | .DS_Store
5 |
6 | # node.js
7 | #
8 | node_modules/
9 | npm-debug.log
10 | yarn-error.log
11 |
12 |
13 | # Xcode
14 | #
15 | build/
16 | *.pbxuser
17 | !default.pbxuser
18 | *.mode1v3
19 | !default.mode1v3
20 | *.mode2v3
21 | !default.mode2v3
22 | *.perspectivev3
23 | !default.perspectivev3
24 | xcuserdata
25 | *.xccheckout
26 | *.moved-aside
27 | DerivedData
28 | *.hmap
29 | *.ipa
30 | *.xcuserstate
31 | project.xcworkspace
32 |
33 |
34 | # Android/IntelliJ
35 | #
36 | build/
37 | .idea
38 | .gradle
39 | local.properties
40 | *.iml
41 |
42 | # BUCK
43 | buck-out/
44 | \.buckd/
45 | *.keystore
46 |
--------------------------------------------------------------------------------
/react-native-fast-storage.podspec:
--------------------------------------------------------------------------------
1 | require 'json'
2 |
3 | package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
4 |
5 | Pod::Spec.new do |s|
6 | s.name = package["name"]
7 | s.version = package["version"]
8 | s.summary = package["description"]
9 | s.homepage = "https://github.com/FidMe/react-native-fast-storage"
10 | s.license = package["license"]
11 | s.authors = package["author"]
12 | s.platform = :ios, "9.0"
13 | s.source = { :git => "#{s.homepage}", :tag => "V#{s.version}" }
14 | s.source_files = "ios/**/*.{h,m}"
15 | s.requires_arc = true
16 | s.dependency 'React'
17 | s.dependency 'MMKV', '1.0.23'
18 | end
--------------------------------------------------------------------------------
/android/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | android
4 | Project android created by Buildship.
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 | org.eclipse.buildship.core.gradleprojectbuilder
15 |
16 |
17 |
18 |
19 |
20 | org.eclipse.jdt.core.javanature
21 | org.eclipse.buildship.core.gradleprojectnature
22 |
23 |
24 |
--------------------------------------------------------------------------------
/android/src/main/java/com/fidme/faststorage/RNFastStoragePackage.java:
--------------------------------------------------------------------------------
1 |
2 | package com.fidme.faststorage;
3 |
4 | import java.util.Arrays;
5 | import java.util.Collections;
6 | import java.util.List;
7 |
8 | import com.facebook.react.ReactPackage;
9 | import com.facebook.react.bridge.NativeModule;
10 | import com.facebook.react.bridge.ReactApplicationContext;
11 | import com.facebook.react.uimanager.ViewManager;
12 | import com.facebook.react.bridge.JavaScriptModule;
13 |
14 | public class RNFastStoragePackage implements ReactPackage {
15 | @Override
16 | public List createNativeModules(ReactApplicationContext reactContext) {
17 | return Arrays.asList(new RNFastStorageModule(reactContext));
18 | }
19 |
20 | // Deprecated from RN 0.47
21 | public List> createJSModules() {
22 | return Collections.emptyList();
23 | }
24 |
25 | @Override
26 | public List createViewManagers(ReactApplicationContext reactContext) {
27 | return Collections.emptyList();
28 | }
29 | }
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | def safeExtGet(prop, fallback) {
2 | rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
3 | }
4 |
5 | buildscript {
6 | repositories {
7 | mavenCentral()
8 | google()
9 | maven {
10 | url 'https://maven.google.com'
11 | }
12 | }
13 |
14 | dependencies {
15 | classpath 'com.android.tools.build:gradle:4.2.2'
16 | }
17 | }
18 |
19 | apply plugin: 'com.android.library'
20 |
21 | android {
22 | compileSdkVersion safeExtGet('compileSdkVersion', 30)
23 | buildToolsVersion safeExtGet('buildToolsVersion', '30.0.2')
24 | defaultConfig {
25 | minSdkVersion safeExtGet('minSdkVersion', 21)
26 | targetSdkVersion safeExtGet('targetSdkVersion', 30)
27 | }
28 | lintOptions {
29 | abortOnError false
30 | warning 'InvalidPackage'
31 | }
32 | }
33 |
34 | repositories {
35 | mavenCentral()
36 | maven {
37 | url 'https://maven.google.com'
38 | }
39 | maven { url "https://www.jitpack.io" }
40 | }
41 |
42 | dependencies {
43 | implementation 'com.facebook.react:react-native:+'
44 | implementation 'com.tencent:mmkv-static:1.2.10'
45 | }
46 |
--------------------------------------------------------------------------------
/android/src/main/java/com/fidme/faststorage/RNFastStorageModule.java:
--------------------------------------------------------------------------------
1 |
2 | package com.fidme.faststorage;
3 |
4 | import com.facebook.react.bridge.ReactApplicationContext;
5 | import com.facebook.react.bridge.ReactContextBaseJavaModule;
6 | import com.facebook.react.bridge.ReactMethod;
7 | import com.facebook.react.bridge.Promise;
8 | import com.tencent.mmkv.MMKV;
9 |
10 | public class RNFastStorageModule extends ReactContextBaseJavaModule {
11 |
12 | private final ReactApplicationContext reactContext;
13 |
14 | public RNFastStorageModule(ReactApplicationContext reactContext) {
15 | super(reactContext);
16 | this.reactContext = reactContext;
17 | }
18 |
19 | @Override
20 | public String getName() {
21 | return "RNFastStorage";
22 | }
23 |
24 | @ReactMethod
25 | public void setupLibrary() {
26 | MMKV.initialize(getReactApplicationContext());
27 | }
28 |
29 | @ReactMethod
30 | public void setItem(String key, String value, Promise promise) {
31 | try {
32 | MMKV kv = MMKV.defaultMMKV();
33 | kv.encode(key, value);
34 | promise.resolve(value);
35 | } catch (Error e) {
36 | promise.reject("Error", "Unable to setItem");
37 | } catch (Exception e) {
38 | promise.reject("Error", "Unable to setItem");
39 | }
40 | }
41 |
42 | @ReactMethod
43 | public void getItem(String key, Promise promise) {
44 | try {
45 | MMKV kv = MMKV.defaultMMKV();
46 | promise.resolve(kv.decodeString(key));
47 | } catch (Error e) {
48 | promise.reject("Error", "Unable to getItem");
49 | } catch (Exception e) {
50 | promise.reject("Error", "Unable to getItem");
51 | }
52 | }
53 |
54 | @ReactMethod
55 | public void removeItem(String key, Promise promise) {
56 | try {
57 | MMKV kv = MMKV.defaultMMKV();
58 | kv.removeValueForKey(key);
59 | promise.resolve(key);
60 | } catch (Error e) {
61 | promise.reject("Error", "Unable to removeItem");
62 | } catch (Exception e) {
63 | promise.reject("Error", "Unable to removeItem");
64 | }
65 | }
66 |
67 | @ReactMethod
68 | public void clearStore(Promise promise) {
69 | try {
70 | MMKV kv = MMKV.defaultMMKV();
71 | kv.clearAll();
72 | promise.resolve("Done");
73 | } catch (Error e) {
74 | promise.reject("Error", "Unable to removeItem");
75 | } catch (Exception e) {
76 | promise.reject("Error", "Unable to removeItem");
77 | }
78 | }
79 | }
--------------------------------------------------------------------------------
/android/gradlew.bat:
--------------------------------------------------------------------------------
1 | @rem
2 | @rem Copyright 2015 the original author or authors.
3 | @rem
4 | @rem Licensed under the Apache License, Version 2.0 (the "License");
5 | @rem you may not use this file except in compliance with the License.
6 | @rem You may obtain a copy of the License at
7 | @rem
8 | @rem https://www.apache.org/licenses/LICENSE-2.0
9 | @rem
10 | @rem Unless required by applicable law or agreed to in writing, software
11 | @rem distributed under the License is distributed on an "AS IS" BASIS,
12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | @rem See the License for the specific language governing permissions and
14 | @rem limitations under the License.
15 | @rem
16 |
17 | @if "%DEBUG%" == "" @echo off
18 | @rem ##########################################################################
19 | @rem
20 | @rem Gradle startup script for Windows
21 | @rem
22 | @rem ##########################################################################
23 |
24 | @rem Set local scope for the variables with windows NT shell
25 | if "%OS%"=="Windows_NT" setlocal
26 |
27 | set DIRNAME=%~dp0
28 | if "%DIRNAME%" == "" set DIRNAME=.
29 | set APP_BASE_NAME=%~n0
30 | set APP_HOME=%DIRNAME%
31 |
32 | @rem Resolve any "." and ".." in APP_HOME to make it shorter.
33 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
34 |
35 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
36 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
37 |
38 | @rem Find java.exe
39 | if defined JAVA_HOME goto findJavaFromJavaHome
40 |
41 | set JAVA_EXE=java.exe
42 | %JAVA_EXE% -version >NUL 2>&1
43 | if "%ERRORLEVEL%" == "0" goto execute
44 |
45 | echo.
46 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
47 | echo.
48 | echo Please set the JAVA_HOME variable in your environment to match the
49 | echo location of your Java installation.
50 |
51 | goto fail
52 |
53 | :findJavaFromJavaHome
54 | set JAVA_HOME=%JAVA_HOME:"=%
55 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
56 |
57 | if exist "%JAVA_EXE%" goto execute
58 |
59 | echo.
60 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
61 | echo.
62 | echo Please set the JAVA_HOME variable in your environment to match the
63 | echo location of your Java installation.
64 |
65 | goto fail
66 |
67 | :execute
68 | @rem Setup the command line
69 |
70 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
71 |
72 |
73 | @rem Execute Gradle
74 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
75 |
76 | :end
77 | @rem End local scope for the variables with windows NT shell
78 | if "%ERRORLEVEL%"=="0" goto mainEnd
79 |
80 | :fail
81 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
82 | rem the _cmd.exe /c_ return code!
83 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
84 | exit /b 1
85 |
86 | :mainEnd
87 | if "%OS%"=="Windows_NT" endlocal
88 |
89 | :omega
90 |
--------------------------------------------------------------------------------
/ios/RNFastStorage.m:
--------------------------------------------------------------------------------
1 |
2 | #import "RNFastStorage.h"
3 | #import
4 |
5 | @implementation RNFastStorage
6 |
7 | - (dispatch_queue_t)methodQueue
8 | {
9 | return dispatch_get_main_queue();
10 | }
11 | RCT_EXPORT_MODULE()
12 |
13 | #pragma mark setItem
14 | RCT_EXPORT_METHOD(setItem:(NSString*)key
15 | value:(NSString*)value
16 | resolve:(RCTPromiseResolveBlock)resolve
17 | rejecter:(RCTPromiseRejectBlock)reject
18 | ) {
19 | dispatch_async(dispatch_queue_create("FastStorage.setItem", 0), ^{
20 | dispatch_async(dispatch_get_main_queue(), ^{
21 | @try {
22 | MMKV *mmkv = [MMKV defaultMMKV];
23 | [mmkv setObject:value forKey:key];
24 | resolve(value);
25 | }
26 | @catch (NSException *exception) {
27 | reject(@"cannot_set", @"Cannot set item", nil);
28 | }
29 |
30 | });
31 | });
32 | }
33 |
34 | #pragma mark getItem
35 | RCT_EXPORT_METHOD(getItem:(NSString*)key
36 | resolve:(RCTPromiseResolveBlock)resolve
37 | rejecter:(RCTPromiseRejectBlock)reject
38 | ) {
39 | dispatch_async(dispatch_queue_create("FastStorage.getItem", 0), ^{
40 | dispatch_async(dispatch_get_main_queue(), ^{
41 | @try {
42 | MMKV *mmkv = [MMKV defaultMMKV];
43 | resolve([mmkv getObjectOfClass:NSString.class forKey:key]);
44 | }
45 | @catch (NSException *exception) {
46 | reject(@"cannot_get", exception.reason, nil);
47 | }
48 |
49 | });
50 | });
51 | }
52 |
53 | #pragma mark removeItem
54 | RCT_EXPORT_METHOD(removeItem:(NSString*)key
55 | resolve:(RCTPromiseResolveBlock)resolve
56 | rejecter:(RCTPromiseRejectBlock)reject
57 | ) {
58 | dispatch_async(dispatch_queue_create("FastStorage.removeItem", 0), ^{
59 | dispatch_async(dispatch_get_main_queue(), ^{
60 | @try {
61 | MMKV *mmkv = [MMKV defaultMMKV];
62 | [mmkv removeValueForKey:key];
63 | resolve(@"");
64 | }
65 | @catch (NSException *exception) {
66 | reject(@"cannot_get", exception.reason, nil);
67 | }
68 |
69 | });
70 | });
71 | }
72 |
73 | #pragma mark clearStore
74 | RCT_EXPORT_METHOD(clearStore:(RCTPromiseResolveBlock)resolve
75 | rejecter:(RCTPromiseRejectBlock)reject
76 | ) {
77 | dispatch_async(dispatch_queue_create("FastStorage.clearStore", 0), ^{
78 | dispatch_async(dispatch_get_main_queue(), ^{
79 | @try {
80 | MMKV *mmkv = [MMKV defaultMMKV];
81 | [mmkv clearAll];
82 | resolve(@"");
83 | }
84 | @catch (NSException *exception) {
85 | reject(@"cannot_get", exception.reason, nil);
86 | }
87 |
88 | });
89 | });
90 | }
91 |
92 |
93 | @end
94 |
95 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # react-native-fast-storage
2 |
3 | react-native-fast-storage is a drop in replacement for `AsyncStorage`.
4 |
5 | This library is the React Native implementation of https://github.com/Tencent/MMKV.
6 |
7 | It provides very fast read and write access.
8 |
9 | ## Getting started
10 |
11 | `$ npm install react-native-fast-storage --save`
12 |
13 | `$ react-native link react-native-fast-storage`
14 |
15 | **Additional IOS step**
16 |
17 | If you encounter this error :
18 |
19 | ```
20 | ld: warning: Could not find auto-linked framework 'MMKV'
21 | ```
22 |
23 | You need to manually follow these steps :
24 |
25 | - Open up your project in Xcode
26 | - Select the main target (under "Targets"),
27 | - Go to the "Build Settings" tab, and find the "Framework Search Paths" section.
28 | - Add `../node_modules/react-native-fast-storage/ios` (non-recursive) for each of your configurations (e.g. Debug and Release).
29 | - Find the MMKV.framework file in ../node_modules/react-native-fast-storage/ios and drag it into Xcode under the "Frameworks" section. In the dialog that pops up, uncheck "Copy items if needed", choose "Create groups", and ensure your main target is checked under "Add to targets".
30 | - In Xcode, select the project, then select the main target (under "Targets"), then go to the "General" tab and find the "Embedded Binaries" section. Click the "+" icon and select MMKV.framework which appears under "Frameworks" then click "Add".
31 | - In Xcode do "Product" -> "Clean".
32 |
33 | ## Usage
34 |
35 | ```javascript
36 | import FastStorage from "react-native-fast-storage";
37 |
38 | await FastStorage.setItem("key", "Coucou toi");
39 |
40 | const item = await FastStorage.getItem("key");
41 | ```
42 |
43 | ## Methods
44 |
45 | All methods are asynchronous, just like AsyncStorage.
46 |
47 | | Prop | Params | Returns | Description |
48 | | :---------- | :--------------------------: | :--------------------------: | :------------------------------------ |
49 | | setItem | `key`, `value` | `value` | Allows to set an item |
50 | | getItem | `key` | `value` | Retrieve the item |
51 | | removeItem | `key` | null | Remove an item from the store |
52 | | clearStore | none | null | Clear the entire store |
53 | | multiGet | Array<`key`> | Array> | Retrieve multiples item |
54 | | multiGet | Array> | null | Set multiples items |
55 | | multiRemove | Array<`key`> | null | Remove multiples items from the store |
56 |
57 |
58 | ## multiGet
59 |
60 | Get multiple values at once.
61 |
62 | ```static multiGet(keys: Array): Promise>>```
63 |
64 | ```js
65 | const values = await FastStorage.multiGet(['test', 'key'])
66 | console.log(values) // [['test', 'testValue'], ['key', 'keyValue']]
67 | ```
68 |
69 | ## multiSet
70 |
71 | Set multiple values at once.
72 |
73 | ```static multiSet(keys: Array>): Promise```
74 |
75 | ```js
76 | await FastStorage.multiSet([['test', 'testValue'], ['key', 'keyValue']])
77 | ```
78 |
79 |
80 | ## multiRemove
81 |
82 | Remove multiples values at once.
83 |
84 | ```static multiRemove(keys: Array): Promise```
85 |
86 | ```js
87 | await FastStorage.multiRemove(['test', 'key'])
88 | ```
--------------------------------------------------------------------------------
/ios/MMKV.framework/Headers/MMKV.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Tencent is pleased to support the open source community by making
3 | * MMKV available.
4 | *
5 | * Copyright (C) 2018 THL A29 Limited, a Tencent company.
6 | * All rights reserved.
7 | *
8 | * Licensed under the BSD 3-Clause License (the "License"); you may not use
9 | * this file except in compliance with the License. You may obtain a copy of
10 | * the License at
11 | *
12 | * https://opensource.org/licenses/BSD-3-Clause
13 | *
14 | * Unless required by applicable law or agreed to in writing, software
15 | * distributed under the License is distributed on an "AS IS" BASIS,
16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 | * See the License for the specific language governing permissions and
18 | * limitations under the License.
19 | */
20 |
21 | #import
22 |
23 | @interface MMKV : NSObject
24 |
25 | NS_ASSUME_NONNULL_BEGIN
26 |
27 | // a generic purpose instance
28 | + (instancetype)defaultMMKV;
29 |
30 | // mmapID: any unique ID (com.tencent.xin.pay, etc)
31 | // if you want a per-user mmkv, you could merge user-id within mmapID
32 | + (nullable instancetype)mmkvWithID:(NSString *)mmapID NS_SWIFT_NAME(init(mmapID:));
33 |
34 | // mmapID: any unique ID (com.tencent.xin.pay, etc)
35 | // if you want a per-user mmkv, you could merge user-id within mmapID
36 | // cryptKey: 16 byte at most
37 | + (nullable instancetype)mmkvWithID:(NSString *)mmapID cryptKey:(nullable NSData *)cryptKey NS_SWIFT_NAME(init(mmapID:cryptKey:));
38 |
39 | - (BOOL)reKey:(nullable NSData *)newKey NS_SWIFT_NAME(reset(cryptKey:));
40 | - (nullable NSData *)cryptKey;
41 |
42 | // object: NSString/NSData/NSDate/id
43 | - (BOOL)setObject:(id)object forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
44 |
45 | - (BOOL)setBool:(BOOL)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
46 |
47 | - (BOOL)setInt32:(int32_t)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
48 |
49 | - (BOOL)setUInt32:(uint32_t)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
50 |
51 | - (BOOL)setInt64:(int64_t)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
52 |
53 | - (BOOL)setUInt64:(uint64_t)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
54 |
55 | - (BOOL)setFloat:(float)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
56 |
57 | - (BOOL)setDouble:(double)value forKey:(NSString *)key NS_SWIFT_NAME(set(_:forKey:));
58 |
59 | - (nullable id)getObjectOfClass:(Class)cls forKey:(NSString *)key NS_SWIFT_NAME(object(of:forKey:));
60 |
61 | - (bool)getBoolForKey:(NSString *)key NS_SWIFT_NAME(boolValue(forKey:));
62 | - (bool)getBoolForKey:(NSString *)key defaultValue:(bool)defaultValue NS_SWIFT_NAME(boolValue(forKey:defaultValue:));
63 |
64 | - (int32_t)getInt32ForKey:(NSString *)key NS_SWIFT_NAME(int32(forKey:));
65 | - (int32_t)getInt32ForKey:(NSString *)key defaultValue:(int32_t)defaultValue NS_SWIFT_NAME(int32(forKey:defaultValue:));
66 |
67 | - (uint32_t)getUInt32ForKey:(NSString *)key NS_SWIFT_NAME(uint32(forKey:));
68 | - (uint32_t)getUInt32ForKey:(NSString *)key defaultValue:(uint32_t)defaultValue NS_SWIFT_NAME(uint32(forKey:defaultValue:));
69 |
70 | - (int64_t)getInt64ForKey:(NSString *)key NS_SWIFT_NAME(int64(forKey:));
71 | - (int64_t)getInt64ForKey:(NSString *)key defaultValue:(int64_t)defaultValue NS_SWIFT_NAME(int64(forKey:defaultValue:));
72 |
73 | - (uint64_t)getUInt64ForKey:(NSString *)key NS_SWIFT_NAME(uint64(forKey:));
74 | - (uint64_t)getUInt64ForKey:(NSString *)key defaultValue:(uint64_t)defaultValue NS_SWIFT_NAME(uint64(forKey:defaultValue:));
75 |
76 | - (float)getFloatForKey:(NSString *)key NS_SWIFT_NAME(float(forKey:));
77 | - (float)getFloatForKey:(NSString *)key defaultValue:(float)defaultValue NS_SWIFT_NAME(float(forKey:defaultValue:));
78 |
79 | - (double)getDoubleForKey:(NSString *)key NS_SWIFT_NAME(double(forKey:));
80 | - (double)getDoubleForKey:(NSString *)key defaultValue:(double)defaultValue NS_SWIFT_NAME(double(forKey:defaultValue:));
81 |
82 | - (BOOL)containsKey:(NSString *)key NS_SWIFT_NAME(contains(key:));
83 |
84 | - (size_t)count;
85 |
86 | - (size_t)totalSize;
87 |
88 | - (void)enumerateKeys:(void (^)(NSString *key, BOOL *stop))block;
89 |
90 | - (void)removeValueForKey:(NSString *)key NS_SWIFT_NAME(removeValue(forKey:));
91 |
92 | - (void)removeValuesForKeys:(NSArray *)arrKeys NS_SWIFT_NAME(removeValues(forKeys:));
93 |
94 | - (void)clearMemoryCache;
95 |
96 | - (void)clearAll;
97 |
98 | // you don't need to call this, really, I mean it
99 | // unless you care about out of battery
100 | - (void)sync;
101 |
102 | // for CrashProtected Only!!
103 | + (BOOL)isFileValid:(NSString *)mmapID NS_SWIFT_NAME(isFileValid(for:));
104 |
105 | NS_ASSUME_NONNULL_END
106 |
107 | @end
108 |
--------------------------------------------------------------------------------
/android/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 |
3 | #
4 | # Copyright 2015 the original author or authors.
5 | #
6 | # Licensed under the Apache License, Version 2.0 (the "License");
7 | # you may not use this file except in compliance with the License.
8 | # You may obtain a copy of the License at
9 | #
10 | # https://www.apache.org/licenses/LICENSE-2.0
11 | #
12 | # Unless required by applicable law or agreed to in writing, software
13 | # distributed under the License is distributed on an "AS IS" BASIS,
14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 | # See the License for the specific language governing permissions and
16 | # limitations under the License.
17 | #
18 |
19 | ##############################################################################
20 | ##
21 | ## Gradle start up script for UN*X
22 | ##
23 | ##############################################################################
24 |
25 | # Attempt to set APP_HOME
26 | # Resolve links: $0 may be a link
27 | PRG="$0"
28 | # Need this for relative symlinks.
29 | while [ -h "$PRG" ] ; do
30 | ls=`ls -ld "$PRG"`
31 | link=`expr "$ls" : '.*-> \(.*\)$'`
32 | if expr "$link" : '/.*' > /dev/null; then
33 | PRG="$link"
34 | else
35 | PRG=`dirname "$PRG"`"/$link"
36 | fi
37 | done
38 | SAVED="`pwd`"
39 | cd "`dirname \"$PRG\"`/" >/dev/null
40 | APP_HOME="`pwd -P`"
41 | cd "$SAVED" >/dev/null
42 |
43 | APP_NAME="Gradle"
44 | APP_BASE_NAME=`basename "$0"`
45 |
46 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
47 | DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
48 |
49 | # Use the maximum available, or set MAX_FD != -1 to use that value.
50 | MAX_FD="maximum"
51 |
52 | warn () {
53 | echo "$*"
54 | }
55 |
56 | die () {
57 | echo
58 | echo "$*"
59 | echo
60 | exit 1
61 | }
62 |
63 | # OS specific support (must be 'true' or 'false').
64 | cygwin=false
65 | msys=false
66 | darwin=false
67 | nonstop=false
68 | case "`uname`" in
69 | CYGWIN* )
70 | cygwin=true
71 | ;;
72 | Darwin* )
73 | darwin=true
74 | ;;
75 | MINGW* )
76 | msys=true
77 | ;;
78 | NONSTOP* )
79 | nonstop=true
80 | ;;
81 | esac
82 |
83 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
84 |
85 |
86 | # Determine the Java command to use to start the JVM.
87 | if [ -n "$JAVA_HOME" ] ; then
88 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
89 | # IBM's JDK on AIX uses strange locations for the executables
90 | JAVACMD="$JAVA_HOME/jre/sh/java"
91 | else
92 | JAVACMD="$JAVA_HOME/bin/java"
93 | fi
94 | if [ ! -x "$JAVACMD" ] ; then
95 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
96 |
97 | Please set the JAVA_HOME variable in your environment to match the
98 | location of your Java installation."
99 | fi
100 | else
101 | JAVACMD="java"
102 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
103 |
104 | Please set the JAVA_HOME variable in your environment to match the
105 | location of your Java installation."
106 | fi
107 |
108 | # Increase the maximum file descriptors if we can.
109 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
110 | MAX_FD_LIMIT=`ulimit -H -n`
111 | if [ $? -eq 0 ] ; then
112 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
113 | MAX_FD="$MAX_FD_LIMIT"
114 | fi
115 | ulimit -n $MAX_FD
116 | if [ $? -ne 0 ] ; then
117 | warn "Could not set maximum file descriptor limit: $MAX_FD"
118 | fi
119 | else
120 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
121 | fi
122 | fi
123 |
124 | # For Darwin, add options to specify how the application appears in the dock
125 | if $darwin; then
126 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
127 | fi
128 |
129 | # For Cygwin or MSYS, switch paths to Windows format before running java
130 | if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
131 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
132 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
133 |
134 | JAVACMD=`cygpath --unix "$JAVACMD"`
135 |
136 | # We build the pattern for arguments to be converted via cygpath
137 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
138 | SEP=""
139 | for dir in $ROOTDIRSRAW ; do
140 | ROOTDIRS="$ROOTDIRS$SEP$dir"
141 | SEP="|"
142 | done
143 | OURCYGPATTERN="(^($ROOTDIRS))"
144 | # Add a user-defined pattern to the cygpath arguments
145 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
146 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
147 | fi
148 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
149 | i=0
150 | for arg in "$@" ; do
151 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
152 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
153 |
154 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
155 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
156 | else
157 | eval `echo args$i`="\"$arg\""
158 | fi
159 | i=`expr $i + 1`
160 | done
161 | case $i in
162 | 0) set -- ;;
163 | 1) set -- "$args0" ;;
164 | 2) set -- "$args0" "$args1" ;;
165 | 3) set -- "$args0" "$args1" "$args2" ;;
166 | 4) set -- "$args0" "$args1" "$args2" "$args3" ;;
167 | 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
168 | 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
169 | 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
170 | 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
171 | 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
172 | esac
173 | fi
174 |
175 | # Escape application args
176 | save () {
177 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
178 | echo " "
179 | }
180 | APP_ARGS=`save "$@"`
181 |
182 | # Collect all arguments for the java command, following the shell quoting and substitution rules
183 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
184 |
185 | exec "$JAVACMD" "$@"
186 |
--------------------------------------------------------------------------------
/ios/RNFastStorage.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 768238A52170840D00A83AC5 /* MMKV.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 768238A42170840D00A83AC5 /* MMKV.framework */; };
11 | B3E7B58A1CC2AC0600A0062D /* RNFastStorage.m in Sources */ = {isa = PBXBuildFile; fileRef = B3E7B5891CC2AC0600A0062D /* RNFastStorage.m */; };
12 | /* End PBXBuildFile section */
13 |
14 | /* Begin PBXCopyFilesBuildPhase section */
15 | 58B511D91A9E6C8500147676 /* CopyFiles */ = {
16 | isa = PBXCopyFilesBuildPhase;
17 | buildActionMask = 2147483647;
18 | dstPath = "include/$(PRODUCT_NAME)";
19 | dstSubfolderSpec = 16;
20 | files = (
21 | );
22 | runOnlyForDeploymentPostprocessing = 0;
23 | };
24 | /* End PBXCopyFilesBuildPhase section */
25 |
26 | /* Begin PBXFileReference section */
27 | 134814201AA4EA6300B7C361 /* libRNFastStorage.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRNFastStorage.a; sourceTree = BUILT_PRODUCTS_DIR; };
28 | 768238A42170840D00A83AC5 /* MMKV.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = MMKV.framework; sourceTree = ""; };
29 | B3E7B5881CC2AC0600A0062D /* RNFastStorage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RNFastStorage.h; sourceTree = ""; };
30 | B3E7B5891CC2AC0600A0062D /* RNFastStorage.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RNFastStorage.m; sourceTree = ""; };
31 | /* End PBXFileReference section */
32 |
33 | /* Begin PBXFrameworksBuildPhase section */
34 | 58B511D81A9E6C8500147676 /* Frameworks */ = {
35 | isa = PBXFrameworksBuildPhase;
36 | buildActionMask = 2147483647;
37 | files = (
38 | 768238A52170840D00A83AC5 /* MMKV.framework in Frameworks */,
39 | );
40 | runOnlyForDeploymentPostprocessing = 0;
41 | };
42 | /* End PBXFrameworksBuildPhase section */
43 |
44 | /* Begin PBXGroup section */
45 | 134814211AA4EA7D00B7C361 /* Products */ = {
46 | isa = PBXGroup;
47 | children = (
48 | 134814201AA4EA6300B7C361 /* libRNFastStorage.a */,
49 | );
50 | name = Products;
51 | sourceTree = "";
52 | };
53 | 58B511D21A9E6C8500147676 = {
54 | isa = PBXGroup;
55 | children = (
56 | 768238A42170840D00A83AC5 /* MMKV.framework */,
57 | B3E7B5881CC2AC0600A0062D /* RNFastStorage.h */,
58 | B3E7B5891CC2AC0600A0062D /* RNFastStorage.m */,
59 | 134814211AA4EA7D00B7C361 /* Products */,
60 | );
61 | sourceTree = "";
62 | };
63 | /* End PBXGroup section */
64 |
65 | /* Begin PBXNativeTarget section */
66 | 58B511DA1A9E6C8500147676 /* RNFastStorage */ = {
67 | isa = PBXNativeTarget;
68 | buildConfigurationList = 58B511EF1A9E6C8500147676 /* Build configuration list for PBXNativeTarget "RNFastStorage" */;
69 | buildPhases = (
70 | 58B511D71A9E6C8500147676 /* Sources */,
71 | 58B511D81A9E6C8500147676 /* Frameworks */,
72 | 58B511D91A9E6C8500147676 /* CopyFiles */,
73 | );
74 | buildRules = (
75 | );
76 | dependencies = (
77 | );
78 | name = RNFastStorage;
79 | productName = RCTDataManager;
80 | productReference = 134814201AA4EA6300B7C361 /* libRNFastStorage.a */;
81 | productType = "com.apple.product-type.library.static";
82 | };
83 | /* End PBXNativeTarget section */
84 |
85 | /* Begin PBXProject section */
86 | 58B511D31A9E6C8500147676 /* Project object */ = {
87 | isa = PBXProject;
88 | attributes = {
89 | LastUpgradeCheck = 0830;
90 | ORGANIZATIONNAME = Facebook;
91 | TargetAttributes = {
92 | 58B511DA1A9E6C8500147676 = {
93 | CreatedOnToolsVersion = 6.1.1;
94 | };
95 | };
96 | };
97 | buildConfigurationList = 58B511D61A9E6C8500147676 /* Build configuration list for PBXProject "RNFastStorage" */;
98 | compatibilityVersion = "Xcode 3.2";
99 | developmentRegion = English;
100 | hasScannedForEncodings = 0;
101 | knownRegions = (
102 | en,
103 | );
104 | mainGroup = 58B511D21A9E6C8500147676;
105 | productRefGroup = 58B511D21A9E6C8500147676;
106 | projectDirPath = "";
107 | projectRoot = "";
108 | targets = (
109 | 58B511DA1A9E6C8500147676 /* RNFastStorage */,
110 | );
111 | };
112 | /* End PBXProject section */
113 |
114 | /* Begin PBXSourcesBuildPhase section */
115 | 58B511D71A9E6C8500147676 /* Sources */ = {
116 | isa = PBXSourcesBuildPhase;
117 | buildActionMask = 2147483647;
118 | files = (
119 | B3E7B58A1CC2AC0600A0062D /* RNFastStorage.m in Sources */,
120 | );
121 | runOnlyForDeploymentPostprocessing = 0;
122 | };
123 | /* End PBXSourcesBuildPhase section */
124 |
125 | /* Begin XCBuildConfiguration section */
126 | 58B511ED1A9E6C8500147676 /* Debug */ = {
127 | isa = XCBuildConfiguration;
128 | buildSettings = {
129 | ALWAYS_SEARCH_USER_PATHS = NO;
130 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
131 | CLANG_CXX_LIBRARY = "libc++";
132 | CLANG_ENABLE_MODULES = YES;
133 | CLANG_ENABLE_OBJC_ARC = YES;
134 | CLANG_WARN_BOOL_CONVERSION = YES;
135 | CLANG_WARN_CONSTANT_CONVERSION = YES;
136 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
137 | CLANG_WARN_EMPTY_BODY = YES;
138 | CLANG_WARN_ENUM_CONVERSION = YES;
139 | CLANG_WARN_INFINITE_RECURSION = YES;
140 | CLANG_WARN_INT_CONVERSION = YES;
141 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
142 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
143 | CLANG_WARN_UNREACHABLE_CODE = YES;
144 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
145 | COPY_PHASE_STRIP = NO;
146 | ENABLE_STRICT_OBJC_MSGSEND = YES;
147 | ENABLE_TESTABILITY = YES;
148 | GCC_C_LANGUAGE_STANDARD = gnu99;
149 | GCC_DYNAMIC_NO_PIC = NO;
150 | GCC_NO_COMMON_BLOCKS = YES;
151 | GCC_OPTIMIZATION_LEVEL = 0;
152 | GCC_PREPROCESSOR_DEFINITIONS = (
153 | "DEBUG=1",
154 | "$(inherited)",
155 | );
156 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
157 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
158 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
159 | GCC_WARN_UNDECLARED_SELECTOR = YES;
160 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
161 | GCC_WARN_UNUSED_FUNCTION = YES;
162 | GCC_WARN_UNUSED_VARIABLE = YES;
163 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
164 | MTL_ENABLE_DEBUG_INFO = YES;
165 | ONLY_ACTIVE_ARCH = YES;
166 | SDKROOT = iphoneos;
167 | };
168 | name = Debug;
169 | };
170 | 58B511EE1A9E6C8500147676 /* Release */ = {
171 | isa = XCBuildConfiguration;
172 | buildSettings = {
173 | ALWAYS_SEARCH_USER_PATHS = NO;
174 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
175 | CLANG_CXX_LIBRARY = "libc++";
176 | CLANG_ENABLE_MODULES = YES;
177 | CLANG_ENABLE_OBJC_ARC = YES;
178 | CLANG_WARN_BOOL_CONVERSION = YES;
179 | CLANG_WARN_CONSTANT_CONVERSION = YES;
180 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
181 | CLANG_WARN_EMPTY_BODY = YES;
182 | CLANG_WARN_ENUM_CONVERSION = YES;
183 | CLANG_WARN_INFINITE_RECURSION = YES;
184 | CLANG_WARN_INT_CONVERSION = YES;
185 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
186 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
187 | CLANG_WARN_UNREACHABLE_CODE = YES;
188 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
189 | COPY_PHASE_STRIP = YES;
190 | ENABLE_NS_ASSERTIONS = NO;
191 | ENABLE_STRICT_OBJC_MSGSEND = YES;
192 | GCC_C_LANGUAGE_STANDARD = gnu99;
193 | GCC_NO_COMMON_BLOCKS = YES;
194 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
195 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
196 | GCC_WARN_UNDECLARED_SELECTOR = YES;
197 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
198 | GCC_WARN_UNUSED_FUNCTION = YES;
199 | GCC_WARN_UNUSED_VARIABLE = YES;
200 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
201 | MTL_ENABLE_DEBUG_INFO = NO;
202 | SDKROOT = iphoneos;
203 | VALIDATE_PRODUCT = YES;
204 | };
205 | name = Release;
206 | };
207 | 58B511F01A9E6C8500147676 /* Debug */ = {
208 | isa = XCBuildConfiguration;
209 | buildSettings = {
210 | FRAMEWORK_SEARCH_PATHS = (
211 | "$(inherited)",
212 | "$(PROJECT_DIR)",
213 | );
214 | HEADER_SEARCH_PATHS = (
215 | "$(inherited)",
216 | /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
217 | "$(SRCROOT)/../../../React/**",
218 | "$(SRCROOT)/../../react-native/React/**",
219 | );
220 | LIBRARY_SEARCH_PATHS = "$(inherited)";
221 | OTHER_LDFLAGS = "-ObjC";
222 | PRODUCT_NAME = RNFastStorage;
223 | SKIP_INSTALL = YES;
224 | };
225 | name = Debug;
226 | };
227 | 58B511F11A9E6C8500147676 /* Release */ = {
228 | isa = XCBuildConfiguration;
229 | buildSettings = {
230 | FRAMEWORK_SEARCH_PATHS = (
231 | "$(inherited)",
232 | "$(PROJECT_DIR)",
233 | );
234 | HEADER_SEARCH_PATHS = (
235 | "$(inherited)",
236 | /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
237 | "$(SRCROOT)/../../../React/**",
238 | "$(SRCROOT)/../../react-native/React/**",
239 | );
240 | LIBRARY_SEARCH_PATHS = "$(inherited)";
241 | OTHER_LDFLAGS = "-ObjC";
242 | PRODUCT_NAME = RNFastStorage;
243 | SKIP_INSTALL = YES;
244 | };
245 | name = Release;
246 | };
247 | /* End XCBuildConfiguration section */
248 |
249 | /* Begin XCConfigurationList section */
250 | 58B511D61A9E6C8500147676 /* Build configuration list for PBXProject "RNFastStorage" */ = {
251 | isa = XCConfigurationList;
252 | buildConfigurations = (
253 | 58B511ED1A9E6C8500147676 /* Debug */,
254 | 58B511EE1A9E6C8500147676 /* Release */,
255 | );
256 | defaultConfigurationIsVisible = 0;
257 | defaultConfigurationName = Release;
258 | };
259 | 58B511EF1A9E6C8500147676 /* Build configuration list for PBXNativeTarget "RNFastStorage" */ = {
260 | isa = XCConfigurationList;
261 | buildConfigurations = (
262 | 58B511F01A9E6C8500147676 /* Debug */,
263 | 58B511F11A9E6C8500147676 /* Release */,
264 | );
265 | defaultConfigurationIsVisible = 0;
266 | defaultConfigurationName = Release;
267 | };
268 | /* End XCConfigurationList section */
269 | };
270 | rootObject = 58B511D31A9E6C8500147676 /* Project object */;
271 | }
272 |
--------------------------------------------------------------------------------