-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2c8d89e
commit 06a7b82
Showing
11 changed files
with
262 additions
and
4 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,8 @@ | ||
.husky | ||
.vscode | ||
node_modules | ||
public | ||
static | ||
new | ||
dist | ||
.yarn |
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,23 @@ | ||
module.exports = { | ||
env: { | ||
node: true, | ||
es2022: true, | ||
browser: true, | ||
}, | ||
extends: ["eslint:recommended", "plugin:astro/recommended"], | ||
parserOptions: { | ||
ecmaVersion: "latest", | ||
sourceType: "module", | ||
}, | ||
overrides: [ | ||
{ | ||
files: ["*.astro"], | ||
parser: "astro-eslint-parser", | ||
parserOptions: { | ||
parser: "@typescript-eslint/parser", | ||
extraFileExtensions: [".astro"], | ||
}, | ||
rules: {}, | ||
}, | ||
], | ||
}; |
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
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 @@ | ||
{ | ||
"MD033": false, | ||
"MD013": 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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Expose Astro dependencies for `pnpm` users | ||
shamefully-hoist=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,13 @@ | ||
# Ignore everything | ||
/* | ||
|
||
# Except these files & folders | ||
!/src | ||
!/publix | ||
!/.github | ||
!tsconfig.json | ||
!astro.config.ts | ||
!package.json | ||
!.prettierrc | ||
!.eslintrc.js | ||
!README.md |
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,20 @@ | ||
{ | ||
"arrowParens": "avoid", | ||
"semi": true, | ||
"tabWidth": 2, | ||
"printWidth": 80, | ||
"singleQuote": false, | ||
"jsxSingleQuote": false, | ||
"trailingComma": "es5", | ||
"bracketSpacing": true, | ||
"endOfLine": "lf", | ||
"plugins": ["prettier-plugin-astro", "prettier-plugin-tailwindcss"], | ||
"overrides": [ | ||
{ | ||
"files": "*.astro", | ||
"options": { | ||
"parser": "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,57 @@ | ||
import { defineConfig } from "astro/config"; | ||
import tailwind from "@astrojs/tailwind"; | ||
import react from "@astrojs/react"; | ||
import remarkToc from "remark-toc"; | ||
import remarkCollapse from "remark-collapse"; | ||
import sitemap from "@astrojs/sitemap"; | ||
|
||
// https://astro.build/config | ||
export default defineConfig({ | ||
// https://docs.astro.build/en/reference/configuration-reference/#site | ||
// see https://config.tips/c/astro/dynamic-astro-site-value/ | ||
site: import.meta.env.DEV ? "http://localhost:4321" : 'https://emeraldjava.github.io/', | ||
// See https://github.com/withastro/astro/issues/5512 | ||
// https://docs.astro.build/en/guides/environment-variables/ | ||
// https://vitejs.dev/guide/env-and-mode.html#env-files | ||
//base: import.meta.env.DEV ? "." : "/emeraldjava-astro", | ||
//base: import.meta.env.VITE_BASE, | ||
integrations: [ | ||
tailwind({ | ||
applyBaseStyles: true, | ||
}), | ||
react(), | ||
sitemap(), | ||
], | ||
markdown: { | ||
remarkPlugins: [ | ||
remarkToc, | ||
[ | ||
remarkCollapse, | ||
{ | ||
test: "Table of contents", | ||
}, | ||
], | ||
], | ||
// shikiConfig: { | ||
// theme: "one-dark-pro", | ||
// wrap: true, | ||
// }, | ||
}, | ||
vite: { | ||
// build: { | ||
// rollupOptions: { | ||
// output: { | ||
// entryFileNames: '[name]-[hash].js', | ||
// } | ||
// } | ||
// }, | ||
optimizeDeps: { | ||
exclude: ["@resvg/resvg-js"], | ||
}, | ||
}, | ||
scopedStyleStrategy: "where", | ||
// https://about.gitlab.com/blog/2022/10/24/publishing-an-astro-site-with-pages/ | ||
// GitLab Pages requires exposed files to be located in a folder called "public". | ||
// So we're instructing Astro to put the static build output in a folder of that name. | ||
outDir: './dist' | ||
}); |
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: '3' | ||
|
||
services: | ||
app: | ||
image: node:18 | ||
ports: | ||
- 4321:4321 | ||
working_dir: /app | ||
command: npm run dev -- --host 0.0.0.0 | ||
volumes: | ||
- ./:/app |
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,63 @@ | ||
{ | ||
"name": "emeraldjava.github.io", | ||
"version": "2024.6.6", | ||
"scripts": { | ||
"dev": "astro dev", | ||
"start": "astro dev", | ||
"build": "astro check && astro build", | ||
"preview": "astro preview", | ||
"sync": "astro sync", | ||
"astro": "astro", | ||
"format:check": "prettier --check . --plugin=prettier-plugin-astro", | ||
"format": "prettier --write . --plugin=prettier-plugin-astro", | ||
"cz": "cz", | ||
"prepare": "husky install", | ||
"lint": "eslint ." | ||
}, | ||
"dependencies": { | ||
"@astrojs/check": "^0.5.10", | ||
"@astrojs/rss": "^4.0.2", | ||
"@resvg/resvg-js": "^2.6.0", | ||
"astro": "^4.2.1", | ||
"cross-env": "^7.0.3", | ||
"fuse.js": "^7.0.0", | ||
"github-slugger": "^2.0.0", | ||
"remark-collapse": "^0.1.2", | ||
"remark-toc": "^9.0.0", | ||
"satori": "^0.10.11", | ||
"tailwindcss": "^3.4.1", | ||
"typescript": "^5.4.5" | ||
}, | ||
"devDependencies": { | ||
"@astrojs/react": "^3.0.9", | ||
"@astrojs/sitemap": "^3.0.5", | ||
"@astrojs/tailwind": "^5.1.0", | ||
"@divriots/jampack": "^0.23.2", | ||
"@tailwindcss/typography": "^0.5.10", | ||
"@types/github-slugger": "^1.3.0", | ||
"@types/react": "^18.2.48", | ||
"@typescript-eslint/parser": "^6.19.0", | ||
"astro-eslint-parser": "^0.16.2", | ||
"commitizen": "^4.3.0", | ||
"cz-conventional-changelog": "^3.3.0", | ||
"eslint": "^8.56.0", | ||
"eslint-plugin-astro": "^0.31.3", | ||
"husky": "^8.0.3", | ||
"lint-staged": "^15.2.0", | ||
"prettier": "^3.2.4", | ||
"prettier-plugin-astro": "^0.13.0", | ||
"prettier-plugin-tailwindcss": "^0.5.11", | ||
"react": "^18.2.0", | ||
"react-dom": "^18.2.0" | ||
}, | ||
"config": { | ||
"commitizen": { | ||
"path": "./node_modules/cz-conventional-changelog" | ||
} | ||
}, | ||
"lint-staged": { | ||
"*.{js,jsx,ts,tsx,md,mdx,json,astro}": [ | ||
"prettier --write --plugin=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,17 @@ | ||
{ | ||
"extends": "astro/tsconfigs/strict", | ||
"compilerOptions": { | ||
"baseUrl": "src", | ||
"jsx": "react-jsx", | ||
"paths": { | ||
"@assets/*": ["assets/*"], | ||
"@config": ["config.ts"], | ||
"@components/*": ["components/*"], | ||
"@content/*": ["content/*"], | ||
"@layouts/*": ["layouts/*"], | ||
"@pages/*": ["pages/*"], | ||
"@styles/*": ["styles/*"], | ||
"@utils/*": ["utils/*"], | ||
}, | ||
}, | ||
} |