@tyrads.com/tyrads-sdk 1.1.6-beta.1 → 1.1.6-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,187 +1,187 @@
1
- {
2
- "name": "@tyrads.com/tyrads-sdk",
3
- "version": "1.1.6-beta.1",
4
- "description": "Tyrads SDK for React Native ",
5
- "source": "./src/index.tsx",
6
- "main": "./lib/commonjs/index.js",
7
- "module": "./lib/module/index.js",
8
- "exports": {
9
- ".": {
10
- "import": {
11
- "types": "./lib/typescript/module/src/index.d.ts",
12
- "default": "./lib/module/index.js"
13
- },
14
- "require": {
15
- "types": "./lib/typescript/commonjs/src/index.d.ts",
16
- "default": "./lib/commonjs/index.js"
17
- }
18
- }
19
- },
20
- "files": [
21
- "src",
22
- "lib",
23
- "android",
24
- "ios",
25
- "cpp",
26
- "*.podspec",
27
- "!ios/build",
28
- "!android/build",
29
- "!android/gradle",
30
- "!android/gradlew",
31
- "!android/gradlew.bat",
32
- "!android/local.properties",
33
- "!**/__tests__",
34
- "!**/__fixtures__",
35
- "!**/__mocks__",
36
- "!**/.*"
37
- ],
38
- "scripts": {
39
- "example": "yarn workspace tyrads-sdk-example",
40
- "test": "jest",
41
- "typecheck": "tsc",
42
- "lint": "eslint \"**/*.{js,ts,tsx}\"",
43
- "clean": "del-cli android/build example/android/build example/android/app/build example/ios/build lib",
44
- "prepare": "bob build",
45
- "release": "release-it"
46
- },
47
- "keywords": [
48
- "react-native",
49
- "ios",
50
- "android"
51
- ],
52
- "repository": {
53
- "type": "git",
54
- "url": "git+https://github.com/tyrads-com/tyrads-sdk-reactnative.git"
55
- },
56
- "author": "dev@acmo.in <dev@acmo.in> (https://tyrads.com)",
57
- "license": " BSD-3-Clause",
58
- "bugs": {
59
- "url": "https://github.com/tyrads-com/tyrads-sdk-reactnative/issues"
60
- },
61
- "homepage": "https://github.com/tyrads-com/tyrads-sdk-reactnative#readme",
62
- "publishConfig": {
63
- "registry": "https://registry.npmjs.org/"
64
- },
65
- "devDependencies": {
66
- "@commitlint/config-conventional": "^17.0.2",
67
- "@evilmartians/lefthook": "^1.5.0",
68
- "@react-native/eslint-config": "^0.73.1",
69
- "@release-it/conventional-changelog": "^5.0.0",
70
- "@types/jest": "^29.5.5",
71
- "@types/react": "^18.2.44",
72
- "commitlint": "^17.0.2",
73
- "del-cli": "^5.1.0",
74
- "eslint": "^8.51.0",
75
- "eslint-config-prettier": "^9.0.0",
76
- "eslint-plugin-prettier": "^5.0.1",
77
- "jest": "^29.7.0",
78
- "prettier": "^3.0.3",
79
- "react": "18.2.0",
80
- "react-native": "0.74.5",
81
- "react-native-builder-bob": "^0.29.0",
82
- "release-it": "^15.0.0",
83
- "turbo": "^1.10.7",
84
- "typescript": "^5.2.2"
85
- },
86
- "resolutions": {
87
- "@types/react": "^18.2.44"
88
- },
89
- "peerDependencies": {
90
- "react": "*",
91
- "react-native": "*"
92
- },
93
- "workspaces": [
94
- "example"
95
- ],
96
- "packageManager": "yarn@3.6.1",
97
- "jest": {
98
- "preset": "react-native",
99
- "modulePathIgnorePatterns": [
100
- "<rootDir>/example/node_modules",
101
- "<rootDir>/lib/"
102
- ]
103
- },
104
- "commitlint": {
105
- "extends": [
106
- "@commitlint/config-conventional"
107
- ]
108
- },
109
- "release-it": {
110
- "git": {
111
- "commitMessage": "chore: release ${version}",
112
- "tagName": "v${version}"
113
- },
114
- "npm": {
115
- "publish": true
116
- },
117
- "github": {
118
- "release": true
119
- },
120
- "plugins": {
121
- "@release-it/conventional-changelog": {
122
- "preset": "angular"
123
- }
124
- }
125
- },
126
- "eslintConfig": {
127
- "root": true,
128
- "extends": [
129
- "@react-native",
130
- "prettier"
131
- ],
132
- "rules": {
133
- "react/react-in-jsx-scope": "off",
134
- "prettier/prettier": [
135
- "error",
136
- {
137
- "quoteProps": "consistent",
138
- "singleQuote": true,
139
- "tabWidth": 2,
140
- "trailingComma": "es5",
141
- "useTabs": false
142
- }
143
- ]
144
- }
145
- },
146
- "eslintIgnore": [
147
- "node_modules/",
148
- "lib/"
149
- ],
150
- "prettier": {
151
- "quoteProps": "consistent",
152
- "singleQuote": true,
153
- "tabWidth": 2,
154
- "trailingComma": "es5",
155
- "useTabs": false
156
- },
157
- "react-native-builder-bob": {
158
- "source": "src",
159
- "output": "lib",
160
- "targets": [
161
- [
162
- "commonjs",
163
- {
164
- "esm": true
165
- }
166
- ],
167
- [
168
- "module",
169
- {
170
- "esm": true
171
- }
172
- ],
173
- [
174
- "typescript",
175
- {
176
- "project": "tsconfig.build.json",
177
- "esm": true
178
- }
179
- ]
180
- ]
181
- },
182
- "create-react-native-library": {
183
- "type": "module-legacy",
184
- "languages": "kotlin-swift",
185
- "version": "0.40.0"
186
- }
187
- }
1
+ {
2
+ "name": "@tyrads.com/tyrads-sdk",
3
+ "version": "1.1.6-beta.2",
4
+ "description": "Tyrads SDK for React Native ",
5
+ "source": "./src/index.tsx",
6
+ "main": "./lib/commonjs/index.js",
7
+ "module": "./lib/module/index.js",
8
+ "exports": {
9
+ ".": {
10
+ "import": {
11
+ "types": "./lib/typescript/module/src/index.d.ts",
12
+ "default": "./lib/module/index.js"
13
+ },
14
+ "require": {
15
+ "types": "./lib/typescript/commonjs/src/index.d.ts",
16
+ "default": "./lib/commonjs/index.js"
17
+ }
18
+ }
19
+ },
20
+ "files": [
21
+ "src",
22
+ "lib",
23
+ "android",
24
+ "ios",
25
+ "cpp",
26
+ "*.podspec",
27
+ "!ios/build",
28
+ "!android/build",
29
+ "!android/gradle",
30
+ "!android/gradlew",
31
+ "!android/gradlew.bat",
32
+ "!android/local.properties",
33
+ "!**/__tests__",
34
+ "!**/__fixtures__",
35
+ "!**/__mocks__",
36
+ "!**/.*"
37
+ ],
38
+ "scripts": {
39
+ "example": "yarn workspace tyrads-sdk-example",
40
+ "test": "jest",
41
+ "typecheck": "tsc",
42
+ "lint": "eslint \"**/*.{js,ts,tsx}\"",
43
+ "clean": "del-cli android/build example/android/build example/android/app/build example/ios/build lib",
44
+ "prepare": "bob build",
45
+ "release": "release-it"
46
+ },
47
+ "keywords": [
48
+ "react-native",
49
+ "ios",
50
+ "android"
51
+ ],
52
+ "repository": {
53
+ "type": "git",
54
+ "url": "git+https://github.com/tyrads-com/tyrads-sdk-reactnative.git"
55
+ },
56
+ "author": "dev@acmo.in <dev@acmo.in> (https://tyrads.com)",
57
+ "license": " BSD-3-Clause",
58
+ "bugs": {
59
+ "url": "https://github.com/tyrads-com/tyrads-sdk-reactnative/issues"
60
+ },
61
+ "homepage": "https://github.com/tyrads-com/tyrads-sdk-reactnative#readme",
62
+ "publishConfig": {
63
+ "registry": "https://registry.npmjs.org/"
64
+ },
65
+ "devDependencies": {
66
+ "@commitlint/config-conventional": "^17.0.2",
67
+ "@evilmartians/lefthook": "^1.5.0",
68
+ "@react-native/eslint-config": "^0.73.1",
69
+ "@release-it/conventional-changelog": "^5.0.0",
70
+ "@types/jest": "^29.5.5",
71
+ "@types/react": "^18.2.44",
72
+ "commitlint": "^17.0.2",
73
+ "del-cli": "^5.1.0",
74
+ "eslint": "^8.51.0",
75
+ "eslint-config-prettier": "^9.0.0",
76
+ "eslint-plugin-prettier": "^5.0.1",
77
+ "jest": "^29.7.0",
78
+ "prettier": "^3.0.3",
79
+ "react": "18.2.0",
80
+ "react-native": "0.74.5",
81
+ "react-native-builder-bob": "^0.29.0",
82
+ "release-it": "^15.0.0",
83
+ "turbo": "^1.10.7",
84
+ "typescript": "^5.2.2"
85
+ },
86
+ "resolutions": {
87
+ "@types/react": "^18.2.44"
88
+ },
89
+ "peerDependencies": {
90
+ "react": "*",
91
+ "react-native": "*"
92
+ },
93
+ "workspaces": [
94
+ "example"
95
+ ],
96
+ "packageManager": "yarn@3.6.1",
97
+ "jest": {
98
+ "preset": "react-native",
99
+ "modulePathIgnorePatterns": [
100
+ "<rootDir>/example/node_modules",
101
+ "<rootDir>/lib/"
102
+ ]
103
+ },
104
+ "commitlint": {
105
+ "extends": [
106
+ "@commitlint/config-conventional"
107
+ ]
108
+ },
109
+ "release-it": {
110
+ "git": {
111
+ "commitMessage": "chore: release ${version}",
112
+ "tagName": "v${version}"
113
+ },
114
+ "npm": {
115
+ "publish": true
116
+ },
117
+ "github": {
118
+ "release": true
119
+ },
120
+ "plugins": {
121
+ "@release-it/conventional-changelog": {
122
+ "preset": "angular"
123
+ }
124
+ }
125
+ },
126
+ "eslintConfig": {
127
+ "root": true,
128
+ "extends": [
129
+ "@react-native",
130
+ "prettier"
131
+ ],
132
+ "rules": {
133
+ "react/react-in-jsx-scope": "off",
134
+ "prettier/prettier": [
135
+ "error",
136
+ {
137
+ "quoteProps": "consistent",
138
+ "singleQuote": true,
139
+ "tabWidth": 2,
140
+ "trailingComma": "es5",
141
+ "useTabs": false
142
+ }
143
+ ]
144
+ }
145
+ },
146
+ "eslintIgnore": [
147
+ "node_modules/",
148
+ "lib/"
149
+ ],
150
+ "prettier": {
151
+ "quoteProps": "consistent",
152
+ "singleQuote": true,
153
+ "tabWidth": 2,
154
+ "trailingComma": "es5",
155
+ "useTabs": false
156
+ },
157
+ "react-native-builder-bob": {
158
+ "source": "src",
159
+ "output": "lib",
160
+ "targets": [
161
+ [
162
+ "commonjs",
163
+ {
164
+ "esm": true
165
+ }
166
+ ],
167
+ [
168
+ "module",
169
+ {
170
+ "esm": true
171
+ }
172
+ ],
173
+ [
174
+ "typescript",
175
+ {
176
+ "project": "tsconfig.build.json",
177
+ "esm": true
178
+ }
179
+ ]
180
+ ]
181
+ },
182
+ "create-react-native-library": {
183
+ "type": "module-legacy",
184
+ "languages": "kotlin-swift",
185
+ "version": "0.40.0"
186
+ }
187
+ }
package/readme.md CHANGED
@@ -1,24 +1,24 @@
1
- # tyrads-sdk
2
-
3
- Tyrads SDK for React Native
4
-
5
- ## Installation
6
-
7
- ```sh
8
- npm install @tyrads.com/tyrads-sdk
9
- ```
10
-
11
- ## Usage
12
-
13
-
14
- ```js
15
- import Tyrads from '@tyrads.com/tyrads-sdk';
16
-
17
- // ...
18
-
19
-
20
- Tyrads.init('', '');
21
- Tyrads.loginUser('');
22
- Tyrads.showOffers();
23
- ```
24
-
1
+ # tyrads-sdk
2
+
3
+ Tyrads SDK for React Native
4
+
5
+ ## Installation
6
+
7
+ ```sh
8
+ npm install @tyrads.com/tyrads-sdk
9
+ ```
10
+
11
+ ## Usage
12
+
13
+
14
+ ```js
15
+ import Tyrads from '@tyrads.com/tyrads-sdk';
16
+
17
+ // ...
18
+
19
+
20
+ Tyrads.init('', '');
21
+ Tyrads.loginUser('');
22
+ Tyrads.showOffers();
23
+ ```
24
+
package/src/index.tsx CHANGED
@@ -1,19 +1,19 @@
1
- import { NativeModules, Platform } from 'react-native';
2
-
3
- const LINKING_ERROR =
4
- `The package 'tyrads-sdk' doesn't seem to be linked. Make sure: \n\n` +
5
- Platform.select({ ios: "- You have run 'pod install'\n", default: '' }) +
6
- '- You rebuilt the app after installing the package\n' +
7
- '- You are not using Expo Go\n';
8
-
9
- const Tyrads = NativeModules.TyradsSdk
10
- ? NativeModules.TyradsSdk
11
- : new Proxy(
12
- {},
13
- {
14
- get() {
15
- throw new Error(LINKING_ERROR);
16
- },
17
- }
18
- );
19
- export default Tyrads;
1
+ import { NativeModules, Platform } from 'react-native';
2
+
3
+ const LINKING_ERROR =
4
+ `The package 'tyrads-sdk' doesn't seem to be linked. Make sure: \n\n` +
5
+ Platform.select({ ios: "- You have run 'pod install'\n", default: '' }) +
6
+ '- You rebuilt the app after installing the package\n' +
7
+ '- You are not using Expo Go\n';
8
+
9
+ const Tyrads = NativeModules.TyradsSdk
10
+ ? NativeModules.TyradsSdk
11
+ : new Proxy(
12
+ {},
13
+ {
14
+ get() {
15
+ throw new Error(LINKING_ERROR);
16
+ },
17
+ }
18
+ );
19
+ export default Tyrads;
@@ -1,41 +1,41 @@
1
- require "json"
2
-
3
- package = JSON.parse(File.read(File.join(__dir__, "package.json")))
4
- folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'
5
-
6
- Pod::Spec.new do |s|
7
- s.name = "tyrads-sdk"
8
- s.version = package["version"]
9
- s.summary = package["description"]
10
- s.homepage = package["homepage"]
11
- s.license = package["license"]
12
- s.authors = package["author"]
13
-
14
- s.platforms = { :ios => min_ios_version_supported }
15
- s.source = { :git => "https://github.com/tyrads-com/tyrads-sdk-reactnative.git", :tag => "#{s.version}" }
16
-
17
- s.source_files = "ios/**/*.{h,m,mm,swift}"
18
-
19
- # Use install_modules_dependencies helper to install the dependencies if React Native version >=0.71.0.
20
- # See https://github.com/facebook/react-native/blob/febf6b7f33fdb4904669f99d795eba4c0f95d7bf/scripts/cocoapods/new_architecture.rb#L79.
21
- if respond_to?(:install_modules_dependencies, true)
22
- install_modules_dependencies(s)
23
- else
24
- s.dependency "React-Core"
25
-
26
- # Don't install the dependencies when we run `pod install` in the old architecture.
27
- if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
28
- s.compiler_flags = folly_compiler_flags + " -DRCT_NEW_ARCH_ENABLED=1"
29
- s.pod_target_xcconfig = {
30
- "HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\"",
31
- "OTHER_CPLUSPLUSFLAGS" => "-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1",
32
- "CLANG_CXX_LANGUAGE_STANDARD" => "c++17"
33
- }
34
- s.dependency "React-Codegen"
35
- s.dependency "RCT-Folly"
36
- s.dependency "RCTRequired"
37
- s.dependency "RCTTypeSafety"
38
- s.dependency "ReactCommon/turbomodule/core"
39
- end
40
- end
41
- end
1
+ require "json"
2
+
3
+ package = JSON.parse(File.read(File.join(__dir__, "package.json")))
4
+ folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'
5
+
6
+ Pod::Spec.new do |s|
7
+ s.name = "tyrads-sdk"
8
+ s.version = package["version"]
9
+ s.summary = package["description"]
10
+ s.homepage = package["homepage"]
11
+ s.license = package["license"]
12
+ s.authors = package["author"]
13
+
14
+ s.platforms = { :ios => min_ios_version_supported }
15
+ s.source = { :git => "https://github.com/tyrads-com/tyrads-sdk-reactnative.git", :tag => "#{s.version}" }
16
+
17
+ s.source_files = "ios/**/*.{h,m,mm,swift}"
18
+
19
+ # Use install_modules_dependencies helper to install the dependencies if React Native version >=0.71.0.
20
+ # See https://github.com/facebook/react-native/blob/febf6b7f33fdb4904669f99d795eba4c0f95d7bf/scripts/cocoapods/new_architecture.rb#L79.
21
+ if respond_to?(:install_modules_dependencies, true)
22
+ install_modules_dependencies(s)
23
+ else
24
+ s.dependency "React-Core"
25
+
26
+ # Don't install the dependencies when we run `pod install` in the old architecture.
27
+ if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
28
+ s.compiler_flags = folly_compiler_flags + " -DRCT_NEW_ARCH_ENABLED=1"
29
+ s.pod_target_xcconfig = {
30
+ "HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\"",
31
+ "OTHER_CPLUSPLUSFLAGS" => "-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1",
32
+ "CLANG_CXX_LANGUAGE_STANDARD" => "c++17"
33
+ }
34
+ s.dependency "React-Codegen"
35
+ s.dependency "RCT-Folly"
36
+ s.dependency "RCTRequired"
37
+ s.dependency "RCTTypeSafety"
38
+ s.dependency "ReactCommon/turbomodule/core"
39
+ end
40
+ end
41
+ end