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

stylelint test #17

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/workflows/reviewdog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,21 @@ jobs:
github_token: ${{ github.token }}
reporter: "github-pr-review"
fail_on_error: true

stylelint:
name: runner / stylelint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- run: npm ci
working-directory: ./stylelint
- name: stylelint
uses: reviewdog/action-stylelint@v1
with:
reporter: github-pr-review
stylelint_input: '*.css'
workdir: 'stylelint'
fail_on_error: true
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
3 changes: 3 additions & 0 deletions stylelint/.stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": "stylelint-config-recommended"
}
6 changes: 6 additions & 0 deletions stylelint/index.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
a { color: #y3 }
Copy link

Choose a reason for hiding this comment

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

🚫 [stylelint] reported by reviewdog 🐶
Unexpected invalid hex color "#y3" (color-no-invalid-hex) color-no-invalid-hex



a { color: pink;; }
Copy link

Choose a reason for hiding this comment

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

🚫 [stylelint] reported by reviewdog 🐶
Unexpected duplicate selector "a", first used at line 1 (no-duplicate-selectors) no-duplicate-selectors

Copy link

Choose a reason for hiding this comment

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

🚫 [stylelint] reported by reviewdog 🐶
Unexpected extra semicolon (no-extra-semicolons) no-extra-semicolons