Skip to content

Commit c4ebb82

Browse files
committed
Add Prettier GitHub Actions
1 parent 7b58c9e commit c4ebb82

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

.github/workflows/prettier.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Prettier
2+
3+
# This action works with pull requests and pushes
4+
on:
5+
pull_request:
6+
push:
7+
branches:
8+
- main
9+
10+
jobs:
11+
prettier:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v2
17+
with:
18+
# Make sure the actual branch is checked out when running on pull requests
19+
ref: ${{ github.head_ref }}
20+
21+
- name: Prettify code
22+
uses: creyD/prettier_action@v4.2
23+
with:
24+
# This part is also where you can pass other options, for example:
25+
prettier_options: --write .

0 commit comments

Comments
 (0)