-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: set up Astro to expose data via endpoints
- Loading branch information
Showing
20 changed files
with
5,009 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: CI | ||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | ||
|
||
jobs: | ||
build-lint-test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v3 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version-file: .nvmrc | ||
cache: pnpm | ||
- run: pnpm install | ||
- run: pnpm run build | ||
- run: pnpm run lint | ||
- run: pnpm run --if-present test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
node_modules/ | ||
dist/ | ||
.astro/ | ||
.wrangler/ | ||
*.log* | ||
.env.local | ||
.env.*.local | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"plugins": ["prettier-plugin-astro"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"recommendations": [ | ||
"astro-build.astro-vscode", | ||
"EditorConfig.EditorConfig", | ||
"esbenp.prettier-vscode", | ||
"GitHub.vscode-github-actions", | ||
"unifiedjs.vscode-mdx" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"command": "pnpm exec astro dev", | ||
"name": "Development server", | ||
"request": "launch", | ||
"type": "node-terminal" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import starlight from "@astrojs/starlight"; | ||
import { defineConfig } from "astro/config"; | ||
|
||
export default defineConfig({ | ||
integrations: [ | ||
starlight({ | ||
title: "FX Rates HU", | ||
social: { | ||
github: "https://github.com/kripod/fx-rates-hu", | ||
}, | ||
pagefind: false, | ||
}), | ||
], | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,21 +3,27 @@ | |
"private": true, | ||
"type": "module", | ||
"scripts": { | ||
"dev": "node --watch ./src/index.js", | ||
"start": "node ./src/index.js", | ||
"dev": "astro dev", | ||
"build": "astro build", | ||
"preview": "astro preview", | ||
"clean": "git clean --interactive -dx --exclude .env.local --exclude \".env.*.local\" --exclude node_modules/", | ||
"lint": "pnpm run \"/^lint:(?!fix)/\"", | ||
"lint:astro": "astro check", | ||
"lint:format": "prettier --check .", | ||
"lint:types": "tsc --noEmit", | ||
"lint:fix": "pnpm run \"/^lint:fix:/\"", | ||
"lint:fix:format": "prettier --write ." | ||
}, | ||
"dependencies": { | ||
"@astrojs/starlight": "^0.21.5", | ||
"astro": "^4.6.1", | ||
"xlsx": "https://cdn.sheetjs.com/xlsx-0.20.1/xlsx-0.20.1.tgz" | ||
}, | ||
"devDependencies": { | ||
"@types/node": "^20.12.3", | ||
"@astrojs/check": "^0.5.10", | ||
"@types/node": "^20.12.7", | ||
"prettier": "^3.2.5", | ||
"typescript": "^5.4.3" | ||
"prettier-plugin-astro": "^0.13.0", | ||
"typescript": "^5.4.5" | ||
}, | ||
"packageManager": "[email protected]" | ||
} |
Oops, something went wrong.