-
Notifications
You must be signed in to change notification settings - Fork 315
chore: enhance pagination API with improved type safety #1226
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
Merged
Merged
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,136 @@ | ||
| # Contributing | ||
|
|
||
| Thanks for your interest in contributing to this SDK! This document provides guidelines for contributing to the project. | ||
|
|
||
| ## Getting Started | ||
|
|
||
| ### Prerequisites | ||
|
|
||
| - Node.js 20 or higher | ||
| - yarn package manager | ||
|
|
||
| ### Installation | ||
|
|
||
| Install the project dependencies: | ||
|
|
||
| ```bash | ||
| yarn install | ||
| ``` | ||
|
|
||
| ### Building | ||
|
|
||
| Build the project: | ||
|
|
||
| ```bash | ||
| yarn build | ||
| ``` | ||
|
|
||
| ### Testing | ||
|
|
||
| Run the test suite: | ||
|
|
||
| ```bash | ||
| yarn test | ||
| ``` | ||
|
|
||
| Run specific test types: | ||
|
|
||
| - `yarn test:unit` - Run unit tests | ||
| - `yarn test:wire` - Run wire/integration tests | ||
|
|
||
| ### Linting and Formatting | ||
|
|
||
| Check code style: | ||
|
|
||
| ```bash | ||
| yarn run lint | ||
| yarn run format:check | ||
| ``` | ||
|
|
||
| Fix code style issues: | ||
|
|
||
| ```bash | ||
| yarn run lint:fix | ||
| yarn run format:fix | ||
| ``` | ||
|
|
||
| Or use the combined check command: | ||
|
|
||
| ```bash | ||
| yarn run check:fix | ||
| ``` | ||
|
|
||
| ## About Generated Code | ||
|
|
||
| **Important**: Most files in this SDK are automatically generated by [Fern](https://buildwithfern.com) from the API definition. Direct modifications to generated files will be overwritten the next time the SDK is generated. | ||
|
|
||
| ### Generated Files | ||
|
|
||
| The following directories contain generated code: | ||
|
|
||
| - `src/api/` - API client classes and types | ||
| - `src/serialization/` - Serialization/deserialization logic | ||
| - Most TypeScript files in `src/` | ||
|
|
||
| ### How to Customize | ||
|
|
||
| If you need to customize the SDK, you have two options: | ||
|
|
||
| #### Option 1: Use `.fernignore` | ||
|
|
||
| For custom code that should persist across SDK regenerations: | ||
|
|
||
| 1. Create a `.fernignore` file in the project root | ||
| 2. Add file patterns for files you want to preserve (similar to `.gitignore` syntax) | ||
| 3. Add your custom code to those files | ||
|
|
||
| Files listed in `.fernignore` will not be overwritten when the SDK is regenerated. | ||
|
|
||
| For more information, see the [Fern documentation on custom code](https://buildwithfern.com/learn/sdks/overview/custom-code). | ||
|
|
||
| #### Option 2: Contribute to the Generator | ||
|
|
||
| If you want to change how code is generated for all users of this SDK: | ||
|
|
||
| 1. The TypeScript SDK generator lives in the [Fern repository](https://github.com/fern-api/fern) | ||
| 2. Generator code is located at `generators/typescript/sdk/` | ||
| 3. Follow the [Fern contributing guidelines](https://github.com/fern-api/fern/blob/main/CONTRIBUTING.md) | ||
| 4. Submit a pull request with your changes to the generator | ||
|
|
||
| This approach is best for: | ||
|
|
||
| - Bug fixes in generated code | ||
| - New features that would benefit all users | ||
| - Improvements to code generation patterns | ||
|
|
||
| ## Making Changes | ||
|
|
||
| ### Workflow | ||
|
|
||
| 1. Create a new branch for your changes | ||
| 2. Make your modifications | ||
| 3. Run tests to ensure nothing breaks: `yarn test` | ||
| 4. Run linting and formatting: `yarn run check:fix` | ||
| 5. Build the project: `yarn build` | ||
| 6. Commit your changes with a clear commit message | ||
| 7. Push your branch and create a pull request | ||
|
|
||
| ### Commit Messages | ||
|
|
||
| Write clear, descriptive commit messages that explain what changed and why. | ||
|
|
||
| ### Code Style | ||
|
|
||
| This project uses automated code formatting and linting. Run `yarn run check:fix` before committing to ensure your code meets the project's style guidelines. | ||
|
|
||
| ## Questions or Issues? | ||
|
|
||
| If you have questions or run into issues: | ||
|
|
||
| 1. Check the [Fern documentation](https://buildwithfern.com) | ||
| 2. Search existing [GitHub issues](https://github.com/fern-api/fern/issues) | ||
| 3. Open a new issue if your question hasn't been addressed | ||
|
|
||
| ## License | ||
|
|
||
| By contributing to this project, you agree that your contributions will be licensed under the same license as the project. | ||
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this expected? Feels a bit generic to request people to contact Fern instead of Auth0 in case of questions or issues.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated a bit!