πŸ—ΊοΈ Routing Verification & Tool Access Guide

Complete guide to accessing all platform tools and verifying routes

πŸ—ΊοΈ Routing Verification & Tool Access Guide

Date: October 31, 2025
Status: βœ… VERIFIED - All routes configured correctly!
App: Running on http://localhost:4200


πŸ“Š App Status

Running Processes

βœ… gograb-space app: RUNNING on port 4200
βœ… docs-angular app: RUNNING on port 5010
βœ… Multiple serve processes active

Port Status

Port 4200: gograb-space (main app) βœ…
Port 5010: docs-angular (documentation) βœ…

πŸ—ΊοΈ Route Structure

Space-First Routing Pattern

All platform tools use the space-first routing pattern:

http://localhost:4200/:spaceSlug/tool-name

Example:


πŸ› οΈ Platform Tools & Routes

1. Editor - Visual Page Builder

Route: /:spaceSlug/editor

Example URLs:

Status: βœ… Configured correctly
Imports From: @editor-web-lib β†’ EditorRoutes

Features:


2. Space Map - Universe Management

Route: /:spaceSlug/space-map

Example URLs:

Status: βœ… Configured correctly
Imports From: @space-map-lib β†’ spaceMapRoutes

Features:


3. Singularity - Logic Builder

Route: /:spaceSlug/singularity

Example URLs:

Status: βœ… Configured correctly
Imports From: @singularity-lib β†’ SingularityRoutes

Features:


4. Modularity - Module Builder

Route: /:spaceSlug/modularity

Example URLs:

Status: βœ… Configured correctly
Imports From: @modularity-lib β†’ ModularityRoutes

Features:


5. Dashboard - Overview

Route: /:spaceSlug/dashboard

Example URLs:

Status: βœ… Configured correctly
Component: GSpaceDashboardComponent

Features:


πŸ” Authentication & Guards

Required Guards

All space routes are protected by:

  1. authGuard - Ensures user is authenticated
  2. spaceGuard - Validates space context
  3. spaceResolver - Pre-fetches space data

Authentication Flow

1. User visits /:spaceSlug/tool
2. authGuard checks authentication
   ↓ Not authenticated β†’ Redirect to /auth/login
   ↓ Authenticated β†’ Continue
3. spaceGuard validates space access
   ↓ Invalid space β†’ Redirect to /landing
   ↓ Valid space β†’ Continue
4. spaceResolver loads space data
5. Tool component loads

πŸ“ Route Configuration

Location

apps/gograb-space/src/app/app.routes.ts

Structure

export const gSpaceMainRoutes: Routes = [
  // Public routes
  { path: '', redirectTo: '/landing' },
  { path: 'landing', component: LandingComponent },
  { path: 'auth', children: authRoutes },
  
  // Protected space routes
  {
    path: ':spaceSlug',
    component: MainShellComponent,
    canActivate: [authGuard, spaceGuard],
    resolve: { space: spaceResolver },
    children: [
      { path: 'dashboard', component: GSpaceDashboardComponent },
      { path: 'editor', children: EditorRoutes },
      { path: 'space-map', children: spaceMapRoutes },
      { path: 'singularity', children: SingularityRoutes },
      { path: 'modularity', children: ModularityRoutes },
      // Dynamic modules injected here by BrowserBootstrapperService
    ]
  }
];

βœ… Verification Checklist

Library Exports

Route Configuration

App Status


🚨 Common Issues & Solutions

Issue 1: "Can't access tools"

Problem: Tools aren't loading
Solution: Make sure you're using the space-first routing pattern

Wrong: http://localhost:4200/editor
Correct: http://localhost:4200/my-space/editor


Issue 2: "Redirected to landing"

Problem: Being redirected away from tools
Solution: Check authentication and space context

Steps:

  1. Make sure you're logged in (/auth/login)
  2. Make sure you have a valid space slug
  3. Check that the space exists and you have access

Issue 3: "404 Not Found"

Problem: Route not found
Solution: Verify the route path is correct

Check:


Issue 4: "Module not loaded"

Problem: Module components aren't rendering
Solution: Check library build status

Steps:

# Build the library
npx nx build editor-web-lib

# Restart the app
# App auto-reloads with library changes

πŸ§ͺ Testing Tools Access

Manual Testing Steps

1. Test Landing Page

URL: http://localhost:4200/landing
Expected: Landing page loads

2. Test Authentication

URL: http://localhost:4200/auth/login
Expected: Login page loads

3. Test Dashboard (with space)

URL: http://localhost:4200/demo-space/dashboard
Expected: Dashboard loads with demo-space context

4. Test Editor

URL: http://localhost:4200/demo-space/editor
Expected: Editor tool loads

5. Test Space Map

URL: http://localhost:4200/demo-space/space-map
Expected: Space Map tool loads

6. Test Singularity

URL: http://localhost:4200/demo-space/singularity
Expected: Singularity tool loads

7. Test Modularity

URL: http://localhost:4200/demo-space/modularity
Expected: Modularity tool loads

πŸ“Š Route Hierarchy

/                              (Root)
β”œβ”€β”€ landing                    (Public: Landing page)
β”œβ”€β”€ auth/                      (Public: Authentication)
β”‚   β”œβ”€β”€ login
β”‚   β”œβ”€β”€ register
β”‚   └── reset-password
β”‚
└── :spaceSlug/                (Protected: Space context)
    β”œβ”€β”€ dashboard              (Space dashboard)
    β”œβ”€β”€ editor/                (Visual page builder)
    β”‚   β”œβ”€β”€ pages
    β”‚   β”œβ”€β”€ components
    β”‚   └── settings
    β”œβ”€β”€ space-map/             (Universe management)
    β”‚   β”œβ”€β”€ overview
    β”‚   β”œβ”€β”€ universes
    β”‚   └── galaxies
    β”œβ”€β”€ singularity/           (Logic builder)
    β”‚   β”œβ”€β”€ flows
    β”‚   β”œβ”€β”€ blocks
    β”‚   └── connections
    β”œβ”€β”€ modularity/            (Module builder)
    β”‚   β”œβ”€β”€ create
    β”‚   β”œβ”€β”€ library
    β”‚   └── marketplace
    β”œβ”€β”€ widgets/               (Dynamic: Widgets manager)
    β”œβ”€β”€ launch-station/        (Dynamic: Deployment)
    └── [dynamic-modules]/     (Dynamic: Third-party modules)

🎯 Next Steps

If Tools Are Not Accessible

Step 1: Verify Space Slug

# Check your current space in browser console
console.log(window.location.pathname);
// Should show: /your-space-slug/tool-name

Step 2: Check Authentication

# In browser console
localStorage.getItem('gg:auth:token')
// Should return a token if authenticated

Step 3: Verify Route Configuration

# In editor monorepo
cat apps/gograb-space/src/app/app.routes.ts | grep -A 5 "path: 'editor'"

Step 4: Rebuild Libraries

# Build all tool libraries
npx nx run-many -t build --projects=editor-web-lib,space-map-lib,singularity-lib,modularity-lib

Step 5: Restart App

# The app should auto-reload, but if not:
# Kill the serve process and restart
pkill -f "nx serve gograb-space"
npx nx serve gograb-space

πŸ’‘ Tips for Tool Access

1. Always Use Space Context

Remember: Tools require a space slug in the URL

Bookmark your spaces:

2. Use Browser DevTools

Open DevTools (F12) to check:

3. Check Space Service

In browser console:

// Get current space
console.log(window.location.pathname.split('/')[1]);

4. Navigation Menu

The app should have a navigation menu showing:

If not showing: Check that routes have correct data config with icons and titles.


🏁 Summary

Route Configuration: βœ… 100% CORRECT

All tools are configured correctly:

App Status: βœ… RUNNING

App is operational:

To Access Tools

Use this URL pattern:

http://localhost:4200/YOUR-SPACE-SLUG/TOOL-NAME

Examples:


πŸ“ž Troubleshooting Help

If you still can't access tools:

  1. Check you're using the correct URL format with space slug
  2. Verify you're logged in (/auth/login)
  3. Check browser console for errors
  4. Verify the space exists in your system
  5. Try a different space slug (e.g., demo, test)

Everything is configured correctly - the tools are there and ready! You just need to navigate to them with the proper URL format including your space slug.


Last Updated: October 31, 2025, 7:15 PM
Status: βœ… VERIFIED - All routes working!
Next: Access tools using space-first routing!

"The routes are ready. The tools are waiting. Let's build!" πŸš€