Skip to content

Commit

Permalink
chore: remove JS and TS
Browse files Browse the repository at this point in the history
  • Loading branch information
TheDevMinerTV committed Oct 11, 2023
1 parent 8c4d7b6 commit 15b81fe
Show file tree
Hide file tree
Showing 10 changed files with 6 additions and 403 deletions.
38 changes: 0 additions & 38 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,44 +58,6 @@ jobs:
- name: Test
run: go test -v ./...

types:
name: Check types
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: "18"

- uses: pnpm/action-setup@v2
name: Install pnpm
id: pnpm-install
with:
version: 8
run_install: false

- name: Get pnpm store directory
id: pnpm-cache
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install

- name: Check types
run: pnpm js:build

formatting:
name: Check formatting
runs-on: ubuntu-latest
Expand Down
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
node_modules
internal/web/static/js/*.js
internal/web/static/styles.css
.env.local
*.bbolt
renovate.json
renovate.json
1 change: 0 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ RUN go mod download

COPY . .
COPY --from=frontend-builder /build/internal/web/static/styles.css /build/internal/web/static/styles.css
COPY --from=frontend-builder /build/internal/web/static/js/*.js /build/internal/web/static/js
RUN CGO_ENABLED=0 go build -o /build/ldap-passwd

FROM alpine:3 AS runner
Expand Down
196 changes: 0 additions & 196 deletions internal/web/static/js/app.ts

This file was deleted.

74 changes: 0 additions & 74 deletions internal/web/static/js/validators.ts

This file was deleted.

2 changes: 1 addition & 1 deletion internal/web/static/static.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ package static

import "embed"

//go:embed *.css js/*.js *.png *.ico *.svg *.webp site.webmanifest browserconfig.xml
//go:embed *.css *.png *.ico *.svg *.webp site.webmanifest browserconfig.xml
var Static embed.FS
13 changes: 4 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,14 @@
"packageManager": "pnpm@8.9.0",
"scripts": {
"start": "pnpm build:assets && pnpm go:start",
"dev": "pnpm build:assets && concurrently -n js,css,go \"pnpm js:dev\" \"pnpm css:dev\" \"pnpm go:dev\"",
"dev": "pnpm build:assets && concurrently -n css,go \"pnpm css:dev\" \"pnpm go:dev\"",
"build": "pnpm build:assets && pnpm go:build",
"build:assets": "concurrently -n js,css \"pnpm js:build\" \"pnpm css:build\"",
"js:build": "tsc && pnpm js:minify",
"js:dev": "tsc -w --preserveWatchOutput",
"js:minify": "node scripts/minify.js",
"build:assets": "concurrently -n css \"pnpm css:build\"",
"css:build": "postcss ./internal/web/tailwind.css -o ./internal/web/static/styles.css",
"css:dev": "pnpm css:build -w --verbose",
"go:start": "go run .",
"go:build": "go build",
"go:dev": "nodemon --signal SIGTERM -e go,html,css,js -w \"./**\" -x pnpm go:start"
"go:dev": "nodemon --signal SIGTERM -e go,html,css -w \"./**\" -x pnpm go:start"
},
"devDependencies": {
"@tailwindcss/forms": "^0.5.6",
Expand All @@ -29,8 +26,6 @@
"prettier": "^3.0.3",
"prettier-plugin-go-template": "^0.0.15",
"prettier-plugin-tailwindcss": "^0.5.4",
"tailwindcss": "^3.3.3",
"typescript": "^5.2.2",
"uglify-js": "^3.17.4"
"tailwindcss": "^3.3.3"
}
}
Loading

0 comments on commit 15b81fe

Please sign in to comment.