Skip to content

Commit 7ebafee

Browse files
committed
first commit
0 parents  commit 7ebafee

26 files changed

Lines changed: 6428 additions & 0 deletions

.github/workflows/release.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: 'release'
2+
3+
on:
4+
push:
5+
tags: ['*']
6+
7+
jobs:
8+
release:
9+
runs-on: ubuntu-24.04
10+
permissions:
11+
id-token: write
12+
contents: write
13+
env:
14+
RELEASE_NAME: svelte5-vite-ts-tailwind-eslint
15+
steps:
16+
- name: Checkout 🛒
17+
uses: actions/checkout@v6
18+
- name: Setup Pages
19+
uses: actions/configure-pages@v5
20+
- name: node 24 ❇️
21+
uses: actions/setup-node@v6
22+
with:
23+
node-version: 24
24+
cache: 'npm'
25+
- name: cache dependencies 💾
26+
uses: actions/cache@v4
27+
with:
28+
path: ~/.npm
29+
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
30+
restore-keys: |
31+
${{ runner.os }}-node-
32+
33+
- name: Build 🔧
34+
run: |
35+
npm ci
36+
npm run build
37+
(cd dist && zip -r ../$RELEASE_NAME.zip * && tar -czf ../$RELEASE_NAME.tar.gz *)
38+
39+
- name: Generate Release Notes 📝
40+
if: github.ref_type == 'tag'
41+
run: |
42+
CHANGE=$(sed "/${GITHUB_REF_NAME%%-*}/,/##/!d;//d" CHANGELOG.md | awk 'NF')
43+
echo "$CHANGE" > changelog.txt
44+
RELEASE_TYPE=$(if [[ "$GITHUB_REF_NAME" =~ -(beta|rc) ]]; then echo "true"; else echo "false"; fi)
45+
echo "RELEASE_TYPE=${RELEASE_TYPE}" >> $GITHUB_ENV
46+
47+
- name: Create Release 🎉
48+
uses: ncipollo/release-action@v1
49+
if: github.ref_type == 'tag'
50+
with:
51+
artifacts: ${{ env.RELEASE_NAME }}.zip,${{ env.RELEASE_NAME }}.tar.gz
52+
bodyFile: "changelog.txt"
53+
prerelease: ${{ env.RELEASE_TYPE }}

.github/workflows/static.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Deploy to Pages
2+
3+
on:
4+
push:
5+
branches: ['main']
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
13+
concurrency:
14+
group: 'pages'
15+
cancel-in-progress: false
16+
17+
jobs:
18+
deploy:
19+
environment:
20+
name: github-pages
21+
url: ${{ steps.deployment.outputs.page_url }}
22+
runs-on: ubuntu-24.04
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@v6
26+
- name: Setup Pages
27+
uses: actions/configure-pages@v5
28+
- name: node 24 ❇️
29+
uses: actions/setup-node@v6
30+
with:
31+
node-version: 24
32+
cache: 'npm'
33+
- name: cache dependencies 💾
34+
uses: actions/cache@v4
35+
with:
36+
path: ~/.npm
37+
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
38+
restore-keys: |
39+
${{ runner.os }}-node-
40+
- name: Build
41+
run: |
42+
npm ci
43+
npm run build
44+
- name: Upload artifact
45+
uses: actions/upload-pages-artifact@v4
46+
with:
47+
path: 'dist'
48+
- name: Deploy to GitHub Pages
49+
id: deployment
50+
uses: actions/deploy-pages@v4

.github/workflows/test.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: test
2+
on:
3+
push:
4+
branches-ignore: ['main']
5+
6+
jobs:
7+
test-ts:
8+
runs-on: ubuntu-24.04
9+
steps:
10+
- name: checkout 🛒
11+
uses: actions/checkout@v6
12+
13+
- name: node 24 ❇️
14+
uses: actions/setup-node@v6
15+
with:
16+
node-version: 24
17+
cache: 'npm'
18+
19+
- name: cache dependencies 💾
20+
uses: actions/cache@v4
21+
with:
22+
path: ~/.npm
23+
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
24+
restore-keys: |
25+
${{ runner.os }}-node-
26+
27+
- name: make npm ♦️
28+
run: |
29+
npm ci
30+
31+
- name: make lint-js 🧹
32+
run: |
33+
npm run lint
34+
35+
- name: make test-js 🧪
36+
run: |
37+
npm run test

.gitignore

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
dist
12+
dist-ssr
13+
*.local
14+
15+
# Editor directories and files
16+
.vscode/*
17+
!.vscode/extensions.json
18+
.idea
19+
.DS_Store
20+
*.suo
21+
*.ntvs*
22+
*.njsproj
23+
*.sln
24+
*.sw?
25+
26+
*.zip
27+
*.tar.gz
28+

.vscode/extensions.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"recommendations": ["svelte.svelte-vscode"]
3+
}

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
## 0.0.1 (May 1, 2025)
2+
* Initial release.

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Share Timer
2+
3+
[Bootstrapped with svelte5-vite-ts-tailwind-eslint](https://github.com/pjaudiomv/svelte5-vite-ts-tailwind-eslint/)

eslint.config.js

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
import js from '@eslint/js';
2+
import ts from 'typescript-eslint';
3+
import svelte from 'eslint-plugin-svelte';
4+
import prettier from 'eslint-config-prettier';
5+
import globals from 'globals';
6+
7+
/** @type {import('eslint').Linter.FlatConfig[]} */
8+
export default [
9+
js.configs.recommended,
10+
...ts.configs.recommended,
11+
...svelte.configs['flat/recommended'],
12+
prettier,
13+
...svelte.configs['flat/prettier'],
14+
{
15+
languageOptions: {
16+
globals: {
17+
...globals.browser,
18+
...globals.node
19+
}
20+
}
21+
},
22+
{
23+
files: ['**/*.svelte'],
24+
languageOptions: {
25+
parserOptions: {
26+
parser: ts.parser
27+
}
28+
}
29+
},
30+
{
31+
ignores: ['build/', 'dist/', '*.md']
32+
},
33+
{
34+
files: ['**/*.ts', '**/*.svelte'],
35+
rules: {
36+
'@typescript-eslint/no-explicit-any': 'off',
37+
'no-undef': 'off'
38+
}
39+
}
40+
];

index.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
7+
<title>Vite + Svelte + TS + Tailwind + ESLint</title>
8+
</head>
9+
<body>
10+
<div id="app"></div>
11+
<script type="module" src="/src/main.ts"></script>
12+
</body>
13+
</html>

0 commit comments

Comments
 (0)