Update: Extract ServerUtils static methods into lib/utils/ individual files (fixes #55)#56
Conversation
…al files (fixes #55) - Extract getAllRoutes, generateRouterMap, addExistenceProps, mapHandler, cacheRouteConfig into lib/utils/ - Add barrel file lib/utils.js re-exporting all utilities - Export utility functions as named exports from index.js - Update Router.js to import extracted utilities directly - Remove deprecated static methods from ServerUtils class (breaking) - Bump adapt-authoring-core dependency to ^2.0.0 - Add 5 new test files (utils-getAllRoutes, utils-generateRouterMap, utils-addExistenceProps, utils-mapHandler, utils-cacheRouteConfig) - Remove extracted method tests from ServerUtils.spec.js - 114 tests pass Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
github-actions bot
pushed a commit
that referenced
this pull request
Feb 21, 2026
# [2.0.0](v1.4.2...v2.0.0) (2026-02-21) ### Breaking * Extract ServerUtils static methods into lib/utils/ individual files (fixes #55) ([d7c7c11](d7c7c11)), closes [#55](#55) ### Update * Extract ServerUtils static methods into lib/utils/ individual files (fixes #55) (#56) ([6c083a3](6c083a3)), closes [#55](#55) [#56](#56)
|
🎉 This PR is included in version 2.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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
getAllRoutes,generateRouterMap,addExistenceProps,mapHandler,cacheRouteConfig) fromServerUtilsstatic class into individual files underlib/utils/lib/utils.jsand export utilities as named exports fromindex.jsRouter.jsto importaddExistenceProps,cacheRouteConfig,generateRouterMapdirectly instead of viaServerUtilsServerUtilsclass (breaking)adapt-authoring-coreto^2.0.0addErrorHandler,apiNotFoundHandler,methodNotAllowedHandler,genericErrorHandler,rootNotFoundHandler,debugRequestTime,handleInternalRoutes) stay onServerUtilsas they're coupled toApp.instanceTest plan
npm test)🤖 Generated with Claude Code