feat: add script engine, refine entry/initOnce constraints#6
Closed
huajiqaq wants to merge 4 commits intocwuom:masterfrom
Closed
feat: add script engine, refine entry/initOnce constraints#6huajiqaq wants to merge 4 commits intocwuom:masterfrom
huajiqaq wants to merge 4 commits intocwuom:masterfrom
Conversation
Introduce native core initialization state (isNativeCoreInitialized / setNativeCoreInitialized) in NativeCoreBridge and use it when initializing MMKV to better track / log init status. Adjust initializeMmkvForPrimaryNativeLibrary to use the new API and set the flag via setter. Update LogUtils to consult the native init state before gating logs, preventing premature log suppression. Make WePkgDispatcher null-safe for getUri to avoid NPEs, and add a comment in MmkvConfigManagerImpl highlighting that MMKV must be initialized before use.
…R8 compilation issues
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
描述 / Description
基于 Rhino JavaScript 引擎,首次引入脚本能力。用户可直接编写
.js文件作为自定义 Hook,无需编译、无需重启,实现热加载、低门槛的框架扩展。entry:从抽象方法改为非抽象,提供默认实现,子类可不被重写,减少模板代码initOnce:标记为final/ 强制调用,确保不可被跳过、不可被重写,保障初始化逻辑100%执行类型 / Type
修复或解决的问题 / Issues Fixed or Closed by This PR
entry导致的冗余代码问题initOnce被子类覆盖或遗漏调用导致的初始化不可靠问题清单 / Checklist
其他信息 / Additional Information