esoftplay 0.0.130-e → 0.0.130-g

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.
@@ -0,0 +1,39 @@
1
+ // useLibs
2
+
3
+ import { runOnJS, runOnUI } from "react-native-reanimated";
4
+
5
+ export interface LibWorkerProps {
6
+
7
+ }
8
+
9
+ /*
10
+ const run = LibWorker((arg: any[], cb: (out: any) => void) => {
11
+ "worklet";
12
+ let out = 0
13
+ for (let i = 0; i < arg[0]; i++) {
14
+ out += i
15
+ }
16
+ cb(out)
17
+ })
18
+ run([99999999], res => {
19
+ setState(res)
20
+ })
21
+
22
+ */
23
+
24
+ export default function m(func: any): (args: any[], cb: (res: any) => void) => void {
25
+
26
+ return (args: any[], cb: (res: any) => void) => {
27
+ function callback(out: any) {
28
+ "worklet"
29
+ runOnJS(cb)(out)
30
+ }
31
+
32
+ function run() {
33
+ "worklet"
34
+ func(args, callback)
35
+ }
36
+
37
+ runOnUI(run)()
38
+ }
39
+ }
@@ -16,11 +16,11 @@ export default function m(defaultUrl?: string): void {
16
16
  url = url.replace((domain + uri), (domain + uri + 'deeplink/'))
17
17
  url = url.replace(/^[a-z]+\:\/\//g, protocol + "://")
18
18
  function removeLastDot(url: string) {
19
- if (url.substr(url.length - 1, 1) == '.') {
20
- url = url.substring(0, url.length - 1)
21
- return removeLastDot(url)
19
+ if (url.endsWith('.')) {
20
+ url = url.slice(0, -1);
21
+ return removeLastDot(url);
22
22
  }
23
- return url
23
+ return url;
24
24
  }
25
25
  new LibCurl().custom(removeLastDot(url), null,
26
26
  (res) => {
@@ -97,20 +97,9 @@ export default function m(props: UserIndexProps): any {
97
97
  }
98
98
  })
99
99
 
100
- if (esp.config('firebase').hasOwnProperty('apiKey')) {
101
- try {
102
- const Firestore = esp.mod('chatting/firestore')
103
- Firestore()?.init?.()
104
- if (user) {
105
- const ChattingLib = esp.mod('chatting/lib')
106
- ChattingLib().setUser()
107
- }
108
- } catch (error) {
109
-
110
- }
111
- }
112
100
  LibUpdaterProperty.check()
113
101
  }, [])
102
+ //esoftplay-chatting
114
103
 
115
104
  useEffect(() => {
116
105
  if (!loading) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "esoftplay",
3
- "version": "0.0.130-e",
3
+ "version": "0.0.130-g",
4
4
  "description": "embedding data from esoftplay framework (web based) into mobile app",
5
5
  "main": "cache/index.js",
6
6
  "types": "../../index.d.ts",