Skip to content

Commit

Permalink
Bump typescript, use @tsconfig/bases packages for config
Browse files Browse the repository at this point in the history
  • Loading branch information
sondr3 committed Nov 27, 2024
1 parent e28eb3a commit b2ed13e
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 27 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,12 @@
},
"devDependencies": {
"@biomejs/biome": "1.9.4",
"@sondr3/tsconfig": "0.8.0",
"@tsconfig/recommended": "1.0.8",
"@tsconfig/strictest": "2.0.5",
"@types/node": "18.15.3",
"astro": "2.1.3",
"lefthook": "1.8.4",
"typescript": "4.9.5",
"typescript": "5.7.2",
"vitest": "2.1.6"
}
}
41 changes: 21 additions & 20 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/compress.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export const gzip = async (dir: string, extensions: Array<string>, enabled?: boo
}

const end = hrtime.bigint();
logger.success(`finished gzip of ${counter} files in ${(end - start) / 1000000n}ms`);
logger.success(`finished gzip of ${counter} files in ${(end - start) / BigInt(1000000)}ms`);
};

export const brotli = async (dir: string, extensions: Array<string>, enabled?: boolean): Promise<void> => {
Expand All @@ -62,5 +62,5 @@ export const brotli = async (dir: string, extensions: Array<string>, enabled?: b
}

const end = hrtime.bigint();
logger.success(`finished brotli of ${counter} files in ${(end - start) / 1000000n}ms`);
logger.success(`finished brotli of ${counter} files in ${(end - start) / BigInt(1000000)}ms`);
};
9 changes: 6 additions & 3 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
{
"extends": "@sondr3/tsconfig",
"extends": ["@tsconfig/recommended/tsconfig.json", "@tsconfig/strictest/tsconfig.json"],
"compilerOptions": {
"lib": ["ES2020"],
"skipLibCheck": true,
"target": "ES2020",
"module": "NodeNext",
"moduleResolution": "nodenext",
"noUncheckedSideEffectImports": true,
"declaration": true,
"declarationMap": true,
"outDir": "dist"
},
"include": ["src"],
"exclude": ["coverage", "node_modules", "dist"]
"exclude": ["coverage", "node_modules", "dist", "test"]
}

0 comments on commit b2ed13e

Please sign in to comment.