docs/imporve documentaions - #9
Merged
Merged
Conversation
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.
This pull request significantly improves the clarity, usability, and maintainability of the
jsontextlibrary by enhancing documentation, refactoring stream classes for better encapsulation, and clarifying constants and public APIs. The most important changes are grouped below:Documentation and Examples Improvements:
README.mdwith improved explanations, updated terminology (e.g., "structural symbol" instead of "delimiter"), and more practical usage examples, including a new section on replacingnullvalues in streams. Also reorganized and simplified example pipelines for better approachability. [1] [2] [3] [4] [5]JSONTextDecoderStream,JSONTextEncoderStream,JSONTextLineStream, andJSONTextSelectorStream) to clarify their purpose and usage. [1] [2] [3] [4]Stream Class Refactoring and API Consistency:
JSONTextDecoderStream,JSONTextEncoderStream,JSONTextLineStream,JSONTextSelectorStream) to use private decoder/encoder fields and internal drain methods, improving encapsulation, error handling, and code clarity. [1] [2] [3] [4]Constants and Types Clarification:
src/common/constants.ts, including ASCII codes, Unicode escapes, token kinds, default options, and JSON Path segment types, improving maintainability and discoverability. [1] [2] [3] [4] [5]API Documentation and Type Improvements:
Minor Fixes and Cleanups:
Valueinsrc/libs/stream-selector.tsto ensure proper type usage.These changes collectively make the library easier to use, more robust, and better documented for both new and experienced users.