-
Notifications
You must be signed in to change notification settings - Fork 63
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 export of crds constants into typescript model #1619
Conversation
Signed-off-by: Valeriy Svydenko <vsvydenk@redhat.com>
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.
/lgtm
I've been testing the suggested fix. I can confirm that the index.ts
now includes the export of the constants.
More detailed, by running the bash build/typescript-models/generate.sh
I see the following in index.ts
:
export * from "./http/http";
export * from "./auth/auth";
export * from "./models/all";
export { createConfiguration } from "./configuration"
export { Configuration } from "./configuration"
export * from "./apis/exception";
export * from "./servers";
export { RequiredError } from "./apis/baseapi";
export { PromiseMiddleware as Middleware } from './middleware';
export { } from './types/ObjectParamAPI';
export * from './constants/constants';
While on the main
branch we have two separate files:
- The
api.ts
containing only the constants
export * from './constants/constants';
- And the
index.ts
with the rest.
export * from "./http/http";
export * from "./auth/auth";
export * from "./models/all";
export { createConfiguration } from "./configuration"
export { Configuration } from "./configuration"
export * from "./apis/exception";
export * from "./servers";
export { RequiredError } from "./apis/baseapi";
export { PromiseMiddleware as Middleware } from './middleware';
export { } from './types/ObjectParamAPI';
/hold
As the PR needs a review from one of the codeowners too.
@yangcao77 @johnmcollier could you take a look please |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: ibuziuk, johnmcollier, svor, thepetk The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@thepetk I think we can merge it now. And it would be nice to have a new version of devfile/api on npm registry |
@svor sorry I'm on PTO atm. @johnmcollier thanks for merging it :) |
What does this PR do?
Currently it is not possible to import constants from crds when using devfile/api library.
This PR adds export of crds constants into index.ts that is declared as a exported file in package.json.
Which issue(s) does this PR fix
eclipse-che/che#23041
PR acceptance criteria
Testing and documentation do not need to be complete in order for this PR to be approved. We just need to ensure tracking issues are opened.
Unit/Functional tests
QE Integration test
Documentation
Client Impact
How to test changes / Special notes to the reviewer
Check that crds constants are added into exports