forked from federated-nexus/website
Set up prettier
This commit is contained in:
parent
a49c4b9a15
commit
155be0776d
9 changed files with 4960 additions and 55 deletions
72
.github/workflows/astro.yml
vendored
72
.github/workflows/astro.yml
vendored
|
@ -1,50 +1,50 @@
|
||||||
name: Deploy to Pages
|
name: Deploy to Pages
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: ["main"]
|
branches: ["main"]
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
pages: write
|
pages: write
|
||||||
id-token: write
|
id-token: write
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: "pages"
|
group: "pages"
|
||||||
cancel-in-progress: false
|
cancel-in-progress: false
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
name: Build
|
name: Build
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Setup Node
|
- name: Setup Node
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: "20"
|
node-version: "20"
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: npm i
|
run: npm i
|
||||||
|
|
||||||
- name: Build with Astro
|
- name: Build with Astro
|
||||||
run: npm run astro build
|
run: npm run astro build
|
||||||
|
|
||||||
- name: Upload artifact
|
- name: Upload artifact
|
||||||
uses: actions/upload-pages-artifact@v3
|
uses: actions/upload-pages-artifact@v3
|
||||||
with:
|
with:
|
||||||
path: dist
|
path: dist
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
environment:
|
environment:
|
||||||
name: github-pages
|
name: github-pages
|
||||||
url: ${{ steps.deployment.outputs.page_url }}
|
url: ${{ steps.deployment.outputs.page_url }}
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: Deploy
|
name: Deploy
|
||||||
steps:
|
steps:
|
||||||
- name: Deploy to GitHub Pages
|
- name: Deploy to GitHub Pages
|
||||||
id: deployment
|
id: deployment
|
||||||
uses: actions/deploy-pages@v4
|
uses: actions/deploy-pages@v4
|
||||||
|
|
7
.prettierrc
Normal file
7
.prettierrc
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
"plugins": ["prettier-plugin-astro"],
|
||||||
|
"tabWidth": 4,
|
||||||
|
"semi": false,
|
||||||
|
"overrides": [{ "files": "*.astro", "options": { "parser": "astro" } }],
|
||||||
|
"trailingComma": "none"
|
||||||
|
}
|
4
.vscode/extensions.json
vendored
4
.vscode/extensions.json
vendored
|
@ -1,4 +1,4 @@
|
||||||
{
|
{
|
||||||
"recommendations": ["astro-build.astro-vscode"],
|
"recommendations": ["astro-build.astro-vscode"],
|
||||||
"unwantedRecommendations": []
|
"unwantedRecommendations": []
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,21 +11,21 @@ export default defineConfig({
|
||||||
"Federated Nexus is a community resource hosting multiple FOSS (especially federated) services, including Matrix and Forgejo.",
|
"Federated Nexus is a community resource hosting multiple FOSS (especially federated) services, including Matrix and Forgejo.",
|
||||||
favicon: "/images/icon.svg",
|
favicon: "/images/icon.svg",
|
||||||
logo: {
|
logo: {
|
||||||
src: "./src/images/icon.svg",
|
src: "./src/images/icon.svg"
|
||||||
},
|
},
|
||||||
social: [
|
social: [
|
||||||
{
|
{
|
||||||
icon: "seti:git",
|
icon: "seti:git",
|
||||||
label: "Source Code",
|
label: "Source Code",
|
||||||
href: "https://git.federated.nexus",
|
href: "https://git.federated.nexus"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
icon: "mastodon",
|
icon: "mastodon",
|
||||||
label: "Mastodon",
|
label: "Mastodon",
|
||||||
href: "https://wetdry.world/@QuadRadical",
|
href: "https://wetdry.world/@QuadRadical"
|
||||||
},
|
}
|
||||||
],
|
]
|
||||||
}),
|
})
|
||||||
],
|
],
|
||||||
image: { service: passthroughImageService() },
|
image: { service: passthroughImageService() }
|
||||||
})
|
})
|
||||||
|
|
4896
package-lock.json
generated
Normal file
4896
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load diff
|
@ -9,9 +9,11 @@
|
||||||
"astro": "astro"
|
"astro": "astro"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@astrojs/starlight": "^0.34.3",
|
||||||
"astro": "^5.1.8",
|
"astro": "^5.1.8",
|
||||||
|
"prettier": "^3.6.2",
|
||||||
|
"prettier-plugin-astro": "^0.14.1",
|
||||||
"sharp": "^0.33.5",
|
"sharp": "^0.33.5",
|
||||||
"starlight": "^0.3.9",
|
"starlight": "^0.3.9"
|
||||||
"@astrojs/starlight": "^0.34.3"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,5 +3,5 @@ import { docsLoader } from "@astrojs/starlight/loaders"
|
||||||
import { docsSchema } from "@astrojs/starlight/schema"
|
import { docsSchema } from "@astrojs/starlight/schema"
|
||||||
|
|
||||||
export const collections = {
|
export const collections = {
|
||||||
docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }),
|
docs: defineCollection({ loader: docsLoader(), schema: docsSchema() })
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,8 +70,8 @@ import "../styles/login.css"
|
||||||
device_id: session,
|
device_id: session,
|
||||||
initial_device_display_name: `Federated Nexus Login from ${navigator.userAgent}`,
|
initial_device_display_name: `Federated Nexus Login from ${navigator.userAgent}`,
|
||||||
identifier: { type: "m.id.user", user: username },
|
identifier: { type: "m.id.user", user: username },
|
||||||
password,
|
password
|
||||||
}),
|
})
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"extends": "astro/tsconfigs/strict",
|
"extends": "astro/tsconfigs/strict",
|
||||||
"include": [".astro/types.d.ts", "**/*"],
|
"include": [".astro/types.d.ts", "**/*"],
|
||||||
"exclude": ["dist"]
|
"exclude": ["dist"]
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue