A modern Vue 3 + TypeScript frontend application for the Structures framework, providing a rich web interface for data management and administration.
Structures Frontend Next is the next-generation web interface for the Structures framework, built with:
- Vue 3: Modern reactive framework with Composition API
- TypeScript: Type-safe development experience
- Vite: Fast build tool and development server
- Tailwind CSS: Utility-first CSS framework
- Vue Router: Client-side routing
- Pinia: State management
- Modern UI: Clean, responsive design with Tailwind CSS
- Type Safety: Full TypeScript support throughout the application
- Authentication: OIDC integration with multiple providers (Okta, Keycloak, Microsoft, Google, GitHub)
- Multi-tenant Support: Tenant management and isolation
- Data Management: CRUD operations for structures and schemas
- GraphQL Integration: Native GraphQL client with type generation
- Responsive Design: Mobile-first approach with responsive components
- Theme Support: Customizable UI themes and components
npm install
# or
pnpm installCopy and edit the configuration file:
cp public/app-config.json.example public/app-config.jsonEdit public/app-config.json with your OIDC provider settings.
npm run dev
# or
pnpm devThe application will be available at http://localhost:5173
npm run build
# or
pnpm buildThe application supports runtime configuration through JSON files. See CONFIGURATION.md for detailed configuration options.
Supported authentication providers:
- Okta: Enterprise SSO
- Keycloak: Open-source identity management
- Microsoft Entra ID: Azure Active Directory
- Google: Google Workspace
- GitHub: GitHub OAuth
- Microsoft Social: Personal Microsoft accounts
- Apple: Apple ID
- Custom: Any OIDC-compliant provider
For development and testing, basic username/password authentication is available and configurable.
src/
├── components/ # Reusable Vue components
│ ├── modals/ # Modal dialogs
│ └── ... # Other component categories
├── layouts/ # Page layout components
├── pages/ # Route-based page components
├── plugins/ # Vue plugins and extensions
├── states/ # Pinia state management
├── theme/ # UI theme configuration
├── types/ # TypeScript type definitions
├── util/ # Utility functions
└── main.ts # Application entry point
- Node.js 18+
- npm or pnpm
- Modern web browser
# Install dependencies
pnpm install
# Start development server
pnpm dev
# Start development server with kind cluster config
pnpm dev:kind
# Build for production
pnpm build
# Build for kind cluster deployment
pnpm build:kind
# Preview production build
pnpm preview
# Preview kind cluster build
pnpm preview:kind
# Run type checking
pnpm type-check
# Run linting
pnpm lint- Use TypeScript for all new code
- Follow Vue 3 Composition API patterns
- Use Tailwind CSS for styling
- Implement responsive design principles
- Write unit tests for components
# Run unit tests
pnpm test
# Run tests in watch mode
pnpm test:watch
# Generate coverage report
pnpm test:coverage# Run end-to-end tests
pnpm test:e2e
# Run E2E tests in UI mode
pnpm test:e2e:uiThe application builds to static files that can be hosted on any web server:
- Build the application:
pnpm build - Deploy the
dist/folder to your web server - Ensure the configuration file is accessible at
/app-config.json
FROM nginx:alpine
COPY dist/ /usr/share/nginx/html/
COPY nginx.conf /etc/nginx/nginx.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]The application supports environment-specific configuration through Vite's environment variable system.
Configure the WebSocket connection to the Structures server using these environment variables:
| Variable | Description | Default |
|---|---|---|
VITE_CONTINUUM_HOST |
WebSocket server hostname | 127.0.0.1 (auto-detected from window.location if deployed) |
VITE_CONTINUUM_PORT |
WebSocket server port | 58503 |
VITE_CONTINUUM_USE_SSL |
Use secure WebSocket (wss://) | false (auto-detected from window.location if deployed) |
The application uses multiple .env files for different deployment scenarios:
.env: Base configuration for production/deployed builds.env.development: Development overrides (used withnpm run dev).env.kind: Kind cluster overrides (used withnpm run dev:kind).env.local: Local overrides (gitignored, highest precedence)
Example: Connect to Kind cluster NodePort directly
Create a .env.local file:
VITE_CONTINUUM_HOST=127.0.0.1
VITE_CONTINUUM_PORT=30503 # Direct NodePort access
VITE_CONTINUUM_USE_SSL=falseOr use the provided mode:
npm run dev:kindFor build-time configuration, you can use environment variables:
VITE_API_BASE_URL=https://api.example.com
VITE_APP_TITLE=Structures Admin- Pinia: Centralized state management
- Composables: Reusable logic with Vue Composition API
- Local Storage: Persistent user preferences
- Vue Router: Client-side routing with lazy loading
- Route Guards: Authentication and authorization checks
- Dynamic Routes: Tenant-specific routing
- GraphQL: Primary data interface
- REST: Fallback and file operations
- WebSocket: Real-time updates (if configured)
- Follow the existing code conventions
- Use TypeScript for all new code
- Write tests for new functionality
- Update documentation as needed
- Ensure responsive design principles
-
Authentication Errors
- Check OIDC provider configuration
- Verify redirect URIs match
- Check browser console for errors
-
Build Errors
- Clear node_modules and reinstall
- Check TypeScript configuration
- Verify all dependencies are compatible
-
Runtime Errors
- Check browser console for errors
- Verify API endpoints are accessible
- Check network connectivity
Enable debug logging in the configuration:
{
"debug": true
}- Configuration Guide - Detailed configuration options
- Structures Server - Backend server documentation
- Structures Core - Core library documentation
This application is part of the Structures framework and follows the same licensing terms.