electrode-io / electrode-native

A platform to ease integration&delivery of React Native apps in existing mobile applications
https://native.electrode.io
Other
727 stars 113 forks source link

An error occurred: At least one MiniApp or JS API implementation is needed to generate a composite #1865

Closed tianzige666 closed 2 years ago

tianzige666 commented 2 years ago

I want to create a container:

First i init a miniapp with Electrode-native Cli. then i run command with "ern run-android" cli was successful.

  1. i create a Github Repository for Cauldron;
  2. ern cauldron add nativeapp testelectrodenative-miniapp:android:0.0.1;
  3. ern create-container, i got two errors:
    1. "An error occurred: At least one MiniApp or JS API implementation is needed to generate a composite";
    2. "runCauldronCompositeGen failed: Error: At least one MiniApp or JS API implementation is n eeded to generate a composite";
  4. At least , i run "ern start" and "ern create-composite", i got the error "An error occurred: At least one MiniApp or JS API implementation is needed to generate a composite";

Can you guys tell me the step for the create container! Please help!!!!!!!!!!

tianzige666 commented 2 years ago

@belemaire When i run "ern create-composite", i got this error: "An error occurred: At least one MiniApp or JS API implementation is needed to generate a composite"

tianzige666 commented 2 years ago

i want to build a aar module

leekuo commented 2 years ago

Hi @crazySadSoul try this command to create a container: ern create-container --miniapps /absolute/path/to/miniapp_directory --platform ios|android for composites you may want to try this one: ern create-composite -m /absolute/path/to/miniapp1_directory /absolute/path/to/miniapp2_directory

Let me know if that helps or not.

tianzige666 commented 2 years ago

Hi @crazySadSoul try this command to create a container: ern create-container --miniapps /absolute/path/to/miniapp_directory --platform ios|android for composites you may want to try this one: ern create-composite -m /absolute/path/to/miniapp1_directory /absolute/path/to/miniapp2_directory

Let me know if that helps or not.

It work for me! Thank you! But i cant find aar module in the generated directory.

image
leekuo commented 2 years ago

It work for me! Thank you! But i cant find aar module in the generated directory.

image

@crazySadSoul Try running the publish container to your local Maven repository, for example: ern publish-container -p maven --platform android -e '{"groupId":"com.walmart.ern","artifactId":"quickstart"}'

Then look inside your $HOME/.m2 folder and locate the generated AAR artifact there.

tianzige666 commented 2 years ago

@leekuo its successful to generated aar module. 👍

leekuo commented 2 years ago

That is awesome, great to hear!