Coder Social home page Coder Social logo

Challenge Integrating Repack in React Native Mono Repo: App1 Loads Successfully, App2 Fails to Load from Server Bundles about repack HOT 3 OPEN

dhayaljaswantgit avatar dhayaljaswantgit commented on June 24, 2024
Challenge Integrating Repack in React Native Mono Repo: App1 Loads Successfully, App2 Fails to Load from Server Bundles

from repack.

Comments (3)

jbroma avatar jbroma commented on June 24, 2024

Hey @dhayaljaswantgit

for your first issue, please try changing the production path in the following manner:

from:

const resolveURL = Federated.createURLResolver({
  containers: {
    app1: 'http://localhost:9000/[name][ext]',
    app2: 'https://firebasestorage.googleapis.com/v0/b/jaswant-dhayal.appspot.com/o/index-android.bundle?alt=media&token=0f5ab5ee-4b55-424a-8b6b-cd5f13ac119c',
  },
});

to:

const resolveURL = Federated.createURLResolver({
  containers: {
    app1: 'http://localhost:9000/[name][ext]',
    app2: 'https://firebasestorage.googleapis.com/v0/b/jaswant-dhayal.appspot.com/o/[name][ext]',
  },
});

this is because there is more than one file to resolve using the resolver here. Typically you first download .container.bundle and then the app.chunk.bundle. Also please note that you don't need to include the index-android.bundle for the mini-apps as it's unused in MF setup.

when it comes to versioning, I can tell you from my experience that it's not a trivial problem to solve, you can look into this PR that introduced SDK to the super-app-showcase to help with having only 1 version to align to.

from repack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.