Since in most cases we have this:
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-js:$kotlin_version"
}
And the Kotlin standard library seems to large for me.
I want to minimize it by creating my own stdlib, which can be smaller, by declaring only external methods I need.
I tried to remove that method, it compiles, but the generated JS code has this:
if (typeof kotlin === 'undefined') {
throw new Error("Error loading module 'streaking'. Its dependency 'kotlin' was not found. Please, check whether 'kotlin' is loaded prior to 'streaking'.");
}
Which means that there must be something necessary in the stdlib, which I don't know.
As my requirements are described above, is there any workarounds?
Or how can I reduce the size of the generated code?