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

Enforce some naming conventions #4813

Merged
merged 1 commit into from
Mar 1, 2022
Merged

Conversation

Nokel81
Copy link
Collaborator

@Nokel81 Nokel81 commented Feb 3, 2022

  • No type may be called "Props" or "State" (must be more descriptive). This is necessary for better documentation
  • Enforce the majority preference to interface declarations over type for object types.
  • Require that interfaces and type declarations must be PascalCase.

@Nokel81 Nokel81 added the chore label Feb 3, 2022
@Nokel81 Nokel81 requested a review from a team as a code owner February 3, 2022 21:46
@Nokel81 Nokel81 requested review from jweak and Iku-turso and removed request for a team February 3, 2022 21:46
@github-actions
Copy link
Contributor

github-actions bot commented Feb 8, 2022

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions
Copy link
Contributor

github-actions bot commented Feb 8, 2022

Conflicts have been resolved. A maintainer will review the pull request shortly.

@github-actions
Copy link
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

…over type

- Also export all prop types

Signed-off-by: Sebastian Malton <sebastian@malton.name>
@Nokel81 Nokel81 force-pushed the enforce-naming-convension branch from 059a56c to a8c5979 Compare February 18, 2022 15:53
@Nokel81 Nokel81 added this to the 5.5.0 milestone Feb 18, 2022
@github-actions
Copy link
Contributor

Conflicts have been resolved. A maintainer will review the pull request shortly.

tabId: TabId;
submit?: () => Promise<ReactNode | string | void>;
}

interface OptionalProps {
export interface OptionalProps {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
export interface OptionalProps {
export interface InfoPanelOptionalProps {

?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll do that in a follow up PR.

@@ -32,7 +32,7 @@ enum columnId {
}

@observer
export class CrdList extends React.Component {
export class CustomResourceDefinitions extends React.Component {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this a breaking change?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, because it is not exported

@Nokel81 Nokel81 merged commit 0b32775 into master Mar 1, 2022
@Nokel81 Nokel81 deleted the enforce-naming-convension branch March 1, 2022 18:06
DmitriyNoa pushed a commit that referenced this pull request Mar 3, 2022
Signed-off-by: DmitriyNoa <dmytro.zharkov@gmail.com>
@Nokel81 Nokel81 mentioned this pull request May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants