1
0
mirror of https://github.com/amir20/dozzle.git synced 2025-12-21 13:23:07 +01:00

Adds typechecking with typescript (#2101)

* Fixes all other vue errors

* Adds typescheck

* Fix pnpm

* Fix pnpm again for cache
This commit is contained in:
Amir Raminfar
2023-03-29 11:53:15 -07:00
committed by GitHub
parent 804bd5b9e1
commit e84f0cdb97
4 changed files with 38 additions and 13 deletions

View File

@@ -10,14 +10,15 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: latest
- name: Install pnpm
uses: pnpm/action-setup@v2.2.4
with:
version: 7.26.0
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Run Tests
@@ -80,14 +81,15 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: latest
- name: Install pnpm
uses: pnpm/action-setup@v2.2.4
with:
version: 6.20.1
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Release to Github

View File

@@ -7,20 +7,38 @@ on:
- master
name: Test
jobs:
typecheck:
name: Typecheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v3
with:
node-version: latest
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Run Typecheck
run: pnpm run typecheck
npm-test:
name: JavaScript Tests
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: latest
- name: Install pnpm
uses: pnpm/action-setup@v2.2.4
with:
version: 7.26.0
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Run Tests

View File

@@ -45,7 +45,8 @@ const mutationObserver = new MutationObserver((e) => {
scrollToBottom();
} else {
const record = e[e.length - 1];
if (record.target.children[record.target.children.length - 1] == record.addedNodes[record.addedNodes.length - 1]) {
const children = (record.target as HTMLElement).children;
if (children[children.length - 1] == record.addedNodes[record.addedNodes.length - 1]) {
hasMore = true;
}
}

View File

@@ -127,6 +127,10 @@ export class SkippedLogsEntry extends LogEntry<string> {
public get totalSkipped(): number {
return this._totalSkipped;
}
public get lastSkippedItem(): LogEntry<string | JSONObject> {
return this.lastSkipped;
}
}
export function asLogEntry(event: LogEvent): LogEntry<string | JSONObject> {