mirror of
https://github.com/bartvdbraak/hellob.art.git
synced 2025-04-26 17:11:21 +00:00
feat: create initial app skeleton
This commit is contained in:
parent
8d4ea7747a
commit
62f2d4651d
17 changed files with 1223 additions and 2082 deletions
13
.eslintignore
Normal file
13
.eslintignore
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
.DS_Store
|
||||||
|
node_modules
|
||||||
|
/build
|
||||||
|
/.svelte-kit
|
||||||
|
/package
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
!.env.example
|
||||||
|
|
||||||
|
# Ignore files for PNPM, NPM and YARN
|
||||||
|
pnpm-lock.yaml
|
||||||
|
package-lock.json
|
||||||
|
yarn.lock
|
30
.eslintrc.cjs
Normal file
30
.eslintrc.cjs
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
module.exports = {
|
||||||
|
root: true,
|
||||||
|
extends: [
|
||||||
|
'eslint:recommended',
|
||||||
|
'plugin:@typescript-eslint/recommended',
|
||||||
|
'plugin:svelte/recommended',
|
||||||
|
'prettier'
|
||||||
|
],
|
||||||
|
parser: '@typescript-eslint/parser',
|
||||||
|
plugins: ['@typescript-eslint'],
|
||||||
|
parserOptions: {
|
||||||
|
sourceType: 'module',
|
||||||
|
ecmaVersion: 2020,
|
||||||
|
extraFileExtensions: ['.svelte']
|
||||||
|
},
|
||||||
|
env: {
|
||||||
|
browser: true,
|
||||||
|
es2017: true,
|
||||||
|
node: true
|
||||||
|
},
|
||||||
|
overrides: [
|
||||||
|
{
|
||||||
|
files: ['*.svelte'],
|
||||||
|
parser: 'svelte-eslint-parser',
|
||||||
|
parserOptions: {
|
||||||
|
parser: '@typescript-eslint/parser'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
43
.gitignore
vendored
43
.gitignore
vendored
|
@ -1,35 +1,10 @@
|
||||||
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
|
|
||||||
|
|
||||||
# dependencies
|
|
||||||
/node_modules
|
|
||||||
/.pnp
|
|
||||||
.pnp.js
|
|
||||||
|
|
||||||
# testing
|
|
||||||
/coverage
|
|
||||||
|
|
||||||
# next.js
|
|
||||||
/.next/
|
|
||||||
/out/
|
|
||||||
|
|
||||||
# production
|
|
||||||
/build
|
|
||||||
|
|
||||||
# misc
|
|
||||||
.DS_Store
|
.DS_Store
|
||||||
*.pem
|
node_modules
|
||||||
|
/build
|
||||||
# debug
|
/.svelte-kit
|
||||||
npm-debug.log*
|
/package
|
||||||
yarn-debug.log*
|
.env
|
||||||
yarn-error.log*
|
.env.*
|
||||||
|
!.env.example
|
||||||
# local env files
|
vite.config.js.timestamp-*
|
||||||
.env*.local
|
vite.config.ts.timestamp-*
|
||||||
|
|
||||||
# vercel
|
|
||||||
.vercel
|
|
||||||
|
|
||||||
# typescript
|
|
||||||
*.tsbuildinfo
|
|
||||||
next-env.d.ts
|
|
||||||
|
|
2
.npmrc
Normal file
2
.npmrc
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
engine-strict=true
|
||||||
|
resolution-mode=highest
|
|
@ -1,8 +1,13 @@
|
||||||
cache
|
.DS_Store
|
||||||
.cache
|
|
||||||
package.json
|
|
||||||
pnpm-lock.yaml
|
|
||||||
public
|
|
||||||
node_modules
|
node_modules
|
||||||
.next
|
/build
|
||||||
.github
|
/.svelte-kit
|
||||||
|
/package
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
!.env.example
|
||||||
|
|
||||||
|
# Ignore files for PNPM, NPM and YARN
|
||||||
|
pnpm-lock.yaml
|
||||||
|
package-lock.json
|
||||||
|
yarn.lock
|
||||||
|
|
9
.prettierrc
Normal file
9
.prettierrc
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
{
|
||||||
|
"useTabs": true,
|
||||||
|
"singleQuote": true,
|
||||||
|
"trailingComma": "none",
|
||||||
|
"printWidth": 100,
|
||||||
|
"plugins": ["prettier-plugin-svelte"],
|
||||||
|
"pluginSearchDirs": ["."],
|
||||||
|
"overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }]
|
||||||
|
}
|
75
README.md
75
README.md
|
@ -1,57 +1,38 @@
|
||||||
<div align="center">
|
# create-svelte
|
||||||
<h1 align="center">hellob.art</h1>
|
|
||||||
<h5>a simple portfolio</h5>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div align="center">
|
Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/master/packages/create-svelte).
|
||||||
<a href="https://sonarcloud.io/summary/new_code?id=bartvdbraak_hellob.art"><img src="https://sonarcloud.io/api/project_badges/measure?project=bartvdbraak_hellob.art&metric=alert_status" /></a>
|
|
||||||
<a href="https://github.com/bartvdbraak/hellob.art/deployments/activity_log?environment=Production"><img src="https://img.shields.io/github/deployments/bartvdbraak/hellob.art/production?label=vercel&logo=vercel" /></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div align="center">
|
## Creating a project
|
||||||
<a href="https://hellob.art?ref=github">hellob.art</a>
|
|
||||||
</div>
|
|
||||||
<br/>
|
|
||||||
|
|
||||||
## Installation
|
If you're seeing this, you've probably already done this step. Congrats!
|
||||||
|
|
||||||
To install the project and its dependencies, follow these steps:
|
```bash
|
||||||
|
# create a new project in the current directory
|
||||||
|
npm create svelte@latest
|
||||||
|
|
||||||
1. Ensure you have `pnpm` installed on your system. If not, you can install it by running:
|
# create a new project in my-app
|
||||||
|
npm create svelte@latest my-app
|
||||||
```sh-session
|
|
||||||
npm install -g pnpm
|
|
||||||
```
|
|
||||||
|
|
||||||
2. Run the following command to install the project dependencies:
|
|
||||||
```sh-session
|
|
||||||
pnpm install
|
|
||||||
```
|
|
||||||
|
|
||||||
### Environment Variables
|
|
||||||
|
|
||||||
After setting up the required services, you need to set the corresponding environment variables in the `/.env` file. To do this, follow these steps:
|
|
||||||
|
|
||||||
1. Make a copy of the `.env.example` file:
|
|
||||||
|
|
||||||
```sh-session
|
|
||||||
cp .env.example .env
|
|
||||||
```
|
|
||||||
|
|
||||||
2. Open the `.env` file in a text editor and populate the values for the services mentioned above.
|
|
||||||
|
|
||||||
## Build
|
|
||||||
|
|
||||||
To build the project, execute the following command:
|
|
||||||
|
|
||||||
```sh-session
|
|
||||||
pnpm build
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## Run
|
## Developing
|
||||||
|
|
||||||
To run the project locally, use the following command:
|
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
|
||||||
|
|
||||||
```sh-session
|
```bash
|
||||||
pnpm run dev
|
npm run dev
|
||||||
|
|
||||||
|
# or start the server and open the app in a new browser tab
|
||||||
|
npm run dev -- --open
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Building
|
||||||
|
|
||||||
|
To create a production version of your app:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm run build
|
||||||
|
```
|
||||||
|
|
||||||
|
You can preview the production build with `npm run preview`.
|
||||||
|
|
||||||
|
> To deploy your app, you may need to install an [adapter](https://kit.svelte.dev/docs/adapters) for your target environment.
|
||||||
|
|
73
package.json
73
package.json
|
@ -1,46 +1,31 @@
|
||||||
{
|
{
|
||||||
"name": "hellob.art",
|
"name": "hellobart",
|
||||||
"version": "0.1.0",
|
"version": "0.0.1",
|
||||||
"private": true,
|
"private": true,
|
||||||
"author": {
|
"scripts": {
|
||||||
"name": "Bart van der Braak",
|
"dev": "vite dev",
|
||||||
"url": "https://hellob.art"
|
"build": "vite build",
|
||||||
},
|
"preview": "vite preview",
|
||||||
"scripts": {
|
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
|
||||||
"dev": "next dev",
|
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
|
||||||
"build": "next build",
|
"lint": "prettier --plugin-search-dir . --check . && eslint .",
|
||||||
"start": "next start",
|
"format": "prettier --plugin-search-dir . --write ."
|
||||||
"lint": "next lint",
|
},
|
||||||
"prepare": "husky install",
|
"devDependencies": {
|
||||||
"typecheck": "tsc --noEmit",
|
"@sveltejs/adapter-auto": "^2.0.0",
|
||||||
"format:write": "prettier . --write --cache",
|
"@sveltejs/kit": "^1.20.4",
|
||||||
"format:check": "prettier . --check --cache"
|
"@typescript-eslint/eslint-plugin": "^5.45.0",
|
||||||
},
|
"@typescript-eslint/parser": "^5.45.0",
|
||||||
"dependencies": {
|
"eslint": "^8.28.0",
|
||||||
"@t3-oss/env-nextjs": "^0.6.0",
|
"eslint-config-prettier": "^8.5.0",
|
||||||
"@tailwindcss/typography": "^0.5.9",
|
"eslint-plugin-svelte": "^2.30.0",
|
||||||
"@types/node": "20.4.2",
|
"prettier": "^2.8.0",
|
||||||
"@types/react": "18.2.15",
|
"prettier-plugin-svelte": "^2.10.1",
|
||||||
"@types/react-dom": "18.2.7",
|
"svelte": "^4.0.5",
|
||||||
"@vercel/analytics": "^1.0.1",
|
"svelte-check": "^3.4.3",
|
||||||
"autoprefixer": "10.4.14",
|
"tslib": "^2.4.1",
|
||||||
"class-variance-authority": "^0.7.0",
|
"typescript": "^5.0.0",
|
||||||
"clsx": "^2.0.0",
|
"vite": "^4.4.2"
|
||||||
"eslint": "8.45.0",
|
},
|
||||||
"eslint-config-next": "13.4.10",
|
"type": "module"
|
||||||
"next": "13.4.10",
|
|
||||||
"next-themes": "^0.2.1",
|
|
||||||
"postcss": "8.4.26",
|
|
||||||
"react": "18.2.0",
|
|
||||||
"react-dom": "18.2.0",
|
|
||||||
"tailwind-merge": "^1.14.0",
|
|
||||||
"tailwindcss": "3.3.3",
|
|
||||||
"tailwindcss-animate": "^1.0.6",
|
|
||||||
"typescript": "5.1.6"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@commitlint/config-conventional": "^17.6.6",
|
|
||||||
"husky": "^8.0.3",
|
|
||||||
"prettier": "2.8.8"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
2949
pnpm-lock.yaml
2949
pnpm-lock.yaml
File diff suppressed because it is too large
Load diff
12
src/app.d.ts
vendored
Normal file
12
src/app.d.ts
vendored
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
// See https://kit.svelte.dev/docs/types#app
|
||||||
|
// for information about these interfaces
|
||||||
|
declare global {
|
||||||
|
namespace App {
|
||||||
|
// interface Error {}
|
||||||
|
// interface Locals {}
|
||||||
|
// interface PageData {}
|
||||||
|
// interface Platform {}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export {};
|
12
src/app.html
Normal file
12
src/app.html
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8" />
|
||||||
|
<link rel="icon" href="%sveltekit.assets%/favicon.png" />
|
||||||
|
<meta name="viewport" content="width=device-width" />
|
||||||
|
%sveltekit.head%
|
||||||
|
</head>
|
||||||
|
<body data-sveltekit-preload-data="hover">
|
||||||
|
<div style="display: contents">%sveltekit.body%</div>
|
||||||
|
</body>
|
||||||
|
</html>
|
1
src/lib/index.ts
Normal file
1
src/lib/index.ts
Normal file
|
@ -0,0 +1 @@
|
||||||
|
// place files you want to import through the `$lib` alias in this folder.
|
2
src/routes/+page.svelte
Normal file
2
src/routes/+page.svelte
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
<h1>Welcome to SvelteKit</h1>
|
||||||
|
<p>Visit <a href="https://kit.svelte.dev">kit.svelte.dev</a> to read the documentation</p>
|
BIN
static/favicon.png
Normal file
BIN
static/favicon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 KiB |
18
svelte.config.js
Normal file
18
svelte.config.js
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
import adapter from '@sveltejs/adapter-auto';
|
||||||
|
import { vitePreprocess } from '@sveltejs/kit/vite';
|
||||||
|
|
||||||
|
/** @type {import('@sveltejs/kit').Config} */
|
||||||
|
const config = {
|
||||||
|
// Consult https://kit.svelte.dev/docs/integrations#preprocessors
|
||||||
|
// for more information about preprocessors
|
||||||
|
preprocess: vitePreprocess(),
|
||||||
|
|
||||||
|
kit: {
|
||||||
|
// adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list.
|
||||||
|
// If your environment is not supported or you settled on a specific environment, switch out the adapter.
|
||||||
|
// See https://kit.svelte.dev/docs/adapters for more information about adapters.
|
||||||
|
adapter: adapter()
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
export default config;
|
|
@ -1,28 +1,17 @@
|
||||||
{
|
{
|
||||||
"compilerOptions": {
|
"extends": "./.svelte-kit/tsconfig.json",
|
||||||
"target": "es5",
|
"compilerOptions": {
|
||||||
"lib": ["dom", "dom.iterable", "esnext"],
|
"allowJs": true,
|
||||||
"allowJs": true,
|
"checkJs": true,
|
||||||
"skipLibCheck": true,
|
"esModuleInterop": true,
|
||||||
"strict": true,
|
"forceConsistentCasingInFileNames": true,
|
||||||
"forceConsistentCasingInFileNames": true,
|
"resolveJsonModule": true,
|
||||||
"noEmit": true,
|
"skipLibCheck": true,
|
||||||
"esModuleInterop": true,
|
"sourceMap": true,
|
||||||
"module": "esnext",
|
"strict": true
|
||||||
"moduleResolution": "node",
|
}
|
||||||
"resolveJsonModule": true,
|
// Path aliases are handled by https://kit.svelte.dev/docs/configuration#alias
|
||||||
"isolatedModules": true,
|
//
|
||||||
"jsx": "preserve",
|
// If you want to overwrite includes/excludes, make sure to copy over the relevant includes/excludes
|
||||||
"incremental": true,
|
// from the referenced tsconfig.json - TypeScript does not merge them in
|
||||||
"plugins": [
|
|
||||||
{
|
|
||||||
"name": "next"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"paths": {
|
|
||||||
"@/*": ["./*"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
|
|
||||||
"exclude": ["node_modules"]
|
|
||||||
}
|
}
|
||||||
|
|
6
vite.config.ts
Normal file
6
vite.config.ts
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
import { sveltekit } from '@sveltejs/kit/vite';
|
||||||
|
import { defineConfig } from 'vite';
|
||||||
|
|
||||||
|
export default defineConfig({
|
||||||
|
plugins: [sveltekit()]
|
||||||
|
});
|
Loading…
Reference in a new issue