-
Notifications
You must be signed in to change notification settings - Fork 17
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
Add more exports to client #507
Conversation
|
||
export { ActionValidationError } from "./actions/ActionValidationError.js"; | ||
export { isOk } from "./ResultOrError.js"; |
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.
So we originally exporting this which I don't think we're actually using anywhere?
export function isOk(result: ResultOrError<any>): result is { type: "ok" } { |
export function isOk<X>(a: Result<X>): a is OkResult<X> { |
export { PalantirApiError } from "@osdk/shared.net.errors"; | ||
|
||
export type { Client } from "./Client.js"; | ||
export { createClient } from "./createClient.js"; | ||
export { createPlatformClient } from "./createPlatformClient.js"; | ||
|
||
export { createAttachmentFromRid } from "./createAttachmentFromRid.js"; | ||
export { createAttachmentUpload } from "./object/AttachmentUpload.js"; |
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.
Need this if someone wants to upload a blob to an action. The AttachmentUpload
type should also accept the File object from FileApi but we need to provide this helper for now because that doesn't come standard yet
WhereClause, | ||
} from "@osdk/client.api"; | ||
|
||
export { isOk } from "@osdk/client.api"; |
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.
See below on why this got swapped
@@ -27,16 +27,19 @@ export type { | |||
OsdkActionParameters, | |||
OsdkObject, | |||
PageResult, | |||
Result, |
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.
If someone uses fetchPageWithError
the type is wrapped with Result
, so thought it best to expose here
No description provided.