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

Configure code style #98

Merged
merged 37 commits into from
Oct 31, 2023
Merged

Configure code style #98

merged 37 commits into from
Oct 31, 2023

Conversation

kbighorse
Copy link
Contributor

Changes proposed in this pull request:

security considerations

[Note the any security considerations here, or make note of why there are none]

package.json Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
@adunkman
Copy link
Member

(Unsubscribing from this to prevent email noise on new commits — re-ping me if I need to look at it)

-- What
This rule (https://eslint.org/docs/latest/rules/no-param-reassign)
specifies that you cannot reassign a variable that is passed into a
function as a parameter (good, makes sense), but for some reason it
also says that you cannot alter properties of an incoming variable if
it's an object (bad, doesn't make sense).

Updating the eslintrc file to account for this
Also updating the airbnb base linter config version
.eslintrc.json Outdated Show resolved Hide resolved
@kbighorse kbighorse marked this pull request as ready for review October 27, 2023 20:44
@kbighorse kbighorse requested a review from a team as a code owner October 27, 2023 20:44
package.json Outdated Show resolved Hide resolved
Seeing if this helps with websocket errors
-- What
We do not need to specify the extensions in the command line for the
eslint runner (if we need specific extensions only in the future, we
can add these into the config file where they belong).

Additionally, found a bad situation where eslint was reading from the
site build directory if a local build it present, which resulted in
tens of thousands of errors as a result of transpiled code from
external libraries. Have added config values to ignore the build directory.
package.json Outdated Show resolved Hide resolved
Copy link
Contributor

@echappen echappen left a comment

Choose a reason for hiding this comment

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

Thank you both for your work on this! I have a few blocking questions about where dev dependencies are being loaded. Could we also add some written documentation about our linting strategy (why we're doing it, what rules we're using, when in the pipeline it runs, etc).

package.json Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
.github/workflows/pull-request.yml Show resolved Hide resolved
@eric-gade
Copy link
Contributor

@echappen I think I've addressed each of your concerns. I've added some documentation about prettier, as well as our own template precommit hook. The linter forced me to move certain dependencies back to production, but I think that makes sense. Let me know if there's anything else that looks off. Thanks!

Copy link
Contributor

@echappen echappen left a comment

Choose a reason for hiding this comment

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

Looks great, thanks!

@eric-gade eric-gade merged commit 116f40d into main Oct 31, 2023
5 checks passed
@eric-gade eric-gade deleted the configure-code-style branch October 31, 2023 16:09
@kbighorse
Copy link
Contributor Author

great work all!

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.

5 participants