dce works now, it trims everything to aroung 300 K...
# javascript
c
dce works now, it trims everything to aroung 300 Kb, which is ok, the problem is webpack resolve precedence, it was not picking the dced files
c
What did you have to change to get it to work right?
c
path.resolve('classes/kotlin/main'), path.resolve('kotlin-js-min/main'), path.resolve('node_modules'), path.resolve(__dirname, '../../sfn-adapters-core/frontend-core/build/node_modules')
you see that kotlin-js-min path resolve?
i moved it up one line, so that it takes precedence over the non dced .js modules
c
aha
c
but strange now I get another error
e.defineModule function not found
c
😞
c
ahaha what a struggle
now dce really works but it's stripping away even what I use
c
yeah, wrangling the size down to a reasonable level has been awful
c
are you working at JB ?
Utils.kt:34 Uncaught TypeError: e.defineModule is not a function at Object.o (Utils.kt:34) at Object.<anonymous> (Utils.kt:34) at n (bootstrap:19) at Object.<anonymous> (stream.kt:161) at n (bootstrap:19) at bootstrap:83 at bootstrap:83
i wonder what this is
ok solved it, another webpack issue
and on top of this, gradle with all sorts of race conditions sometimes just doesn't add the minified file to the jar
c
I am not working at jb, no