-
Notifications
You must be signed in to change notification settings - Fork 538
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modernize codebase to take advantage of node.js 22(lts) #383
Comments
billchurch
added a commit
that referenced
this issue
Dec 11, 2024
billchurch
added a commit
that referenced
this issue
Dec 14, 2024
billchurch
added a commit
that referenced
this issue
Dec 14, 2024
billchurch
added a commit
that referenced
this issue
Dec 14, 2024
will there be library version of it, so i can just create node server and import library? Lastly, will there be easy way to import in React JS? Thanks. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Overview
This issue outlines the plan to upgrade the WebSSH2 server from Node.js v6.9.1 to v22.12.0 LTS. This modernization will improve code quality, reduce dependencies, and leverage modern Node.js features.
Current State Analysis
Key Dependencies to Update
[email protected]
→ Latest ([email protected]
)[email protected]
→ Latest ([email protected]
)[email protected]
→ Latest ([email protected]
)[email protected]
→ Latest ([email protected]
)Code Patterns Needing Modernization
Callback-based patterns in:
ssh.js
: SSH connection handlingsocket.js
: Socket.IO event handlingmiddleware.js
: Express middlewareCommonJS require statements throughout:
Older error handling patterns:
Modernization Tasks
Phase 1: Development Environment Setup
package.json
.nvmrc
file with Node.js 22.12.0node --watch
and remove nodemonPhase 2: Dependencies Update
webssh2_client
packagesocket.io-client
module to4.7.4
webssh2_client 8basic-auth
with native HTTP authenticationPhase 3: Code Modernization
3.1 Module System
3.2 Async/Await Implementation
Refactor SSH connection handling:
Update socket event handlers:
3.3 Native API Usage
3.4 Testing Updates
Phase 4: Security Enhancements
Phase 5: Documentation and Type Safety
Breaking Changes
Migration Strategy
Additional Considerations
Resources
Timeline Estimate
Total estimated time: 10 weeks
Please comment on this issue if you have questions or suggestions for the modernization plan.
The text was updated successfully, but these errors were encountered: