@expo-harmony/expo-app-metrics 0.2.2-harmony.1

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/README.md ADDED
@@ -0,0 +1,14 @@
1
+ # @expo-harmony/expo-app-metrics
2
+
3
+ [**GitHub 仓库**](https://github.com/renbaoshuo/expo-harmony/tree/master/packages/expo-app-metrics)
4
+
5
+ 为 HarmonyOS 上的 React Native 应用提供 Expo App Metrics 的原生实现,与官方同版本的 `expo-app-metrics` 配套使用。支持采集应用启动耗时、帧率指标和内存使用快照,并支持按会话记录指标、附加自定义指标以及读取和清空本地持久化的记录。启动耗时包括冷启动、暖启动、Bundle 加载、首次渲染和可交互时间;帧率指标包括渲染帧数、掉帧、慢帧、卡顿帧数和卡顿总时长。
6
+
7
+ 内存快照通过 HarmonyOS HiDebug 的异步接口读取,需要系统 API 版本 20 及以上。帧率指标基于系统帧回调统计,需要在 React Native UI 上下文就绪后才能获取。官方类型中标注为 Android 专属的会话 API(`startSession`、`stopSession`、`addCustomMetricToSession`)在 HarmonyOS 上同样可用。
8
+
9
+ ## Author
10
+
11
+ **expo-harmony** © [Baoshuo](https://github.com/renbaoshuo), Released under the MIT License.<br>
12
+ Authored and maintained by Baoshuo with help from [contributors](https://github.com/renbaoshuo/expo-harmony/contributors).
13
+
14
+ > [Personal Website](https://baoshuo.ren) · [Blog](https://blog.baoshuo.ren) · GitHub [@renbaoshuo](https://github.com/renbaoshuo) · Twitter [@baoshuo](https://twitter.com/baoshuo)
@@ -0,0 +1,6 @@
1
+ {
2
+ "platforms": ["harmony"],
3
+ "harmony": {
4
+ "modules": ["ExpoAppMetricsModule"]
5
+ }
6
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "name": "@expo-harmony/expo-app-metrics",
3
+ "version": "0.2.2-harmony.1",
4
+ "keywords": [
5
+ "react-native",
6
+ "expo",
7
+ "expo-harmony",
8
+ "harmonyos"
9
+ ],
10
+ "homepage": "https://github.com/renbaoshuo/expo-harmony/tree/master/packages/expo-app-metrics#readme",
11
+ "repository": "https://github.com/renbaoshuo/expo-harmony",
12
+ "author": {
13
+ "name": "Baoshuo",
14
+ "email": "i@baoshuo.ren",
15
+ "url": "https://github.com/renbaoshuo"
16
+ },
17
+ "description": "HarmonyOS native implementation for expo-app-metrics",
18
+ "main": "Index.ets",
19
+ "license": "MIT",
20
+ "dependencies": {
21
+ "@expo-harmony/expo-modules-core": "55.0.25-harmony.1"
22
+ }
23
+ }
Binary file
package/index.d.ts ADDED
@@ -0,0 +1 @@
1
+ export {};
package/index.js ADDED
@@ -0,0 +1,3 @@
1
+ 'use strict';
2
+
3
+ module.exports = Object.freeze({});
package/package.json ADDED
@@ -0,0 +1,47 @@
1
+ {
2
+ "name": "@expo-harmony/expo-app-metrics",
3
+ "version": "0.2.2-harmony.1",
4
+ "description": "HarmonyOS port of expo-app-metrics",
5
+ "keywords": [
6
+ "react-native",
7
+ "expo",
8
+ "expo-harmony",
9
+ "harmonyos"
10
+ ],
11
+ "license": "MIT",
12
+ "author": "Baoshuo <i@baoshuo.ren>",
13
+ "repository": {
14
+ "type": "git",
15
+ "url": "git+https://github.com/renbaoshuo/expo-harmony.git",
16
+ "directory": "packages/expo-app-metrics"
17
+ },
18
+ "homepage": "https://github.com/renbaoshuo/expo-harmony/tree/master/packages/expo-app-metrics#readme",
19
+ "bugs": "https://github.com/renbaoshuo/expo-harmony/issues",
20
+ "main": "index.js",
21
+ "types": "index.d.ts",
22
+ "scripts": {
23
+ "harmony:clean": "expo-harmony-module prepare --clean-only",
24
+ "harmony:build": "expo-harmony-module prepare",
25
+ "prepack": "expo-harmony-module prepack"
26
+ },
27
+ "peerDependencies": {
28
+ "@expo-harmony/expo-modules-core": "55.0.25-harmony.1",
29
+ "expo-app-metrics": "0.2.2"
30
+ },
31
+ "devDependencies": {
32
+ "@expo-harmony/expo-module-scripts": "55.0.0-harmony.0",
33
+ "@expo-harmony/expo-modules-core": "55.0.25-harmony.1",
34
+ "@react-native-oh/react-native-harmony": "0.84.1",
35
+ "expo": "55.0.26",
36
+ "expo-app-metrics": "0.2.2",
37
+ "expo-modules-core": "55.0.25",
38
+ "react": "19.2.3",
39
+ "react-native": "0.84.1"
40
+ },
41
+ "engines": {
42
+ "node": ">=20"
43
+ },
44
+ "publishConfig": {
45
+ "access": "public"
46
+ }
47
+ }