esoftplay 0.0.119-e → 0.0.119-f
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/router.js +10 -3
- package/package.json +1 -1
package/bin/router.js
CHANGED
|
@@ -467,6 +467,13 @@ declare module "esoftplay" {
|
|
|
467
467
|
tmpTask[clsName]["function"]['decode'] = 'decode(text: string): string;';
|
|
468
468
|
}
|
|
469
469
|
if (tmpTask[clsName]["class"]) {
|
|
470
|
+
|
|
471
|
+
if (clsName !== "LibComponent")
|
|
472
|
+
ItemText += "import { LibComponent } from 'esoftplay/cache/lib/component.import';\n"
|
|
473
|
+
else if (clsName === "LibComponent") {
|
|
474
|
+
ItemText += "import { Component } from 'react';\n"
|
|
475
|
+
}
|
|
476
|
+
|
|
470
477
|
// ItemText += "\n";
|
|
471
478
|
for (var i = 0; i < tmpTask[clsName]["type"].length; i++) {
|
|
472
479
|
ItemText += "\n " + tmpTask[clsName]["type"][i].replace(/\n/g, "\n ");
|
|
@@ -621,15 +628,15 @@ function createRouter() {
|
|
|
621
628
|
Task += "\t\t" + 'case "' + nav + '":' + "\n\t\t\t" + 'Out = require("../../.' + Modules[module][task] + '")?.default' + "\n\t\t\t" + 'break;' + "\n";
|
|
622
629
|
TaskProperty += "\t\t" + 'case "' + nav + '":' + "\n\t\t\t" + 'Out = require("../../.' + Modules[module][task] + '")' + "\n\t\t\t" + 'break;' + "\n";
|
|
623
630
|
/* ADD ROUTER EACH FILE FOR STATIC IMPORT */
|
|
624
|
-
var item = "import { stable } from 'usestable';\nimport { default as _" + ucword(module) + ucword(task) + " } from '
|
|
631
|
+
var item = "import { stable } from 'usestable';\nimport { default as _" + ucword(module) + ucword(task) + " } from '../../../." + Modules[module][task] + "';\n"
|
|
625
632
|
if (HookModules.includes(nav)) {
|
|
626
633
|
item += "" +
|
|
627
|
-
"import * as " + ucword(module) + ucword(task) + SuffixHooksProperty + " from '
|
|
634
|
+
"import * as " + ucword(module) + ucword(task) + SuffixHooksProperty + " from '../../../." + Modules[module][task] + "';\n" +
|
|
628
635
|
"var " + ucword(module) + ucword(task) + " = stable(_" + ucword(module) + ucword(task) + "); \n" +
|
|
629
636
|
"export { " + ucword(module) + ucword(task) + SuffixHooksProperty + ", " + ucword(module) + ucword(task) + " };\n"
|
|
630
637
|
} else if (UseLibs.includes(nav)) {
|
|
631
638
|
item += "" +
|
|
632
|
-
"import * as " + ucword(module) + ucword(task) + SuffixHooksProperty + " from '
|
|
639
|
+
"import * as " + ucword(module) + ucword(task) + SuffixHooksProperty + " from '../../../." + Modules[module][task] + "';\n" +
|
|
633
640
|
"var " + ucword(module) + ucword(task) + " = _" + ucword(module) + ucword(task) + "; \n" +
|
|
634
641
|
"export { " + ucword(module) + ucword(task) + SuffixHooksProperty + ", " + ucword(module) + ucword(task) + " };\n"
|
|
635
642
|
} else {
|