feat: add @wolfstar/plugin-subcommands-advanced - #17
Merged
Conversation
Port modular slash-subcommand classes from @kaname-png/plugin-subcommands-advanced to @wolfstar/http-framework, with wiring via CommandLoaderStrategy and tests using http-framework-test-utils.
Add scripts/tsdown.config.ts and tsconfig.build.json, switch both packages to `tsdown` with dist/esm output, and drop the build.mjs workaround.
RedStar071
marked this pull request as ready for review
July 29, 2026 11:45
The reusable label-sync workflow merges this file with the shared sapphiredev/.github core labels, but it was missing here, causing the workflow to fail (open overwrite-labels/.github/labels.yml: no such file or directory).
This reverts commit 44bd704.
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
Adds
@wolfstar/plugin-subcommands-advanced, adapted from@kaname-png/plugin-subcommands-advancedfor@wolfstar/http-framework.Slash subcommands (and groups) can live in separate command classes instead of methods on a single parent class.
API
Subcommand— parent chat-input commandCommand— child withregisterSubCommand/registerSubcommandInGroupoptions@RegisterAsSubcommand/@RegisterAsSubcommandGroup— class decorators@wolfstar/plugin-subcommands-advanced/register— installs aCommandLoaderStrategythat wires children onto the parent after pieces are constructedBuild tooling
scripts/tsdown.config.ts(same pattern as stars-components)tsdown→dist/esm/tsconfig.build.jsonfor declaration emit used by tsdownTesting / tooling
@wolfstar/http-framework-test-utilsTest plan
pnpm build(both packages via shared tsdown config)pnpm typecheckpnpm test(24 tests)pnpm lintNeed help on this PR? Tag
@codesmith-botwith what you need. Autofix is enabled.Confidence Score: 3/5
The PR is not yet clearly safe to merge because preservation of framework-native subcommand handler mappings remains unverified.
The rebuilt resolver relies on recovering non-enumerable handler-link symbols from
toJSON()output, but the available implementation evidence does not establish that serialization retains those symbols or that null links remain routable.Files Needing Attention: packages/plugin-subcommands-advanced/src/lib/utils/wiring.ts
What T-Rex did
Reviews (6): Last reviewed commit: "Merge branch 'main' into cursor/plugin-s..." | Re-trigger Greptile