Skip to content

Improve TypeScript experience in SDK v3 #416

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

Closed
hossam-nasr opened this issue Jan 9, 2023 · 3 comments
Closed

Improve TypeScript experience in SDK v3 #416

hossam-nasr opened this issue Jan 9, 2023 · 3 comments
Assignees
Labels
Enhancement New feature or request preview-blocker issues required for v3 public preview programming model 🚀 types issues related to types v3 Issues related to v3 of the package to support the new programming model
Milestone

Comments

@hossam-nasr
Copy link
Contributor

hossam-nasr commented Jan 9, 2023

Based on discussions here and here, and related to issues #240 and #171.

The SDK has had some gaps in its support for TypeScript and exporting types (see #240, #171, and #352).

SDK v3 and support for the new programming model is a good chance to improve our types story and our TypeScript experience, which includes, but is not limited to:

  1. Ensuring all necessary types (e.g., type for orchestration and entity contexts) are exported from the root of the package (Add more exported types #171)
  2. Enrich and expand existing types (e.g., further define the OrchestrationHandler type)
  3. Ensure no publicly exported types have the I prefix
  4. Create TypeScript-specific samples and templates
  5. Strongly type our TypeScript code samples and docs
@hossam-nasr
Copy link
Contributor Author

hossam-nasr commented Feb 2, 2023

Discussed some offline. As part of this, we should also try to switch from autogeneration of .d.ts files, to manual authoring of them. This should would help us become more intentional about which types we export, and also address #352. To do this, we should:

  1. Move all types/interfaces that we should expose publicly to the types directory (in normal .ts files)
  2. Separate class implementations from declarations, and move declarations to the types directory (also in .ts files)
  3. Switch to manual .d.ts file generation

Work for points 2 and 3 is already being done

@hossam-nasr
Copy link
Contributor Author

hossam-nasr commented Feb 9, 2023

Closed by PRs: #446, #447, #450, #451, #470
Issues: #458, #455, #352

@hossam-nasr hossam-nasr added this to the V3 Preview milestone Feb 9, 2023
@ejizba
Copy link
Contributor

ejizba commented Feb 9, 2023

NOTE: We removed the "breaking-change" label for this particular issue because I wanted to track each breaking change individually instead of in a roll-up issue. See Hossam's links above

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New feature or request preview-blocker issues required for v3 public preview programming model 🚀 types issues related to types v3 Issues related to v3 of the package to support the new programming model
Projects
None yet
Development

No branches or pull requests

2 participants