Skip to content
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

Overhaul typing support #1104

Closed
wants to merge 62 commits into from
Closed

Overhaul typing support #1104

wants to merge 62 commits into from

Conversation

jdalrymple
Copy link
Owner

@jdalrymple jdalrymple commented Aug 22, 2020

Summary

  • Updating camelCase and snake_case types to be handled conditionally
  • Expanding return types to show correct information and proper defaults if unset

Played around with conditional typing. Sorta based off this

Specific example here

fixes: #1088 #1306 #1482 #1218 #519

Update

Finally got the typing to work, next steps are:

  • Going through and implementing the new format throughout the services codebase
  • Updates tests to maintain 90% coverage
  • Verifying the typing information present with the Gitlab API Docs.
  • Double check typing information present with the Gitlab API Docs.
  • Double check connected issues have been solved
📦 Published PR as canary version: 29.0.0--canary.1104.301157685.0

✨ Test out this PR locally via:

npm install @gitbeaker/[email protected]
npm install @gitbeaker/[email protected]
npm install @gitbeaker/[email protected]
npm install @gitbeaker/[email protected]
npm install @gitbeaker/[email protected]
# or 
yarn add @gitbeaker/[email protected]
yarn add @gitbeaker/[email protected]
yarn add @gitbeaker/[email protected]
yarn add @gitbeaker/[email protected]
yarn add @gitbeaker/[email protected]

@jdalrymple jdalrymple added bug release:canary Deploy canary release labels Aug 22, 2020
@jdalrymple jdalrymple changed the title Experiment with extensions Fixing union types that are used to control camelCase and snake_case response objects Aug 22, 2020
@jdalrymple
Copy link
Owner Author

So this should technically work, but ill have to update alot more references i think.

@jdalrymple jdalrymple marked this pull request as draft August 22, 2020 12:39
@jdalrymple jdalrymple force-pushed the 1088-union-typing branch 2 times, most recently from e787947 to 4460a84 Compare October 13, 2020 22:34
@jdalrymple
Copy link
Owner Author

Having trouble sorting out the typings :( I posted up an example situation on SO to hopefully get some guidance

@jdalrymple jdalrymple removed the bug label Apr 4, 2021
@jdalrymple
Copy link
Owner Author

Finished the first pass, going to double check what has been added and include supplemental TODO's for the next PR

@jdalrymple
Copy link
Owner Author

Breaking this PR up into cleaner pieces

@jdalrymple jdalrymple closed this May 11, 2021
@jdalrymple jdalrymple deleted the 1088-union-typing branch May 14, 2021 14:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release:canary Deploy canary release
Projects
None yet
1 participant