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

add and run prettier #7

Merged
merged 1 commit into from
Jul 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": "next/core-web-vitals"
"extends": ["next/core-web-vitals", "prettier"]
}
34 changes: 17 additions & 17 deletions .github/workflows/firebase-hosting-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,21 @@

name: Deploy to Firebase Hosting on merge
"on":
push:
branches:
- main
push:
branches:
- main
jobs:
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: npm install && npm run lint && npm run build
env:
CMS_URL: ${{ secrets.CMS_URL }}
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
target: "satakuntalainenosakunta"
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT_SATAKUNTATALO_SERVICES }}"
channelId: live
projectId: satakuntatalo-services
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: npm install && npm run lint && npm run build
env:
CMS_URL: ${{ secrets.CMS_URL }}
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
target: "satakuntalainenosakunta"
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT_SATAKUNTATALO_SERVICES }}"
channelId: live
projectId: satakuntatalo-services
40 changes: 20 additions & 20 deletions .github/workflows/firebase-hosting-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,23 @@
name: Deploy to Firebase Hosting on PR
"on": pull_request
jobs:
build_and_preview:
if: "${{ github.event.pull_request.head.repo.full_name == github.repository }}"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: npm install && npm run lint && npm run build
env:
CMS_URL: ${{ secrets.CMS_URL }}
- uses: FirebaseExtended/action-hosting-deploy@v0
id: firebase
with:
target: "satakuntalainenosakunta"
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT_SATAKUNTATALO_SERVICES }}"
projectId: satakuntatalo-services
- uses: treosh/lighthouse-ci-action@v12
id: lighthouse
with:
urls: ${{ steps.firebase.outputs.details_url }}
temporaryPublicStorage: true
build_and_preview:
if: "${{ github.event.pull_request.head.repo.full_name == github.repository }}"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: npm install && npm run lint && npm run build
env:
CMS_URL: ${{ secrets.CMS_URL }}
- uses: FirebaseExtended/action-hosting-deploy@v0
id: firebase
with:
target: "satakuntalainenosakunta"
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT_SATAKUNTATALO_SERVICES }}"
projectId: satakuntatalo-services
- uses: treosh/lighthouse-ci-action@v12
id: lighthouse
with:
urls: ${{ steps.firebase.outputs.details_url }}
temporaryPublicStorage: true
1 change: 1 addition & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
2 changes: 1 addition & 1 deletion doc/initial_plan.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Inital project planning

This effort aims to create a new website for the Satakunta Nation
The old website has become cumbersome to maintain, and is built with 10 year old technology. The user experience is also not welcoming.
The old website has become cumbersome to maintain, and is built with 10 year old technology. The user experience is also not welcoming.

We plan on using Figma for prototyping and designing user interfaces, Trello for tracking tasks and progress, and Miro for diagrams (site maps etc.). The code is hosted here on GitHub.

Expand Down
10 changes: 5 additions & 5 deletions firebase.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"hosting": {
"target": "satakuntalainenosakunta",
"public": "out",
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"]
}
"hosting": {
"target": "satakuntalainenosakunta",
"public": "out",
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"]
}
}
2 changes: 1 addition & 1 deletion hooks/useCMS.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const useCMS = <T>({ collection, query = "", initialData }: UseCMSProps<T>) => {

try {
const response = await fetch(
`${process.env.NEXT_PUBLIC_DIRECTUS_URL}/items/text`
`${process.env.NEXT_PUBLIC_DIRECTUS_URL}/items/text`,
);
if (!response.ok) {
throw new Error(`Error: ${response.status} ${response.statusText}`);
Expand Down
2 changes: 1 addition & 1 deletion next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
const nextConfig = {
output: "export",
images: {
unoptimized: true
unoptimized: true,
},
reactStrictMode: true,
};
Expand Down
29 changes: 29 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,10 @@
"@vitejs/plugin-react": "^4.3.1",
"eslint": "^8",
"eslint-config-next": "14.2.4",
"eslint-config-prettier": "^9.1.0",
"fast-check": "^3.20.0",
"jsdom": "^24.1.0",
"prettier": "3.3.3",
"typescript": "^5",
"vitest": "^2.0.3"
}
Expand Down
Loading