Document VS Code extension and expand test coverage#409
Merged
Conversation
Add a /vscode-extension/ docs section (overview, installation with dynamic VSIX download link, configuration, features) parallel to the MCP Server section. Replace the placeholder activation test with a real Extension Host integration suite, fix the rootDir trap so unit tests can import production code directly, and add unit tests for WebDavMappingsProvider and SandboxConfigProvider. Extend ci-vs-extension.yml to also run on SDK changes and cache the .vscode-test binary.
- Drop unimplemented "Compare with Instance" diff from features.md and remove its placeholder image; the diffCartridge command is stub functionality. - Fix project-root pinning docs: "Use as B2C Commerce Root" only shows on a workspace-root folder when the workspace has more than one folder open; "Reset" is palette-only. - Replace internal-source pointer with an inline rule in the cloned sandbox indicators paragraph. - Add 24h TTL to the VSIX release data loader cache so a maintainer who cuts a release won't see a stale version on the next local docs build. - Include pnpm-lock.yaml in the .vscode-test cache key so a test-cli / test-electron version bump invalidates the cache. - Comment the activation test's command-registration check to explain why it doubles as a swallowed-failure detector. - Tidy webdav-mappings.test.ts stub.
Replace the invisible 1x1 PNG placeholders with per-slot SVG placeholders that render as dashed-border boxes with the slot title, description, and a "replace with <slot>.png" hint. Reviewers and the user can now see exactly where each screenshot belongs on the rendered page. Updated TODO comments to spell out the swap path (.svg -> .png) and added images/README.md with the replacement workflow.
Telemetry: - Wire SDK Telemetry into the VS Code extension (project=b2c-vs-extension) using the same App Insights connection string as the MCP server. - Lifecycle events (EXTENSION_ACTIVATED / DEACTIVATED / ACTIVATION_FAILED) plus per-command COMMAND_INVOKED with outcome and duration via registerSafeCommand. Exceptions reported through sendException. - Honors vscode.env.isTelemetryEnabled (telemetry.telemetryLevel) plus SFCC_DISABLE_TELEMETRY / SF_DISABLE_TELEMETRY. Persists anonymous cliId in globalStorageUri. Docs: - Lead Configuration with "Connecting to a B2C Instance" — a per-feature credential requirements table modeled on the CLI's per-command auth sections (sandbox.md, scapi-schemas.md). Adds an example dw.json with inline comments tagging each block to features. - Demote b2c-dx.* settings to a "Settings reference" section near the bottom with a clear "you usually don't need to change these" callout. - Add Telemetry section documenting what's collected, what's not, and three independent opt-out paths. - Add per-feature "Requires" callouts on every feature in features.md plus a top-of-page jump nav.
- initTelemetry is now fire-and-forget — client.start() runs in the background so activation never blocks on it. trackEvent() was already in-memory + batched, so subsequent sendEvent calls are non-blocking. - Drop per-command COMMAND_INVOKED events. Replace with FEATURE_USED, bucketed by broad category (sandbox/webdav/content/codeSync/apiBrowser/ debugger/scaffold/cap/pageDesigner/logs/instance) and deduped to one event per category per session. - Add b2c-dx.telemetry.enabled setting (default true). Telemetry is off if any of the three signals say off: VS Code's telemetry.telemetryLevel, this setting, or the SF/SFCC env var. - Strip the Telemetry section from the docs site — the setting's description in the VS Code Settings UI is the disclosure surface. Add the row to the configuration page's settings reference table. - Wire markFeatureUsed into the page-designer command and the script debugger factory so non-safety-wrapped features still register usage.
- Soften the intro and per-feature copy on index.md / installation.md; remove dw.json/SFCC_* jargon from outward-facing prose. - Reorder highlights and add screenshots for the three biggest ones (Sandbox Realm Explorer, Library Explorer, Script Debugger). Make highlight images clickable so the inline thumbnail can be expanded to the full-resolution capture. - Rename Cartridge Code Sync -> "Cartridge Management and Code Watch/ Upload"; add SCAPI API Explorer as a dedicated highlight. - Drop the Page Designer Assistant highlight; promote Scaffolding to a highlight in its place (covers cartridges, controllers, hooks, jobs). - Expand the Script Debugger blurb to call out controllers, jobs, custom scripts, SCAPI hooks, Custom APIs, breakpoints, and log points. - Delete features.md; fold Log Tailing, Active Instance Status Bar, and B2C CLI Plugin Support onto index.md and update sidebar / cross-links. - Drop Project Root Pinning from configuration.md (uncommon use case). - Mention the VS Code Extension on docs/guide/index.md with a quick- install block parallel to the CLI/MCP installs, using the existing release.data.ts loader.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Notes for reviewers
Test plan