cradova 3.3.15 → 3.3.16
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/dist/index.js +5 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -570,7 +570,6 @@ class Page {
|
|
|
570
570
|
if (html instanceof HTMLElement) {
|
|
571
571
|
this._template.innerHTML = "";
|
|
572
572
|
this._template.appendChild(html);
|
|
573
|
-
console.log("boohoo 2", html);
|
|
574
573
|
} else {
|
|
575
574
|
throw new Error(` \u2718 Cradova err: template function for the page returned ${html} instead of html`);
|
|
576
575
|
}
|
|
@@ -632,6 +631,7 @@ class RouterBoxClass {
|
|
|
632
631
|
} else {
|
|
633
632
|
[route, params] = this.checker(url);
|
|
634
633
|
}
|
|
634
|
+
console.log({ url, route });
|
|
635
635
|
if (typeof route !== "undefined") {
|
|
636
636
|
try {
|
|
637
637
|
if (typeof route === "function") {
|
|
@@ -674,8 +674,11 @@ class RouterBoxClass {
|
|
|
674
674
|
}
|
|
675
675
|
checker(url) {
|
|
676
676
|
if (url[0] !== "/") {
|
|
677
|
-
|
|
677
|
+
console.log(url, 1);
|
|
678
|
+
url = url.slice(url.indexOf("/", 8));
|
|
679
|
+
console.log(url, 2);
|
|
678
680
|
}
|
|
681
|
+
console.log(url);
|
|
679
682
|
if (this.routes[url]) {
|
|
680
683
|
return [this.routes[url], { path: url }];
|
|
681
684
|
}
|