Remove hash from URLs (/#/login -> /login) using usePathUrlStrategy(). Uses conditional imports to only apply on web, keeping mobile/desktop builds unaffected. Required for OIDC callback to work - Authentik redirects to /callback which Flutter now recognizes as a route. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
11 lines
299 B
Dart
11 lines
299 B
Dart
/// Web-specific URL strategy configuration.
|
|
library;
|
|
|
|
import 'package:flutter_web_plugins/url_strategy.dart';
|
|
|
|
void configureUrlStrategy() {
|
|
// Use path-based URLs instead of hash-based (e.g., /login instead of /#/login)
|
|
// Required for OIDC callback to work properly
|
|
usePathUrlStrategy();
|
|
}
|