Cloudfront-Master
A VS Code extension for efficient development with the Cloudfront app framework — and for switching backend setups in the Projects3 (Cloud Software backend) workspace.
Features
Template Sync
- Auto-Sync on Save — Automatically syncs changes between source templates and the generated template (
libs/shared/src/template). Detects conflicts and offers Compare / Force Overwrite options.
- External Change Detection — Monitors file changes made outside VS Code (e.g. by AI tools or CLI) and triggers sync automatically. Configurable response time.
- Batch Sync — Sync a single component, an entire template, or all templates at once via tree view buttons.
- Force Sync — Right-click any resource file to force-sync it to the generated template.
Templates & Components Tree View
- Template Overview — Lists all installed templates sorted by priority, with their components, pipes, and gallery-slide-components.
- Resource Search (
Ctrl+Shift+F6) — Quickly find and open resources and files across all templates. Results are sorted by proximity to the currently open file.
- Unreferenced File Detection — Files on disk but not in
template.config.json are shown grayed out, with QuickFix to add them.
- Show Unreferenced Components — Lists every component folder and file that no template config references, across all templates; select one to open it.
- Sync Drift Badge — Source template files that differ from their generated counterpart are badged in the Explorer and the tree view.
- Create in Template — Copy files from one template into another via right-click, automatically updating
template.config.json.
- Delete Template — Remove an entire template folder via trash icon in the tree view.
- Context Menu — Copy Path, Reveal in Explorer, Force Sync on resource files.
Component Generator
- Guided Wizard — Create new components via command palette or tree view button. Walks through template selection, naming, base class, copy mode, and optional designer integration.
- Designer Integration — Generates GsStruct interface, form schema, and registers in PageComponentsHelper (incl. icon type and bcModules selection).
Config Validation & Auto-Completion
- Template Config Linter — Validates
template.config.json with VS Code Diagnostics: missing files, undeclared resources on disk, containerGallery settings, itemOverlayImages, environments, and more.
- QuickFixes — Add unreferenced files to config, remove missing files from config, fix validation issues.
- Auto-Completion — Context-aware completions for keys, resource names, file paths, copyMode values, and containerGallery settings.
Code Linting
- Color Class Linter — Warns when using cloudfront colors in designer context (missing
d- prefix) or vice versa, with quick-fix to swap the prefix.
- Font Class Linter — Warns when hardcoding Tailwind font classes (e.g.
font-source-sans-3) in the default template. Fonts should be set via tag classes in the configurator. Quick-fix to remove the class.
- Angular Structure Linter — Enforces the team's class structure conventions in
.component.ts and .service.ts files: section comments in correct order, access modifier ordering, no constructor DI, no empty lifecycle methods. Quick-fixes available.
Color Preview
- Inline Color Indicators — Template color classes (e.g.
text-danger-main, bg-primary-shine) are shown with a colored square in the editor.
- Backend-Aware — Colors are loaded from the backend via
environment.json → BACKEND_URL, with fallback to a default palette.
Environment Management
- Save / Load / Delete — Snapshot the current
environment.json values and restore them later. Supports ENVIRONMENT, BACKEND_URL, CHANNEL_ID, DEFAULT_CULTURE, and more.
- With Template Repos — Optionally save the template repos with an environment and restore them when loading it.
- Quick Switch (
Ctrl+Shift+F7) — Switch environments from a search field; the list in the sidebar can be filtered too (Ctrl+F).
- Default Environment — Mark a default via the star icon; it is restored after clearing templates.
- Tracking & Local Backend Switches — Toggle tracking and flip between the local and the remote backend with one click.
- Schema Support — Editing
environment.json suggests the available settings and flags unknown values.
Backend Environments (Projects3)
- Own View — Opening the Projects3 workspace shows a Backend Environments list.
- Save / Load / Delete — Save the current Business Central checkout and switch back to it with one click.
- Template Restore — A backend environment can keep its template and bring it back when it is missing.
- Reset — Reset the backend config to "nothing checked out".
AI Assistants (MCP)
- Built-in MCP Server — Copilot agent mode, Claude Code and Claude Desktop can use the Cloudfront tools; registration happens automatically.
- Tools — List templates, read configs, search resources, validate and lint files, create components, switch or reset environments, look up backend colors and get the right
nx command.
- Context — Conventions, installed templates and the current environment (secrets masked) are provided as ready-to-use context.
Branch Watching & Notifications
- Template Branch Watcher — Detects when a template's git branch changes and prompts for a rebuild.
- Project Branch Watcher — Detects when the main project branch changes.
- Configurable Notifications — Each notification type (template added/removed, branch changed, sync conflict) can be toggled individually.
- Serve / Debug / Test — Launch any app directly from the tree view. Debug uses the matching VS Code launch configuration.
- Run Status — Apps that are actually being served are marked as running, no matter how they were started.
- Build Template — Run build-template without clearing templates first.
- Clear Templates — Remove all templates except default (with environment reset).
What's New
- Changelog Page — After a feature update, a "What's New" page lists everything that changed since your last version.
- Show Changelog — Open the full changelog at any time via
Cloudfront-Master: Show Changelog.
Extension Settings
| Setting |
Default |
Description |
enabled |
true |
Enable/disable the extension |
workspaceFolderName |
"" |
Workspace folder name (auto-detects if empty) |
autoCopyOnRiskySave |
true |
Auto-sync on save in template folders |
logLevel |
info |
Log level (info / debug) |
colorPreview.enabled |
true |
Show color indicators next to template color classes |
angularStructureLinter.enabled |
true |
Enable/disable the Angular structure linter |
externalChangeDetection |
balanced |
Response time for external file change detection (fast / balanced / performant / off) |
localBackendUrl |
https://localhost:44336 |
Backend URL used by the local backend switch |
autoRegisterMcp |
true |
Register the MCP server with Claude Code and Claude Desktop automatically |
showChangelogOnUpdate |
true |
Open the "What's New" page after a feature update |
notifications.templateAdded |
true |
Notify when a template is added |
notifications.templateRemoved |
true |
Notify when a template is removed |
notifications.templateBranchChanged |
true |
Notify when a template switches branch |
notifications.projectBranchChanged |
true |
Notify when the project branch changes |
notifications.syncConflict |
true |
Notify on sync conflicts |
Keyboard Shortcuts
| Shortcut |
Command |
Ctrl+Shift+F6 |
Search resources across all templates |
Ctrl+Shift+F7 |
Switch environment |
Ctrl+F (in the Actions view) |
Filter environments |
License
Proprietary. See LICENSE.md.
| |