Skip to content

style: add additional style rules, organize eslintrc, & apply fixes#68

Merged
devonzara merged 2 commits into
mainfrom
dz-additional-style-rules
Mar 28, 2023
Merged

style: add additional style rules, organize eslintrc, & apply fixes#68
devonzara merged 2 commits into
mainfrom
dz-additional-style-rules

Conversation

@devonzara

@devonzara devonzara commented Mar 27, 2023

Copy link
Copy Markdown
Collaborator

Closes N/A

Description

Add some additional style rules, organize the eslintrc, & apply style fixes.

// Ensure there is no space before and 1 space after commas.
// eg. [1, 2] not [1 ,2] or [1,2]
// https://eslint.org/docs/latest/rules/comma-spacing
'comma-spacing': 'error',

// Ensure there is only ever 1 consecutive empty line.
// https://eslint.org/docs/latest/rules/no-multiple-empty-lines
'no-multiple-empty-lines': ['error', { max: 1, maxEOF: 1 }],

// Ensure there is 1 empty line after the last import statement.
// https://github.com/import-js/eslint-plugin-import/blob/main/docs/rules/newline-after-import.md
'import/newline-after-import': 'error',

// Ensure there is 1 empty line above export statements.
// https://eslint.org/docs/latest/rules/padding-line-between-statements
'padding-line-between-statements': [
  'error',
  { blankLine: 'always', prev: '*', next: 'export' },
  { blankLine: 'any', prev: 'export', next: 'export' },
],

Testing

N/A

Type of change

Please remove all except for everything applicable, and then remove this line.

  • Other (styles rules/fixes)

Screenshots

N/A

Checklist:

  • Changes have new/updated automated tests, if applicable
  • Changes have new/updated docs, if applicable
  • I have performed a self-review of my own code
  • I have added comments on any new, hard-to-understand code
  • Changes have been manually tested
  • Changes generate no new errors or warnings

@MainlyColors MainlyColors left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

@windyScripts windyScripts left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

LGTM

@Caleb-Cohen

Copy link
Copy Markdown
Collaborator

Screenshot 2023-03-28 at 11 41 10 AM

I'm hitting this lint error when testing this PR.

@devonzara

Copy link
Copy Markdown
Collaborator Author

@Caleb-Cohen Pretty sure you just need to run npm install, I don't believe that to be an error resulting from anything new in this PR.

@devonzara devonzara merged commit db0d77c into main Mar 28, 2023
@devonzara devonzara deleted the dz-additional-style-rules branch March 28, 2023 21:22
@devonzara devonzara mentioned this pull request Mar 29, 2023
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants