React Native鸿蒙化仓库
| Files | Last commit | Last update |
|---|---|---|
docs(Docs): fix audit findings and complete English translations Fix the issues found by the documentation audit and complete the English translations: repair broken relative links, Chinese punctuation in English prose and wrong anchor casing across the documentation tree; rename files and directories whose names contained spaces to follow the naming rule; complete the missing English translations for mixed-language docs; add alt text to content figures; align skill names in .agents docs with the actual directories; protect the autolinking naming rule rnoh__+[org name]+[package name] and its example with backticks so prettier keeps the underscores; fix the column count of the stability table in the zh-cn operations README. Restore the TurboModule list-item indentation and code fences, align its native-code examples with the Chinese version, and replace the FCP trace and PGO process figures with English versions. Pin the React Native documentation links in the multi-screen adaptation guide to version 0.86. Point the Huawei developer portal links in the contribution guide at the English portal. Restore the flowchart column alignment in the AI diagnosis guide and quote the HSP image URI in the scenario examples. Fix the unclosed deprecated superscript tags in the API description headings. Add the missing useEffect dependency array in the multi-screen adaptation example. Sync the Codegen guide with the Chinese version: deprecation marker, ets output path parameter, and overwrite notice. Impact: documentation only; no source code is touched. Closes #3572 AI[100%] Human Fixed[0%] Human[0%] AI Adopted[99%] Signed-off-by: 焦舒畅 <18327003767@163.com> Co-authored-by: codex (gpt-5.6-sol) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> | 17 days ago | |
chore(Docs): RNOH社区规范文档调整,以及提供对应模板文件 1、RNOH社区规范文档调整 2、配套规范提供对应模板文件 3、tester直接依赖源码编译,需要在entry做debug和release区分 Signed-off-by: gyange <gyange@163.com> | 7 months ago | |
chore(Upgrade): bump RNOH to RN 0.88.1 Align RNOH packages, samples, docs, and third-party hermes gitlink (9a115f157) with upstream React Native 0.88.1. Resolve CodeCheck gate failures for non-upstream files: - SampleComponent: use single quotes for string literals (G.TYP.04) - NetworkingTest: extract helpers to reduce getTestCase size - Add sample-package .prettierrc.js with Huawei MIT header (2026) Signed-off-by: changlp <chang_leipeng@hoperun.com> | 2 days ago | |
refactor: integrate quality-toolkit — full quality engineering stack Replace all self-hosted quality tooling with the quality-toolkit submodule (standards + skills + tools, 185 rules, 62-scenario self-verification suite). Single atomic commit; detailed history in the toolkit repo. Compliance harness: - .quality-toolkit submodule (HTTPS) + .quality/harness.config.json - 185-rule catalog with dependency gating; CI gate via --commit-range Commit enforcement: - commitlint rnoh preset with rnoh-tests-required rule - .githooks: commitlint + gitleaks + lint-staged after business checks Issue/PR automation: - tools/submit, tools/create-issue, tools/generate-branch-pr, tools/platform-api (gitcode/gitee/atomgit/github) Static analysis + multi-branch submit (restored from RNOH): - tools/static-check: 782-line multi-language engine - tools/submit-prs: 606-line Python multi-branch automation Skills structure: - .agents/skills/ → mixed: toolkit skills via symlinks (13 generic) + RNOH-local skills (arkts-test, rnoh-upgrade) - arkts-test moved from toolkit (HarmonyOS-specific) - rnoh-upgrade created from upgrade-version Part B+C (RNOH-specific) Testing: - packages/rnoh_test: CPTF E2E suite (submodule, HTTPS) - .opencode/agent/: 13 agents from toolkit + 2 RNOH-local skills Scripts replaced: all self-hosted quality scripts → toolkit equivalents (check_includes, integrate-upstream-code, package-trim, verify-docs, format-cpp, gitleaks, bump-version, gtest-*, patch-react-native) Impact: pnpm init-ws works without SSH keys; pnpm harness exit 0; pnpm submit --create-issue --yes creates issue + PR + linkage. test case: toolkit 62-scenario suite + gtest:quality 2983 tests + live Issue/PR creation on CPTF fork Signed-off-by: gyange <gaoyang36@huawei.com> AI[100%] Human Fixed[0%] Human[0%] AI Adopted[100%] Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> | 2 months ago | |
chore(Config): drop the repo-level fork owner declaration per review The remote.fork block added in b9b453f0b hardcodes a personal fork into a config file shared by every contributor of the upstream repository. resolveFork treats remoteConfig.fork as the highest-priority fork source, so non-owner contributors running generate-branch-pr would be directed to a fork they cannot push to (remote-add then 403, or the owner/repo validation exits early). The submit workflow is unaffected (it does not pass remoteConfig), but the declaration was added for generate-branch-pr in the first place, so it cannot stay. Keep only the remote.origin label (local origin plays upstream — documentation only, no code consumes it) and let fork resolution fall back to the per-user chain: local fork remote, GBR_FORK_OWNER / GBR_FORK_REMOTE env, API fork detection (and fork auto-creation when enabled). Every contributor resolves their own fork that way. Impact: harness config only. The equivalent declarations on rnoh_test and CPTF carry the same latent flaw for other contributors; follow-ups proposed separately (config removal there, plus a per-user placeholder mechanism in the toolkit as the systemic fix). Signed-off-by: gyange <gaoyang36@huawei.com> | 1 month ago | |
!4059 merge 0.88-preview into 0.88-preview docs(文档): 同步双语文档至 RNOH 0.88.1 Created-by: changlp Commit-by: changlp Merged-by: openharmony_ci Description: ## 变更类型 请在对应类型前打 √,仅可选择一项: - [ ] feat(新增功能,对应 Changelog Added) - [ ] fix(修复 Bug,对应 Changelog Fixed) - [x] docs(文档变更,对应 Changelog Documentation) - [ ] refactor(代码重构,对应 Changelog Changed) - [ ] perf(性能优化,对应 Changelog Performance) - [ ] test(测试相关) - [ ] chore(构建/工具链/依赖) - [ ] deprecated(标记弃用,对应 Changelog Deprecated) - [ ] removed(移除功能,对应 Changelog Removed) - [ ] security(安全修复,对应 Changelog Security) - [ ] revert(回滚) ## 变更 Scope - [ ] 基础组件(View, Text, Image, ScrollView等) - [ ] 布局组件(Flex, Absolute, SafeArea等) - [ ] API模块(Networking, Storage, Permissions等) - [ ] 动画系统(Animated, Reanimated, GestureHandler等) - [ ] 导航(Navigation, StackNavigator等) - [ ] 样式系统(StyleSheet, Theme等) - [ ] 桥接层(Bridge, TurboModules, Fabric等) - [ ] JS引擎(Hermes, JSC, JSI, JSVM等) - [ ] 构建系统(BuildSystem, CMake, HAP, HAR, Symbols等) - [ ] 开发工具(DevTools, Debugger, Profiler等) - [ ] 测试(Tests, E2E, UnitTests) - [x] 其他(Docs, Examples, Config, CLI, Scripts等) ## 变更内容 - 将环境搭建、版本升级指导、roadmap、稳定版本识别、Release Notes 等中英文文档对齐到 RNOH / RN 0.88.1 - 新增 v0.88.1 Release Notes(中/英),并在中文版本说明索引中保留 0.86 条目 - 修正 release 包相关 CMake 头文件路径说明(include),补充编译类 FAQ 中第三方头文件缺失的处理指引 - 同步 AGENTS.md / README 中的 Node、React、React Native 版本信息 兼容性:纯文档变更,不影响运行时 API / Native / 符号。 ## RNOH 特殊说明 - [ ] Symbols变更(说明符号处理情况) - [ ] Native层变更(说明符号处理和.so文件影响) - [ ] 构建系统变更(说明对Debug/Release模式的影响) - [ ] 组件变更(说明兼容性和API变化) Native层变更说明: - 无 组件变更说明: - 无 ## 关联 Issue 已关联 #3712。 ## 测试情况 - [ ] 已通过本地完整测试(单元测试/集成测试) - [ ] 已通过 CI 自动构建与测试 - [ ] 已补充/更新对应的测试用例 - [ ] 已在目标环境(HarmonyOS设备/模拟器)验证功能 - [x] 已对变更文档做相对链接抽查,并核对 release2 HAR 的 include / react-native-harmony.cmake 路径 ## 检查项 - [x] 代码符合项目编码规范 - [x] 已更新相关文档(若涉及功能变更) - [x] 无敏感信息泄露 - [ ] 已同步更新 Changelog(可选,建议随 PR 同步更新 [Unreleased] 区块) - [x] Commit 信息符合规范(包含正确的 type 和 scope) See merge request: CPF-RN/ohos_react_native!4059 | 1 day ago | |
feat(Text): apply fontVariationSettings on Text and degrade 'wght' on TextInput RN 0.88 adds fontVariationSettings to Text and TextInput alike. The JS layer serializes the object form into a CSS-like string that the native side receives through TextAttributes::fontVariationSettings. - New shared FontVariationSettingsParser.{h,cpp}: tolerant regex parser (quote style, spacing, sign/exponent; malformed pairs are skipped instead of throwing). Uses static regex and strtof so out-of-range values are skipped rather than propagating an exception. - Text side (StyledStringWrapper): parse the string and call OH_Drawing_TextStyleAddFontVariation per pair (@since 12); axes unsupported by the font or API level are silently ignored by OH, matching upstream semantics. - TextInput/TextArea side (TextInputNodeBase): ArkUI exposes no input-side font-variation API at any released level (verified against the API 20/21/24/26 SDKs), so the 'wght' axis degrades onto the discrete NODE_FONT_WEIGHT buckets (nearest hundred, clamped to 100..900), applied after fontWeight so the axis overrides it, matching CSS precedence; other axes stay silently ignored. - Tester demo: FontVariationSettingsTest page (reference / wght 300/900 / string-vs-object syntax / unsupported axis on Text; wght degradation rows on TextInput), registered in the tester suite list. - clang-format the four C++ files touched by this feature so the cpp-formatting verify lane stays clean. Impact scope: Text rendering with a fontVariationSettings style and TextInput/TextArea with a 'wght' axis; non-wght axes and plain fontWeight semantics are not affected. Host gtest prerequisites: mockGetAttributeI32 accessor, TextAttributes stub sync with the 0.88 member, <mutex> include for DynamicArkUILoader, the SHELL:-include fix in configure_arkui_sdk_headers and the sysroot include path fix for rnoh_textinput_node_test. Parser unit tests link the production parser directly (no extracted copy). Tests: gtest rnoh_textinput_node_test 435/435 (5 new SetFont_*Wght*/Slnt cases) and rnoh_text_test (8 ParseFontVariationSettings cases including OutOfRange_Skipped) on host with the API 26 SDK; tester debug HAP (arm64-v8a) built from the 0.88.1 sources with the demo suite packed in the bundle. Signed-off-by: changlp <chang_leipeng@hoperun.com> | 1 day ago | |
chore(Upgrade): guard the preset plugin shape and extract install hooks to files Two follow-ups from MR review: commitlint.config.js merged the toolkit preset's plugin rules into this repo's single inline-plugin slot via preset.plugins[0].rules. That silently degrades to {} if the toolkit ever splits its rules across several plugins or moves them off the first one — the preset rules would drop out of the overlay with no error. Surface both structural breaks now: warn when the preset does not expose exactly one plugin object, and warn when the extracted rule set comes back empty. Both warnings name the pinned toolkit version so the drift is diagnosable. preinstall and _setup:husky were two inline node -e one-liners of very different length. Extract both into scripts/ as plain readable files and point the package.json entries at them — identical behavior (warn-only submodule self-heal, pnpm version gate when the toolkit is present, hooks/template git config), with the warn texts normalized to English to match the repo's all-English posture. Smoke-tested on this checkout: the gate runs, the git config stays idempotent, and the commitlint overlay still carries the full preset rule set plus body-english. Signed-off-by: gyange <gaoyang36@huawei.com> | 1 month ago | |
chore(Upgrade): bump RNOH to RN 0.88.1 Align RNOH packages, samples, docs, and third-party hermes gitlink (9a115f157) with upstream React Native 0.88.1. Resolve CodeCheck gate failures for non-upstream files: - SampleComponent: use single quotes for string literals (G.TYP.04) - NetworkingTest: extract helpers to reduce getTestCase size - Add sample-package .prettierrc.js with Huawei MIT header (2026) Signed-off-by: changlp <chang_leipeng@hoperun.com> | 2 days ago | |
chore: add license scanning config, change some licence headers # message auto-generated for no-merge-commit merge: merge license into 0.77.1-rc.1-ohos chore: add license scanning config, change some licence headers Created-by: linhandev Commit-by: linhandev Merged-by: huangyouhua Description: ## Why are these changes being made? - Add license header scanning config. Without that oat config codecheck task in start build would fail while adding new source code file. - Config files don't usually get license headers, but since clang configs takes comments, I'd like to add license headers in them to be on the safe side. pnpm verify and format both works after this change. - Our jsvm related code license header is referencing non existing LICENSE-MIT file, changed that to LICENSE - RNTypes.ts is mainly copied from upstream, it should use meta's license ## Changelog ## Test Plan Add a new source code file with hw license header, ci should pass ## Checklist - [x] pnpm verify command has passed successfully. ~~- [ ] No failures occurred in automatic tests on the CONCURRENT TESTER page in the tester app.~~ ~~- [ ] No failures occurred in automatic tests on the SEQUENTIAL TESTER page in the tester app.~~ - [x] MR does not include a breaking change or a review has been requested from a Huawei reviewer. See merge request: openharmony-sig/ohos_react_native!862 | 1 year ago | |
chore: add license scanning config, change some licence headers # message auto-generated for no-merge-commit merge: merge license into 0.77.1-rc.1-ohos chore: add license scanning config, change some licence headers Created-by: linhandev Commit-by: linhandev Merged-by: huangyouhua Description: ## Why are these changes being made? - Add license header scanning config. Without that oat config codecheck task in start build would fail while adding new source code file. - Config files don't usually get license headers, but since clang configs takes comments, I'd like to add license headers in them to be on the safe side. pnpm verify and format both works after this change. - Our jsvm related code license header is referencing non existing LICENSE-MIT file, changed that to LICENSE - RNTypes.ts is mainly copied from upstream, it should use meta's license ## Changelog ## Test Plan Add a new source code file with hw license header, ci should pass ## Checklist - [x] pnpm verify command has passed successfully. ~~- [ ] No failures occurred in automatic tests on the CONCURRENT TESTER page in the tester app.~~ ~~- [ ] No failures occurred in automatic tests on the SEQUENTIAL TESTER page in the tester app.~~ - [x] MR does not include a breaking change or a review has been requested from a Huawei reviewer. See merge request: openharmony-sig/ohos_react_native!862 | 1 year ago | |
docs(Docs): fix bilingual alignment, broken links, and code samples in en/zh-cn docs - align EN/ZH content: rewrite the ContentSlot access section in architecture, add missing sections and sentences (stability, usage-faqs, custom-components, common scenarios, performance, environment-setup, TurboModule), and add the ArkTS-in-C-API section to the zh-cn hybrid-solution guide - fix terminology and code samples: hermescOptions type, onForeground casing, module.json5, Metro config formatting, emitComponentEvent arguments, CMake option comments, and the Woker typo - fix broken links and switch to language-specific targets: stability coding standards, DevEco release notes, trace optimization guides, Smartperf-Host, sample indexes, and sample READMEs - add the ContentSlot access figure and the EN gtest guide/module catalog - update figure files and localize figure references - extend the cspell dictionary and fix code sample errors found in review Signed-off-by: 焦舒畅 <18327003767@163.com> | 9 days ago | |
chore(Upgrade): bump RNOH to RN 0.88.1 Align RNOH packages, samples, docs, and third-party hermes gitlink (9a115f157) with upstream React Native 0.88.1. Resolve CodeCheck gate failures for non-upstream files: - SampleComponent: use single quotes for string literals (G.TYP.04) - NetworkingTest: extract helpers to reduce getTestCase size - Add sample-package .prettierrc.js with Huawei MIT header (2026) Signed-off-by: changlp <chang_leipeng@hoperun.com> | 2 days ago | |
test(UnitTests): fix P8 violations + rnoh_text_test build + coverage improvements P8 fixes (7 files from review 3c1f328ce): - TaskExecutorTest.cpp: replaced enum re-declaration with #include "TaskExecutor.h" - CharToByteIndexTest.cpp: extracted charToByteIndex to CharToByteIndexImpl.cpp, removed "Inlined" marker - StyledStringHelpersTest.cpp: extracted 4 helpers to StyledStringHelpersImpl.cpp, removed "Inlined" marker - TextConversionsTest.cpp: false positive (no P8 marker, already links real .cpp) - ArkUINodeVtableTest.cpp: false positive (no P8 marker, uses real SDK headers) - StackNodeVtableTest.cpp: false positive (no P8 marker, uses real SDK headers) - ArkUIConversionsTest.cpp: false positive (#include real conversions.h) Build fixes: - rnoh_text_test: fixed memory_order circular dependency (pthread.h stub → <string> → <algorithm> → <memory> → shared_ptr.h) - pthread.h: replaced std::string with char[] (avoids <string> include during <atomic> processing) - pthread.h: added #include_next for macOS (uses real system pthread, adds test-only helpers) - pthread.h: added missing types (pthread_once_t, pthread_key_t, etc.) and functions - ReactPrimitives.h stub: added #include <atomic> before <memory> - ShadowNode.h stub: added #include <atomic> before <memory> - TextAttributes.h stub: added #include for Color.h and Geometry.h (SharedColor, Size) - std_compat.h: moved <atomic> before <algorithm> (prevents boyer_moore_searcher.h → <memory> cycle) - CMakeLists.txt: removed duplicate rnoh_arkjs_test target - CMakeLists.txt: added CharToByteIndexImpl.cpp and StyledStringHelpersImpl.cpp to targets - CMakeLists.txt: added include paths for rnoh_task_test (TaskExecutor.h) - Restored text_conversions_test/folly/dynamic.h stub (needed to shadow real folly) gtest-coverage-check.js 脚本数据(llvm-cov 动态采集): Text 组件(rnoh_text_test, 104 用例 PASS): - TextConversions.cpp: Line 93.3% (279/299) | Branch 89.4% (118/132) GREEN - 模块合计: Branch 89.4% (118/132) ArkUI 节点基础设施(合并 rnoh_textinput_conv_test + rnoh_textinput_node_test + all-targets): - conversions.h: Line 97.6% (280/287) | Branch 98.6% (205/208) GREEN - ArkUINode.cpp: Line 30.5% (297/975) | Branch 14.7% (23/156) RED - NativeNodeApi.cpp: Line 71.4% (10/14) | Branch 66.7% (4/6) GREEN - NodeApi.h: Line 50.0% (10/20) | Branch 75.0% (3/4) YELLOW - ArkUINode.h: Line 25.0% (5/20) | Branch 50.0% (2/4) YELLOW - NativeNodeApi.h: Line 0.0% (0/1) | Branch — (无分支) - 模块合计: Branch 62.7% (237/378) ArkUI 节点子类(rnoh_textinput_node_test, 104 用例 PASS): - TextInputNode.cpp: Line 52.7% (202/383) | Branch 22.0% (22/100) YELLOW - TextAreaNode.cpp: Line 17.4% (66/379) | Branch 8.3% (11/132) RED - TextInputNodeBase.cpp: Line 46.4% (155/334) | Branch 29.5% (49/166) RED - 模块合计: Line 29.8% | Branch 19.0% RED 任务调度(rnoh_task_runner_test, 11 用例 PASS): - EventLoopTaskRunner.cpp: Line 86.7% (183/211) | Branch 60.0% (18/30) GREEN - ThreadTaskRunner.cpp: Line 95.1% (58/61) | Branch — (无分支) - Timer.cpp: Line 82.5% (33/40) | Branch 100.0% (2/2) GREEN - 模块合计: Line 88.0% | Branch 61.8% (21/34) GREEN JSI/Napi 桥接(rnoh_arkjs_test, 108 用例 PASS): - ArkJS.cpp: Line 68.3% (407/596) | Branch 69.2% (54/78) YELLOW - JsiConversions.cpp: Line 50.7% (35/69) | Branch 66.7% (24/36) YELLOW - 模块合计: Branch 67.8% (78/114) YELLOW JSI/Napi 桥接分支覆盖率从 50.0% 提升至 67.8%(ArkJS.cpp 从 44.9% → 69.2%) ArkUI 节点子类分支覆盖率仍为 19.0% RED(TextInputNode/TextAreaNode/TextInputNodeBase 需 RNOH_BUILD_INCOMPLETE_STUB_TARGETS 才能编译,后续待 stub 完善) Signed-off-by: huangyirong <huangyirong1@h-partners.com> AI[9%] Human Fixed[0%] Human[91%] AI Adopted[100%] Signed-off-by: huangyirong <huangyirong1@h-partners.com> | 3 months ago | |
chore(Config): enforce English subject and require impact description in commitlint - Add rnoh-subject-english rule: block Chinese characters in subject (error level) - Add rnoh-impact-required rule: warn when feat/fix/etc lacks impact description - Register all 10 plugin rules in rules section (was missing, causing them not to execute) - Fix plugin rule return format: [false, msg] instead of [2, msg] - Remove eslint from root lint-staged (no root eslintrc) - Add gitcode/gitmessage to cspell dictionary impact: all commitlint rules and pre-commit pipeline Signed-off-by: gyange <gyange@163.com> | 5 months ago | |
refactor: integrate quality-toolkit — full quality engineering stack Replace all self-hosted quality tooling with the quality-toolkit submodule (standards + skills + tools, 185 rules, 62-scenario self-verification suite). Single atomic commit; detailed history in the toolkit repo. Compliance harness: - .quality-toolkit submodule (HTTPS) + .quality/harness.config.json - 185-rule catalog with dependency gating; CI gate via --commit-range Commit enforcement: - commitlint rnoh preset with rnoh-tests-required rule - .githooks: commitlint + gitleaks + lint-staged after business checks Issue/PR automation: - tools/submit, tools/create-issue, tools/generate-branch-pr, tools/platform-api (gitcode/gitee/atomgit/github) Static analysis + multi-branch submit (restored from RNOH): - tools/static-check: 782-line multi-language engine - tools/submit-prs: 606-line Python multi-branch automation Skills structure: - .agents/skills/ → mixed: toolkit skills via symlinks (13 generic) + RNOH-local skills (arkts-test, rnoh-upgrade) - arkts-test moved from toolkit (HarmonyOS-specific) - rnoh-upgrade created from upgrade-version Part B+C (RNOH-specific) Testing: - packages/rnoh_test: CPTF E2E suite (submodule, HTTPS) - .opencode/agent/: 13 agents from toolkit + 2 RNOH-local skills Scripts replaced: all self-hosted quality scripts → toolkit equivalents (check_includes, integrate-upstream-code, package-trim, verify-docs, format-cpp, gitleaks, bump-version, gtest-*, patch-react-native) Impact: pnpm init-ws works without SSH keys; pnpm harness exit 0; pnpm submit --create-issue --yes creates issue + PR + linkage. test case: toolkit 62-scenario suite + gtest:quality 2983 tests + live Issue/PR creation on CPTF fork Signed-off-by: gyange <gaoyang36@huawei.com> AI[100%] Human Fixed[0%] Human[0%] AI Adopted[100%] Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> | 2 months ago | |
feat(Upgrade): Upgrade React Native version to 0.86.2 影响范围: - Upgrade React Native version to 0.86.2 Closes #2676 Signed-off-by: fangyygw <fang_zhen@hoperun.com> 请在对应类型(请勿多选)前打 √,**仅可选择一项**: - [ ] feat(新增功能,对应 Changelog Added) - [ ] fix(修复 Bug,对应 Changelog Fixed) - [ ] docs(文档变更,对应 Changelog Documentation) - [ ] refactor(代码重构,对应 Changelog Changed) - [ ] perf(性能优化,对应 Changelog Performance) - [ ] test(测试相关,不进入 Changelog) - [ ] chore(构建/工具链/依赖,不进入 Changelog) - [ ] deprecated(标记弃用,对应 Changelog Deprecated) - [ ] removed(移除功能,对应 Changelog Removed) - [ ] security(安全修复,对应 Changelog Security) - 简要描述本次变更的具体内容、解决的问题; - 若为**破坏性变更**,请详细说明: - 影响范围(哪些 API/配置/功能被修改); - 用户适配方案(旧版→新版的替换步骤) <!-- 如何测试这条PR。例如: 1. 打开Tester工程. 2. 执行npm run start命令. ... --> - [ ] 已通过本地完整测试(单元测试/集成测试) - [ ] 已通过 CI 自动构建与测试 - [ ] 已补充/更新对应的测试用例 - [ ] 已在目标环境(如 手机/平板)验证功能 - [ ] 已在最低兼容API版本验证可用性 <!-- 请在合入前根据以下条例进行自检 自检完成后在[ ]内填入"x", 例如: - [x] 不涉及非兼容性变更;若涉及,已通过相应评审。 --> - [ ] 不涉及非兼容性变更;若涉及,已通过相应评审。 - [ ] 不涉及性能或已进行性能测试且无性能劣化。 - [ ] 符合对应的编码规范。 - [ ] 无敏感信息泄露,如密码、密钥等。 - [ ] 不涉及文档更新,或已更新了文档。 - [ ] 针对可测试性要求,已增加必要的自测用例、合理的日志记录或Trace信息。 - [ ] 不存在非法的文件引入,包括图片和代码等 See merge request: fangyygw/ohos_react_native_clp!10 | 3 months ago | |
chore: Init RNOH Interop 61 Project Co-authored-by: Arkadiusz Kasprzyk<arkadiusz.kasprzyk@swmansion.com> # message auto-generated for no-merge-commit merge: merge kas/interop-tester-package into 0.77.1-rc.1-ohos chore: Init RNOH Interop 61 Project Created-by: arkadiuszkasprzyk Commit-by: Arkadiusz Kasprzyk Merged-by: huangyouhua Description: ## Description RNOH Interop 61 Project aims to support RN 61 API so that legacy projects can adopt RNOH without updating their projects on Android and iOS to the new architecture. RNOH Interop 61 package will use the latest RNOH under the hood. This MR adds 2 new packages to monorepo. Tester package also proves that a code can be shared between 2 NPM projects. ## Changes ## Test Plan Run the tester project according to packages/react-native-harmony-61-interop-tester/README.md. ## Checklist - [x] Does not involve incompatible changes; if involved, has been reviewed accordingly. - [x] Does not impact performance, or performance testing has been conducted without degradation. - [x] Complies with the relevant coding standards. - [x] Does not involve documentation updates, or the documentation has been updated. - [x] Meets testability requirements with necessary self-test cases, appropriate logging, or trace information added. - [x] No illegal file inclusions exist, such as images or code. See merge request: openharmony-sig/ohos_react_native!1334 | 1 year ago | |
chore(Upgrade): approve dependency build scripts and migrate pnpm config for v11 The CI pnpm install fails under pnpm 11 with ERR_PNPM_IGNORED_BUILDS for @swc/core and sqlite3 — pnpm 11 turned unapproved dependency build scripts from a warning into an exit-1 failure (reproduced locally with pnpm 11.21.0: a control install exits 1 with the same error, adding allowBuilds exits 0 and the builds run). pnpm 11 also no longer reads pnpm-specific settings from .npmrc, so node-linker=hoisted was silently dropped and the install fell back to the default isolated linker (verified: pnpm config get node-linker answers undefined when only .npmrc carries it). - pnpm-workspace.yaml: allowBuilds approval for @swc/core (transitive via ts-node; postinstall fetches the platform binding) and sqlite3 (direct dep of packages/tester; postinstall fetch/builds the native binding) - pnpm-workspace.yaml: nodeLinker hoisted + packageManagerStrict(+Version) + managePackageManagerVersions migrated from .npmrc - .npmrc: registry/auth lines stay (npm-compatible settings keep the .npmrc domain) Impact: build toolchain config only, no source or test code. Lockfile untouched (CI re-resolves; regeneration stays a separate follow-up). Signed-off-by: gyange <gaoyang36@huawei.com> | 1 month ago | |
feat(Upgrade): Upgrade React Native version to 0.86.2 影响范围: - Upgrade React Native version to 0.86.2 Closes #2676 Signed-off-by: fangyygw <fang_zhen@hoperun.com> | 3 months ago | |
refactor: integrate quality-toolkit — full quality engineering stack Replace all self-hosted quality tooling with the quality-toolkit submodule (standards + skills + tools, 185 rules, 62-scenario self-verification suite). Single atomic commit; detailed history in the toolkit repo. Compliance harness: - .quality-toolkit submodule (HTTPS) + .quality/harness.config.json - 185-rule catalog with dependency gating; CI gate via --commit-range Commit enforcement: - commitlint rnoh preset with rnoh-tests-required rule - .githooks: commitlint + gitleaks + lint-staged after business checks Issue/PR automation: - tools/submit, tools/create-issue, tools/generate-branch-pr, tools/platform-api (gitcode/gitee/atomgit/github) Static analysis + multi-branch submit (restored from RNOH): - tools/static-check: 782-line multi-language engine - tools/submit-prs: 606-line Python multi-branch automation Skills structure: - .agents/skills/ → mixed: toolkit skills via symlinks (13 generic) + RNOH-local skills (arkts-test, rnoh-upgrade) - arkts-test moved from toolkit (HarmonyOS-specific) - rnoh-upgrade created from upgrade-version Part B+C (RNOH-specific) Testing: - packages/rnoh_test: CPTF E2E suite (submodule, HTTPS) - .opencode/agent/: 13 agents from toolkit + 2 RNOH-local skills Scripts replaced: all self-hosted quality scripts → toolkit equivalents (check_includes, integrate-upstream-code, package-trim, verify-docs, format-cpp, gitleaks, bump-version, gtest-*, patch-react-native) Impact: pnpm init-ws works without SSH keys; pnpm harness exit 0; pnpm submit --create-issue --yes creates issue + PR + linkage. test case: toolkit 62-scenario suite + gtest:quality 2983 tests + live Issue/PR creation on CPTF fork Signed-off-by: gyange <gaoyang36@huawei.com> AI[100%] Human Fixed[0%] Human[0%] AI Adopted[100%] Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> | 2 months ago | |
docs(Docs): update bilingual docs for RNOH 0.88.1 Align setup, upgrade, roadmap, and release notes with RN 0.88.1. Fix release CMake include path and release HAR header guidance. Record separate release and release2 symbol archives with the BuildIDs from that build. Keep roadmap/stable-version tables aligned with real branches and npm tags. Signed-off-by: changlp <chang_leipeng@hoperun.com> | 1 day ago | |
chore(Upgrade): bump version to 0.86.2 and update release notes Signed-off-by: changlp <chang_leipeng@hoperun.com> | 26 days ago | |
docs: 新增社区开发规范 Co-authored-by: gyange<gyange@163.com> | 7 months ago | |
chore: add Huawei Technologies copyright and update NOTICE.md ## Summary This PR adds licenses and notices from gitee repo added by Huawei and combines it with our repo. It's better to have more legal mumbo jumbo than less. Related https://gl.swmansion.com/rnoh/react-native-harmony/-/issues/1425 See merge request rnoh/react-native-harmony!1727 Signed-off-by: huangyouhua <1356795413@qq.com> | 1 year ago | |
Chore: add RNTester from upstream repo Co-authored-by: Przemysław Sosna<przemyslaw.sosna@swmansion.com> # message auto-generated for no-merge-commit merge: merge @sosen/official-tester into 0.77.1-rc.1-ohos Chore: add RNTester from upstream repo Created-by: PrzemekSosna Commit-by: Przemysław Sosna Merged-by: huangyouhua Description: ## Description This adds the official RNTester from the upstream repo. ## Changes - added official RNTester for purposes of 0.61 interop tester ## Test Plan 1. Register the official RNTester in index.js of legacy-rn61-project, and try to run it on Harmony. 2. Test on android by running the legacy project with the RNTester registered in index.js. ## Checklist - [x] Does not involve incompatible changes; if involved, has been reviewed accordingly. - [x] Does not impact performance, or performance testing has been conducted without degradation. - [x] Complies with the relevant coding standards. - [x] Does not involve documentation updates, or the documentation has been updated. - [x] Meets testability requirements with necessary self-test cases, appropriate logging, or trace information added. - [x] No illegal file inclusions exist, such as images or code. See merge request: openharmony-sig/ohos_react_native!1375 | 1 year ago | |
fix(Config): exempt LICENSE-Meta from OAT scan and align copyright with upstream 问题描述: OAT 4 扫描报告 LICENSE-Meta 文件存在 Copyright Header Invalid: InvalidCopyright 告警。 LICENSE-Meta 中的版权声明 "Copyright (c) Meta Platforms, Inc. and affiliates" 不符合 OAT.xml policylist 中定义的允许版权模式 (Huawei Technologies Co., Ltd. 或个人开发者格式 ^[A-Z][a-z]+ [A-Z][a-z]+), 且末尾缺少句号,与 React Native 上游官方格式 "Copyright (c) Meta Platforms, Inc. and affiliates." 不一致,可能导致合规风险。 解决方案: 1. 在 OAT.xml 的 defaultFilter 和 copyrightPolicyFilter 中分别添加3个 LICENSE-Meta 文件的 filepath 过滤项, 声明其来自上游 Meta,与 LICENSE-Facebook 等处理一致; 2. 在3个 LICENSE-Meta 文件版权声明末尾补齐句号, 使其与 React Native 官方仓库格式完全一致。 影响范围: 仅修改 OAT.xml 过滤规则和 LICENSE-Meta 文本格式, 不改变任何源码逻辑与功能,整体向后兼容。 Signed-off-by: jiaxuan_wong <1801330925@qq.com> | 6 months ago | |
Modifications from version 0.77 migrated to 0.82 Co-authored-by: xiedrsz<xiedairong@huawei.com> Co-authored-by: arkadiuszkasprzyk<arkadiusz.kasprzyk@swmansion.com> Co-authored-by: kidq330<jakub.migdal@swmansion.com> Co-authored-by: michalzuch<michal.zuch@swmansion.com> Co-authored-by: zichenyang21<zichen834194@163.com> Co-authored-by: luqi_tan<295099422@qq.com> Co-authored-by: huangyouhua<huangyouhua2@huawei.com> Co-authored-by: qq_41986353<chenhaoyue1@huawei.com> Co-authored-by: huhaodong<huhaodong6@huawei.com> Co-authored-by: jiaxuan_wong<1801330925@qq.com> Co-authored-by: Marwyk2003<marcin.wykpis@swmansion.com> Co-authored-by: msluszniak<mateusz.sluszniak@swmansion.com> Co-authored-by: ohci1<ohci1@noreply.gitcode.com> Co-authored-by: pafry<patryk.fryda@swmansion.com> Co-authored-by: openharmony_ci<openharmony_ci@noreply.gitcode.com> Co-authored-by: saberblack<lizhen170@huawei.com> Co-authored-by: quxin024<quxin9@huawei.com> Co-authored-by: wojciech-loboda<wojciech.loboda@swmansion.com> Co-authored-by: haozhihang<haozhihang@huawei.com> # message auto-generated for no-merge-commit merge: !1980 merge 0.82 into 0.82 Modifications from version 0.77 migrated to 0.82 Created-by: haozhihang Commit-by: haozhihang;chenhaoyue1;openharmony_ci;michalzuch;pafry;wojciech-loboda;huangyouhua;qq_41986353;quxin024;msluszniak;Marwyk2003;saberblack;huhaodong;luqi_tan;arkadiuszkasprzyk;ohci1;jiaxuan_wong;xiedrsz;zichenyang21;kidq330 Merged-by: openharmony_ci Description: <!-- 请在合并之前删除注释代码,以避免将其包含在GIT历史记录中 --> # 描述 <!-- 简要描述PR的目的,例如: 这条PR主要实现metro局域网内远程调试的功能. --> # 变更日志 <!-- 列出可包含在变更日志中的要点的主要变更。 不要列出内部更改。请以下列开头来写每个变更点: - added - fixed - deprecated - removed 如果是一条新增属性的变更,则以[added]开头,例如: - [added] FlatList组件新增inverted属性 --> # 测试步骤 <!-- 如何测试这条PR。例如: 1. 打开Tester工程. 2. 执行npm run start命令. ... --> # 合入前自检 <!-- 请在合入前根据以下条例进行自检 自检完成后在[ ]内填入"x", 例如: - [x] 不涉及非兼容性变更;若涉及,已通过相应评审。 --> - [ ] 不涉及非兼容性变更;若涉及,已通过相应评审。 - [ ] 不涉及性能或已进行性能测试且无性能劣化。 - [ ] 符合对应的编码规范。 - [ ] 不涉及文档更新,或已更新了文档。 - [ ] 针对可测试性要求,已增加必要的自测用例、合理的日志记录或Trace信息。 - [ ] 不存在非法的文件引入,包括图片和代码等 - [ ] 本PR已经在77分支开启PR或不需要在77分支合入 - 如需合入77分支,PR地址: See merge request: openharmony-sig/ohos_react_native!1980 | 10 months ago | |
chore(Docs): RNOH社区规范文档调整,以及提供对应模板文件 1、RNOH社区规范文档调整 2、配套规范提供对应模板文件 3、tester直接依赖源码编译,需要在entry做debug和release区分 Signed-off-by: gyange <gyange@163.com> | 7 months ago | |
chore(Upgrade): bump RNOH to RN 0.88.1 Align RNOH packages, samples, docs, and third-party hermes gitlink (9a115f157) with upstream React Native 0.88.1. Resolve CodeCheck gate failures for non-upstream files: - SampleComponent: use single quotes for string literals (G.TYP.04) - NetworkingTest: extract helpers to reduce getTestCase size - Add sample-package .prettierrc.js with Huawei MIT header (2026) Signed-off-by: changlp <chang_leipeng@hoperun.com> | 2 days ago | |
docs(Docs): add README.OpenSource for third-party OSS declaration Add README.OpenSource declaring all vendored third-party open-source software (react-native, hermes, boost, double-conversion, fast_float, fmt, folly, glog, libevent) with license, license file path, version, owner, and upstream URL, following the CPF-ApplicationTPC format for OpenHarmony open-source compliance. The Owner field is left empty as a placeholder. Signed-off-by: liu_wentao <liuwentao57@h-partners.com> | 3 months ago | |
docs(Docs): fix bilingual alignment, broken links, and code samples in en/zh-cn docs - align EN/ZH content: rewrite the ContentSlot access section in architecture, add missing sections and sentences (stability, usage-faqs, custom-components, common scenarios, performance, environment-setup, TurboModule), and add the ArkTS-in-C-API section to the zh-cn hybrid-solution guide - fix terminology and code samples: hermescOptions type, onForeground casing, module.json5, Metro config formatting, emitComponentEvent arguments, CMake option comments, and the Woker typo - fix broken links and switch to language-specific targets: stability coding standards, DevEco release notes, trace optimization guides, Smartperf-Host, sample indexes, and sample READMEs - add the ContentSlot access figure and the EN gtest guide/module catalog - update figure files and localize figure references - extend the cspell dictionary and fix code sample errors found in review Signed-off-by: 焦舒畅 <18327003767@163.com> | 9 days ago | |
docs(Docs): update bilingual docs for RNOH 0.88.1 Align setup, upgrade, roadmap, and release notes with RN 0.88.1. Fix release CMake include path and release HAR header guidance. Record separate release and release2 symbol archives with the BuildIDs from that build. Keep roadmap/stable-version tables aligned with real branches and npm tags. Signed-off-by: changlp <chang_leipeng@hoperun.com> | 1 day ago | |
chore(Upgrade): fail fast when the preset plugin shape breaks Follow-up to MR review: a console.warn is easy to scroll past in CI, and the failure mode it guarded is exactly the silent one — if the toolkit preset ever splits its rules across several plugins, taking presetPlugins[0].rules drops the rest while commitlint keeps running with a smaller rule set. Both structural guards in commitlint.config.js now throw instead: the exact-one-plugin invariant and the non-empty extracted-rule-set invariant each raise an error naming the pinned toolkit version, so config loading fails loudly the moment the overlay and the preset shape drift apart. The install-hook scripts (scripts/preinstall.js, scripts/setup-husky.js) intentionally stay warn-only: there the missing-toolkit case is a bootstrap condition that must not fail the install, which is a different invariant from this config-shape one. Smoke-tested on this checkout: the config still loads with the current pin (12 plugin rules, 68 scope-enum entries), and fixtures with a 2-plugin preset, a 0-plugin preset, and an empty rule set all fail config loading with the new errors. Signed-off-by: gyange <gaoyang36@huawei.com> | 1 month ago | |
refactor: integrate quality-toolkit — full quality engineering stack Replace all self-hosted quality tooling with the quality-toolkit submodule (standards + skills + tools, 185 rules, 62-scenario self-verification suite). Single atomic commit; detailed history in the toolkit repo. Compliance harness: - .quality-toolkit submodule (HTTPS) + .quality/harness.config.json - 185-rule catalog with dependency gating; CI gate via --commit-range Commit enforcement: - commitlint rnoh preset with rnoh-tests-required rule - .githooks: commitlint + gitleaks + lint-staged after business checks Issue/PR automation: - tools/submit, tools/create-issue, tools/generate-branch-pr, tools/platform-api (gitcode/gitee/atomgit/github) Static analysis + multi-branch submit (restored from RNOH): - tools/static-check: 782-line multi-language engine - tools/submit-prs: 606-line Python multi-branch automation Skills structure: - .agents/skills/ → mixed: toolkit skills via symlinks (13 generic) + RNOH-local skills (arkts-test, rnoh-upgrade) - arkts-test moved from toolkit (HarmonyOS-specific) - rnoh-upgrade created from upgrade-version Part B+C (RNOH-specific) Testing: - packages/rnoh_test: CPTF E2E suite (submodule, HTTPS) - .opencode/agent/: 13 agents from toolkit + 2 RNOH-local skills Scripts replaced: all self-hosted quality scripts → toolkit equivalents (check_includes, integrate-upstream-code, package-trim, verify-docs, format-cpp, gitleaks, bump-version, gtest-*, patch-react-native) Impact: pnpm init-ws works without SSH keys; pnpm harness exit 0; pnpm submit --create-issue --yes creates issue + PR + linkage. test case: toolkit 62-scenario suite + gtest:quality 2983 tests + live Issue/PR creation on CPTF fork Signed-off-by: gyange <gaoyang36@huawei.com> AI[100%] Human Fixed[0%] Human[0%] AI Adopted[100%] Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> Co-authored-by: opencode (glm-5.2) <ai@local> Co-authored-by: opencode (glm-5.3) <ai@local> | 2 months ago | |
chore(Upgrade): bump RNOH to RN 0.88.1 Align RNOH packages, samples, docs, and third-party hermes gitlink (9a115f157) with upstream React Native 0.88.1. Resolve CodeCheck gate failures for non-upstream files: - SampleComponent: use single quotes for string literals (G.TYP.04) - NetworkingTest: extract helpers to reduce getTestCase size - Add sample-package .prettierrc.js with Huawei MIT header (2026) Signed-off-by: changlp <chang_leipeng@hoperun.com> | 2 days ago | |
chore: update react-native to 0.82.1 Co-authored-by: Patryk Fryda<patryk.fryda@swmansion.com> # message auto-generated for no-merge-commit merge: !1843 merge 0.82 into 0.82 chore: update react-native to 0.82.1 Created-by: pafry Commit-by: Patryk Fryda Merged-by: huangyouhua Description: # https://gitcode.com/openharmony-sig/ohos_react_native/merge_requests/1835 has to be merged first. ## Why are these changes being made? There is ongoing effort to update react-native and RNOH to 0.82. This is the last step. ### Notable react-native changes: - https://github.com/facebook/react-native/pull/51600 - infoLog removal - https://github.com/facebook/react-native/pull/53094 - changing libhermes to libhermesvm - https://github.com/facebook/react-native/pull/52610 - moving ReactNativeFeatureFlags to src/private - https://github.com/facebook/react-native/pull/53360 - stable DOM API - https://github.com/facebook/react-native/pull/52750 - Install ContextContainer::Shared with std::shared_ptr ### Other changes: - replaced custom RNOH cxx turbomodules ## Changelog - updated react-native to 0.82.1 ## Test Plan - launch tester app, - run sequential and concurrent tests ## Checklist - [x] pnpm verify command has passed successfully. - [x] No failures occurred in automatic tests on the CONCURRENT TESTER page in the tester app. - [x] No failures occurred in automatic tests on the SEQUENTIAL TESTER page in the tester app. - [x] MR does not include a breaking change or a review has been requested from a Huawei reviewer. See merge request: openharmony-sig/ohos_react_native!1843 | 11 months ago | |
chore(Upgrade): bump RNOH to RN 0.88.1 Align RNOH packages, samples, docs, and third-party hermes gitlink (9a115f157) with upstream React Native 0.88.1. Resolve CodeCheck gate failures for non-upstream files: - SampleComponent: use single quotes for string literals (G.TYP.04) - NetworkingTest: extract helpers to reduce getTestCase size - Add sample-package .prettierrc.js with Huawei MIT header (2026) Signed-off-by: changlp <chang_leipeng@hoperun.com> | 2 days ago | |
feat(interop-61): support Picker component Co-authored-by: Arkadiusz Kasprzyk<arkadiusz.kasprzyk@swmansion.com> # message auto-generated for no-merge-commit merge: merge kas/picker-61-attempt-3 into 0.77.1-rc.1-ohos feat(interop-61): support Picker component Created-by: arkadiuszkasprzyk Commit-by: Arkadiusz Kasprzyk Merged-by: huangyouhua Description: ## Description This MR adds support for Picker component, which is exported by RN 61 API. The implementation includes extra RNOH specific prop — selectedItemStyle, because OHOS uses by default a blue color to show selection. (I suspect many application developers may need to adapt that color to match the theme of their application.)  ## Changes - [added] Picker component support in interop-61 package ## Test Plan Compare Picker examples in RN Tester 61 with Android. - "Colorful pickers" example isn't supported on OHOS due to platform API limitations. - "Picker with prompt message" example also doesn't work, but this is also the case for Android. ## Checklist - [x] Does not involve incompatible changes; if involved, has been reviewed accordingly. - [x] Does not impact performance, or performance testing has been conducted without degradation. - [x] Complies with the relevant coding standards. - [x] Does not involve documentation updates, or the documentation has been updated. - [x] Meets testability requirements with necessary self-test cases, appropriate logging, or trace information added. - [x] No illegal file inclusions exist, such as images or code. See merge request: openharmony-sig/ohos_react_native!1544 | 1 year ago |
React Native for OpenHarmony (RNOH)
English | 简体中文
Bringing the full React Native development experience to the OpenHarmony ecosystem. High-performance bridging and full Fabric support enable RN applications to run seamlessly on OpenHarmony.
About the Project
This project adds OpenHarmony platform support to the React Native cross-platform application development framework.
| Role | Chinese Documentation | English Documentation |
|---|---|---|
| Application Developer | README.md | README.md |
| Library Developer | 三方库接入指南 | Library Integration Guide |
| Maintainer or Contributor | 开发者共建指南 | Developer Code Contribution Guide |
Documentation
🚀 Getting Started
| Document | Description |
|---|---|
| Environment Setup | Configure the development environment |
| SDK Version Configuration Guide | Configure SDK versions |
| Build Guide | Build Release packages |
📦 Version Management
💡 Which version to use: The default branch
mainof this repository is the version evolution branch (currently carrying exploratory development of new versions; stability is not guaranteed). Do not depend on it directly in production. For production adoption, install the stable version published under the npm dist-tag0.XX-stable(for example,@react-native-oh/react-native-harmony@0.82-stable, named in alignment with upstreamreact-nativeand advanced automatically with each iteration). Current recommendation:0.82-stable(latest GA) is the first choice for new production projects. For an overview of the status of each version line, see Stable Version Identification and Installation · Recommended Version Table.
| Document | Description |
|---|---|
| Stable Version Identification and Installation | Version selection conclusions and recommended version matrix |
| Release Notes | Overview of version information |
| Version Upgrade Guide | Version upgrade workflow |
| Developer Adaptation Requirements for RN Upgrades | Adaptation requirements for RN versions |
| Upstream Breaking Changes | Record of breaking changes |
💡 Development Documentation
| Document | Description |
|---|---|
| Framework Design | Design principles, architecture, and interface specifications to help developers understand the framework's internals. |
| Development Guide | Guidance from environment preparation through feature implementation. |
| Debugging | Tools and techniques to improve debugging efficiency. |
| Performance Tuning | Performance optimization methods, memory optimization guidance, and best practices to improve application performance and memory usage. |
❓ Troubleshooting
RNOH content has been incorporated into mainstream AI models such as Gemini, DeepSeek, and GLM.
Use AI tools together with logs and context to diagnose issues quickly. Provide the error stack + RNOH version + device model to obtain precise root-cause analysis and suggested fixes.
Stability Issues
| Step | Action |
|---|---|
| 1. Collect logs | Use DevEco Studio to obtain crash logs or tombstones. |
| 2. Analyze the stack | Focus on symbols in libRNOH.so and libreact_nativemodule.so. |
| 3. Check common causes | Missing thread synchronization, incorrect NativeModule lifecycle management, and out-of-bounds memory access. |
| 4. AI prompt | "RNOH 0.82 crashes when opening a Modal on a HarmonyOS foldable device. Here is the stack: ... Please analyze possible causes." |
| 5. Validate the solution | Isolate suspected modules and use AddressSanitizer to detect errors. |
| Document | Description |
|---|---|
| Stability Analysis Methods | Methods for analyzing freezes, CppCrash, memory anomalies, and other stability issues |
| v0.72 Historical Fixes | Fix history for version 0.72 |
| v0.77 Historical Fixes | Fix history for version 0.77 |
| v0.82 Historical Fixes | Fix history for version 0.82 |
Performance Issues
| Step | Action |
|---|---|
| 1. Collect data | Use React DevTools Profiler and HarmonyOS DevEco Profiler. |
| 2. Identify bottlenecks | Look for JS thread blocking, UI thread frame drops, and excessive rendering. |
| 3. Apply optimizations | Replace FlatList with FlashList, avoid anonymous functions, and enable Hermes concurrent GC. |
| 4. AI prompt | "Scrolling a long list in RNOH 0.77 is choppy, and JS thread utilization is 80%. Please suggest optimization strategies." |
| 5. Validate | Compare frame rate curves before and after optimization. |
Build and Integration Issues
| Step | Action |
|---|---|
| 1. Compilation errors | Check Git submodules, CMakeLists dependencies, and RNOH/RN version compatibility. |
| 2. Linking errors | Ensure all required .so libraries are packaged and inspect symbols with readelf. |
| 3. Module not found | Check TurboModule registration and Codegen output. |
| 4. AI prompt | "My RNOH build reports undefined symbol: jsi::Value in a 0.82 environment. How can I fix this?" |
| 5. Isolate the reproduction | Create a minimal demo and add modules incrementally to identify the issue. |
| Document | Description |
|---|---|
| RN-JS Bundling | JS bundling workflow |
| hvigorfile Configuration | Hvigor configuration guidance |
| Build and Symbol Management Guide | Build and symbol management |
Recommended workflow: Paste the error stack + version information + device model → AI provides root-cause analysis and patch suggestions → Improve efficiency by 80%.
FAQ
| Document | Description |
|---|---|
| FAQ Overview | Frequently asked questions |
| Compilation FAQ | Compilation issues |
| Runtime FAQ | Runtime issues |
| Specification FAQ | Specification questions |
| Issue Diagnosis and Isolation FAQ | Issue diagnosis methods |
| Usage FAQ | Usage questions |
🤝 Community Governance
| Document | Description |
|---|---|
| Developer Contribution Guide | Contribution workflow |
| Community Issue Management Guidelines | Issue handling guidelines |
| Community Commit and PR Guidelines | Commit and pull request guidelines |
| Community Changelog Guidelines | Changelog guidelines |
| Repository Branch Management Guidelines | Branch management guidelines |
| RNOH Package Management Guidelines | npm package management guidelines |
Community Communication
To be added.
Built with ❤️ by OpenHarmony React Native SIG