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

[Feature Request]: Evaluate possible default flag values for @wordpress/scripts #110

Closed
1 task done
tyrann0us opened this issue Feb 20, 2024 · 0 comments · Fixed by #111
Closed
1 task done

[Feature Request]: Evaluate possible default flag values for @wordpress/scripts #110

tyrann0us opened this issue Feb 20, 2024 · 0 comments · Fixed by #111
Assignees
Labels
enhancement New feature or request

Comments

@tyrann0us
Copy link
Member

tyrann0us commented Feb 20, 2024

Is your feature request related to a problem?

The wp-scripts-lint.yml workflow does not hardcode default flag values, so whenever a *LINT_ARGS input is used, calling workflows must pass the default value, too. This is verbose, resulting in a lot of copying & pasting. Also, it's very error-prone because users just don't know they must add default values after their custom flags.

Describe the desired solution

It would be better if the reusable workflow would hardcode sensible default flag values. These would be appended after the *LINT_ARGS input.

Judging from this search: https://github.com/search?q=org%3Ainpsyde+OR+org%3AInpsyde-Global-Service-Provider+wp-scripts-lint+ARGS+language%3AYAML&type=code, the most often repeated flags are the following:

  • MARKDOWNLINT_ARGS: --ignore node_modules
  • STYLELINT_ARGS: --formatter github

Describe the alternatives that you have considered

Alternatively, we would update the documentation to warn users to always add defaults.

Additional context

It is unclear what value is used when a flag is both set with an input and with the following hardcoded flag.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Edit:
MARKDOWNLINT_ARGS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants