Coder Social home page Coder Social logo

Comments (6)

jbroma avatar jbroma commented on July 23, 2024

Hey @pratt3351,

please verify there are no changes in main chunk after you remove the import. Compare both using diff and see if there is something there. Also have you tried checking what's hiding under 264982:35 in the generated bundle code? Best to do that with minifying turned off so the names are not mangled.

from repack.

pratt3351 avatar pratt3351 commented on July 23, 2024

Hey @pratt3351,

please verify there are no changes in main chunk after you remove the import. Compare both using diff and see if there is something there. Also have you tried checking what's hiding under 264982:35 in the generated bundle code? Best to do that with minifying turned off so the names are not mangled.

@jbroma
hi, thank for reply.
i have a basic question, where can i find main.chunk file in my local device ? sorry for basic question

from repack.

pratt3351 avatar pratt3351 commented on July 23, 2024

Hey @pratt3351,

please verify there are no changes in main chunk after you remove the import. Compare both using diff and see if there is something there. Also have you tried checking what's hiding under 264982:35 in the generated bundle code? Best to do that with minifying turned off so the names are not mangled.

@jbroma
ok i find something. i use zone.js, so i removed it and then i received this following error.
i guess that Promise construct not working.

any help..?
Simulator Screenshot - iPhone 15 - 2024-03-18 at 23 23 35
스크린샷 2024-03-18 오후 11 23 53

from repack.

jbroma avatar jbroma commented on July 23, 2024

Hey @pratt3351,
please verify there are no changes in main chunk after you remove the import. Compare both using diff and see if there is something there. Also have you tried checking what's hiding under 264982:35 in the generated bundle code? Best to do that with minifying turned off so the names are not mangled.

@jbroma hi, thank for reply. i have a basic question, where can i find main.chunk file in my local device ? sorry for basic question

Hi @pratt3351, regarding this, you can unzip the .ipa or .apk (you can change it to .zip and unzip it) and explore the bundle contents and verify it was placed there by OutputPlugin (part of RepackPlugin).

As to your second question, it looks transpiled properly (class-transform), but it fails to include runtime helpers, please create a reproduction repository so I can take a closer look - can't really help you much more than that witohut looking at the code.

from repack.

pratt3351 avatar pratt3351 commented on July 23, 2024

sorry for late reponse
i'm so sorry, for cant give you to reproduction repository.! (its our business app, and cannot divide logic)

but i find something,
when i build js bundle from this command (npx react-native webpack-bundle --entry-file index.js --platform ios --dev false --reset-cache --bundle-output ./test/main.jsbundle --minify false --sourcemap-output ./test/main.jsbundle.map), diffrence between not removed component main bundle and removed component version main bundle
its looks like this
스크린샷 2024-03-27 오후 2 29 13
스크린샷 2024-03-27 오후 2 29 18

right side: not removed component jsbundle
left side :removed component jsbundle

in this screenshot, i have a question,

  1. why my ProductDetailScreen = react.lazy function webpack_require number is changed ?
    2, i think that productCouponService is removed because it is not used, it is cause of this error ?

thinks for your help. always @jbroma

from repack.

jbroma avatar jbroma commented on July 23, 2024

@pratt3351 the number you are referring to is moduleId (see webpack docs) and in production mode it's set to 'deterministic'. It means that when the content of that module changes, so does the ID.

Reviewing this issue once again, I noticed that what you need is Module Federation and not Code Splitting if you want to introduce modifications like this.

I'll close this issue since this is something that isn't supported.

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.