Testing with `per-file` granularity in 1.9.22, I n...
# javascript
e
Testing with
per-file
granularity in 1.9.22, I noticed each .kt file now outputs two .js files. One seems dedicated to exporting the other's definitions. Has this been done recently, or was it always like that? And also, is there a technical reason for doing so?
a
It was always to improve tree-shaking for the exported declarations (and hide some top-level effects).
👍 1
e
@Artem Kobzar I think I didn't notice it before because I wasn't `@JsExport`ing. That clarifies it, thanks!
I'll have to open in issue because kotlin.test tests don't work with per-file.
a
What compiler version do you have?
e
1.9.22
a
It’s fixed in 2.0.0-Beta2
e
Ah thanks! Does it work if in 2.* I disable K2?
a
Yeah, at least it should, if it’s not - please create an issue
e
Perfect. I'm blocked by a couple of YT issues unfortunately, so K1 support is always nice to have.