Cloudfront-Master
A VS Code extension for efficient development with the Cloudfront app framework.
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.
- Default Environment — Set a default environment that is automatically restored after clearing templates.
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.
- Build Template — Run build-template without clearing templates first.
- Clear Templates — Remove all templates except default (with environment reset).
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) |
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 |
License
Proprietary. See LICENSE.md.
| |