diff --git a/docs/Samples/FabricComponentSample/NativeProject/entry/hvigorfile.ts b/docs/Samples/FabricComponentSample/NativeProject/entry/hvigorfile.ts index d0f029bd2a2858b1701bf87bf3f67c00d5630c84..6650e7217be2e794b661d45f0d373a35d0026db4 100644 --- a/docs/Samples/FabricComponentSample/NativeProject/entry/hvigorfile.ts +++ b/docs/Samples/FabricComponentSample/NativeProject/entry/hvigorfile.ts @@ -8,6 +8,6 @@ import { hapTasks } from '@ohos/hvigor-ohos-plugin'; export default { - system: hapTasks, /* Built-in plugin of Hvigor. It cannot be modified. */ - plugins:[] /* Custom plugin to extend the functionality of Hvigor. */ + system: hapTasks, /* Built-in plugin of Hvigor. It cannot be modified. */ + plugins: [] /* Custom plugin to extend the functionality of Hvigor. */ } diff --git a/docs/Samples/FabricComponentSample/NativeProject/hvigorfile.ts b/docs/Samples/FabricComponentSample/NativeProject/hvigorfile.ts index 549b0badab9ef99722e947c60855c7dd266ae506..3ba030761c1b3d33a633b8c22b41961b782bf7b2 100644 --- a/docs/Samples/FabricComponentSample/NativeProject/hvigorfile.ts +++ b/docs/Samples/FabricComponentSample/NativeProject/hvigorfile.ts @@ -8,6 +8,6 @@ import { appTasks } from '@ohos/hvigor-ohos-plugin'; export default { - system: appTasks, /* Built-in plugin of Hvigor. It cannot be modified. */ - plugins:[] /* Custom plugin to extend the functionality of Hvigor. */ + system: appTasks, /* Built-in plugin of Hvigor. It cannot be modified. */ + plugins: [] /* Custom plugin to extend the functionality of Hvigor. */ } diff --git a/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonNode.cpp b/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonNode.cpp index 014334a2485a70f957b89c80c1494323a6bd085d..c12cc7f037c39042e2600a35799214a46d2adb9f 100644 --- a/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonNode.cpp +++ b/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonNode.cpp @@ -26,7 +26,6 @@ ButtonNode::~ButtonNode() { } } - ButtonNode& ButtonNode::setButtonNodeDelegate( ButtonNodeDelegate* buttonNodeDelegate) { m_buttonNodeDelegate = buttonNodeDelegate; diff --git a/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonViewComponentDescriptor.h b/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonViewComponentDescriptor.h index f49df24217be866c3fa3d1f9612410f8e294501b..d4ddc91da7c95a4cde9e38881d087e90c25acdee 100644 --- a/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonViewComponentDescriptor.h +++ b/docs/Samples/Sample/SampleApp/entry/src/main/cpp/ButtonView/ButtonViewComponentDescriptor.h @@ -5,7 +5,6 @@ * LICENSE-MIT file in the root directory of this source tree. */ - #pragma once #include diff --git a/docs/Samples/Sample/SampleApp/entry/src/main/cpp/SampleTurboModulePackage.cpp b/docs/Samples/Sample/SampleApp/entry/src/main/cpp/SampleTurboModulePackage.cpp index f06464ffa14c7b06b33c6ce09f5fdb2cf86d0f54..2f2b2abff1dfdba6f9fffe59ee7aed61c688ded1 100644 --- a/docs/Samples/Sample/SampleApp/entry/src/main/cpp/SampleTurboModulePackage.cpp +++ b/docs/Samples/Sample/SampleApp/entry/src/main/cpp/SampleTurboModulePackage.cpp @@ -43,7 +43,6 @@ class ButtonViewPackageComponentInstanceFactoryDelegate : public ComponentInstan } }; - EventEmitRequestHandlers SampleTurboModulePackage::createEventEmitRequestHandlers() { return {std::make_shared()}; } diff --git a/docs/Samples/using_RNSurface/SampleApp/entry/src/main/ets/pages/Index.ets b/docs/Samples/using_RNSurface/SampleApp/entry/src/main/ets/pages/Index.ets index 721b3cff4a01704de0952627b16750594f63b3a1..404a6ee6d99716fd3dbe1efd8e5c5cc1805b64a3 100644 --- a/docs/Samples/using_RNSurface/SampleApp/entry/src/main/ets/pages/Index.ets +++ b/docs/Samples/using_RNSurface/SampleApp/entry/src/main/ets/pages/Index.ets @@ -53,11 +53,19 @@ export struct Index { enableCAPIArchitecture: true, arkTsComponentNames: [] }); - await this.instance.runJSBundle(new ResourceJSBundleProvider(getContext().resourceManager, this.bundlePath)) - .then(() => { - this.isBundleReady = true; - console.log('instance 加载完成' + this.bundlePath); - }) + await this.instance.runJSBundle(new TraceJSBundleProviderDecorator( + new AnyJSBundleProvider([ + new ResourceJSBundleProvider(getContext().resourceManager, this.bundlePath), + new MetroJSBundleProvider(), + new FileJSBundleProvider('/data/storage/el2/base/files/bundle.harmony.js'), + new ResourceJSBundleProvider(this.rnohCoreContext.uiAbilityContext.resourceManager, 'hermes_bundle.hbc'), + new ResourceJSBundleProvider(this.rnohCoreContext.uiAbilityContext.resourceManager, 'bundle.harmony.js') + ]),this.rnohCoreContext.logger)) + .then(() => { + this.isBundleReady = true; + console.log('instance 加载完成' + this.bundlePath); + }) + } build() { diff --git a/docs/Samples/using_RNSurface/SampleProject/MainProject/package.json b/docs/Samples/using_RNSurface/SampleProject/MainProject/package.json index 80ef7cdfee8dd37d8bd510480f577f248e329d4d..cc7011c78c51bc30145f20db66b12fca7cf06174 100644 --- a/docs/Samples/using_RNSurface/SampleProject/MainProject/package.json +++ b/docs/Samples/using_RNSurface/SampleProject/MainProject/package.json @@ -7,6 +7,7 @@ "ios": "react-native run-ios", "lint": "eslint .", "test": "jest", + "start":"react-native start --config metro.config.js", "dev": "react-native bundle-harmony --dev false --entry-file ./src/bundles/index.js --bundle-output ../../SampleApp/entry/src/main/resources/rawfile/bundle.harmony.js --config ./bundle.config.js --assets-dest ../../SampleApp/entry/src/main/resources/rawfile" }, "dependencies": {