Repository navigation
chore: make TOON dependency optional - #2260
Merged
Merged
Conversation
Lightning00Blade
approved these changes
Jun 25, 2026
samiyac
pushed a commit
to bcfmtolgahan/chrome-devtools-mcp
that referenced
this pull request
Jun 29, 2026
Since toon dependency is only needed for `--experimentalToonFormat` flag, we can make it optional to decrease package size and security footprint for users that don't use it. Testing npx optional peer dependency resolution before the release: ``` npm i -g verdaccio verdaccio ``` On a separate terminal: ``` npm adduser --registry http://localhost:4873/ # follow prompts to create user and login # replace the published package in verdaccio npm unpublish [email protected] --force --registry http://localhost:4873 npm publish --registry http://localhost:4873 # clear npx cache rm -rf ~/.npm/_npx # run the server from commandline and observe both packages being installed: npx --registry http://localhost:4873 --package chrome-devtools-mcp@latest --package @toon-format/toon chrome-devtools-mcp --experimentalToonFormat ``` Paste the following commands (each line separately) to manually interact with the mcp server and observe TOON formatted response directly ### 1. Initialize the session {"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"test-client","version":"1.0.0"}}} ### 2. Confirm initialization {"jsonrpc":"2.0","method":"notifications/initialized"} ### 3. Navigate to Google (this will already create snapshot in most recent versions) {"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"navigate_page","arguments":{"url":"https://google.com"}}} ### 4. Take Snapshot (if not returned by the previous command) {"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"take_snapshot","arguments":{}}} --------- Co-authored-by: Piotr Paulski <[email protected]>
blackwell-systems
added a commit
to blackwell-systems/chrome-devtools-mcp
that referenced
this pull request
Jun 30, 2026
Address review feedback from ChromeDevTools#2235: 1. Replace two boolean flags (experimentalToonFormat, experimentalGcfFormat) with a single --experimentalDataFormat=json|toon|gcf enum. The legacy --experimentalToonFormat flag still works via fallback for backward compatibility. 2. Make @blackwell-systems/gcf an optional peer dependency following the same pattern established for @toon-format/toon in ChromeDevTools#2260. Uses dynamic import() so the package is only loaded when the format is requested. 3. Resolve format choice into a single compactEncode function at the top of format(), eliminating the dual-boolean checks throughout. 4. Add @blackwell-systems/gcf to rollup externals. 5. Regenerate package-lock.json.
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.
Since toon dependency is only needed for
--experimentalToonFormatflag, we can make it optional to decrease package size and security footprint for users that don't use it.Testing npx optional peer dependency resolution before the release:
On a separate terminal:
Paste the following commands (each line separately) to manually interact with the mcp server and observe TOON formatted response directly
1. Initialize the session
2. Confirm initialization
3. Navigate to Google (this will already create snapshot in most recent versions)
4. Take Snapshot (if not returned by the previous command)