Skip to content

Commit

Permalink
feat: make access components routes easier
Browse files Browse the repository at this point in the history
  • Loading branch information
acellam committed Sep 18, 2024
1 parent 71b9c7e commit acc04f9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,8 +197,7 @@ export class FractalJs {
const route = await import(`./components/${componentName}/routers/${routeName}`);
const className = Object.keys(route)[0];
const importedClass = route[className];
this.routes[className] = new importedClass(this);
// fractalLogger.info({ routes: this.routes, className, importedClass });
this.routes[`${componentName}.${className}`] = new importedClass(this);
}
} catch (err: any) {
fractalLogger.error(`Error importing component ${componentName}: ${err.message}`);
Expand Down

0 comments on commit acc04f9

Please sign in to comment.