Get 2024 Templates Mega Bundle!14 Bootstrap, Vue & React Templates + 3 Vector Sets
Get for 99$

When pointing to / no template is applied


Hello,
I've started editing your Angular Demo1 template so that it can feet my needs but I've got a strange problem....

When I just point to / I got the page witout template and I don't understand what's wrong, I've got no error or hints that can help me spotting the problem.

Here's what happens https://i.postimg.cc/JztmD8jZ/s1.png

and what happens if I put /data-owner

https://i.postimg.cc/9X1vGSmp/s2.png

Here's my routing file (/pages/routing.ts)


import { Routes } from "@angular/router";

const Routing: Routes = [
{
path: "data-owner",
loadChildren: () =>
import("../../app/data-owner/data-owner.module").then((m) => m.DataOwnerModule),
},
{
path: "platform-blacklist",
loadChildren: () =>
import("../../app/platform-blacklist/platform-blacklist.module").then((m) => m.PlatformBlacklistModule),
},
{
path: "platform-metadata",
loadChildren: () =>
import("../../app/platform-metadata/platform-metadata.module").then((m) => m.PlatformMetadataModule),
},
{
path: "vocabulary",
loadChildren: () =>
import("../../app/vocabulary/vocabulary.module").then((m) => m.VocabularyModule),
},
{
path: "supplier-source",
loadChildren: () =>
import("../../app/supplier-source/supplier-source.module").then((m) => m.SupplierSourceModule),
},
{
path: "/",
redirectTo: "vocabulary",
pathMatch: "full",
},

{
path: "**",
redirectTo: "error/404",
},
];

export { Routing };


and here's the app-routing.ts


import { NgModule } from "@angular/core";
import { Routes, RouterModule } from "@angular/router";
import { AuthGuard } from "./modules/auth/services/auth.guard";

export const routes: Routes = [
{
path: "auth",
loadChildren: () =>
import("./modules/auth/auth.module").then((m) => m.AuthModule),
},
{
path: "error",
loadChildren: () =>
import("./modules/errors/errors.module").then((m) => m.ErrorsModule),
},
{
path: "",
canActivate: [AuthGuard],
loadChildren: () =>
import("./_metronic/layout/layout.module").then((m) => m.LayoutModule),
},

{ path: "**", redirectTo: "error/404" },
];

@NgModule({
imports: [RouterModule.forRoot(routes)],
exports: [RouterModule],
})
export class AppRoutingModule {}


How can I spot the problem?
Thanks


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(

Replies (2)


Hello,
I've fixed it... I was wrongly referencing the Components inside the app.module... removed them and it worked.. you can close



Glad to hear that happy All the best with your project.


Your Support Matters!

We will highly appreciate your Metronic Review on Themeforest.
Please go to Themeforest Downloads page, select Metronic & leave your feedback.
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(