JS: prevent compiler from importing module more than once if not necessary. See KT-15260
This commit is contained in:
committed by
Alexey Andreev
parent
1ecd957981
commit
9b4b7960d3
@@ -0,0 +1,12 @@
|
||||
__beginModule__();
|
||||
module.exports = function(param) {
|
||||
switch (typeof param) {
|
||||
case "number":
|
||||
return "a";
|
||||
case "string":
|
||||
return "b";
|
||||
default:
|
||||
return "c";
|
||||
}
|
||||
};
|
||||
__endModule__("lib");
|
||||
Reference in New Issue
Block a user