**refactor(cli): remove obsolete command and streamline TextEncoder/TextDecoder usage**

- Removed the `test-tensorflow-textencoder` command from `cli.ts` as part of deprecating redundant tests and unused CLI functionality.
- Simplified `TextEncoder` and `TextDecoder` definitions in `brainy-wrapper.js` by replacing direct constructor usage with shorthand properties within a utility object.

This refactor reduces unnecessary complexity in CLI commands and improves maintainability by aligning with current project goals and streamlined test structure.
This commit is contained in:
David Snelling 2025-07-15 11:52:54 -07:00
parent a4072cf3c0
commit c275d86e56
2 changed files with 3 additions and 18 deletions

View file

@ -31,9 +31,9 @@ if (
isTypedArray: (arr) => {
return !!(ArrayBuffer.isView(arr) && !(arr instanceof DataView))
},
// Use native TextEncoder and TextDecoder
TextEncoder: TextEncoder,
TextDecoder: TextDecoder
// Instead of using constructors directly, create a utility object with constructors
TextEncoder,
TextDecoder
}
// Initialize TextEncoder/TextDecoder instances