Skip to content

Commit

Permalink
build(catalog): re-enable catalog typechecking
Browse files Browse the repository at this point in the history
This enables typechecking on the catalog so that we catch type build issues in CI next time. Type issues didn't break before since we run our code through esbuild, and it was disabled because of some weird 11ty issues that are fixed in this CL
  • Loading branch information
e111077 committed Jun 22, 2023
1 parent 39af025 commit 07668e6
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,5 @@ catalog/site/components/*.md
catalog/site/components/images
catalog/*.tsbuildinfo
catalog/stories/*/
!catalog/stories/components/
!catalog/stories/components/
!catalog/src/types/**/*.d.ts
9 changes: 7 additions & 2 deletions catalog/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
"build:dev": {
"dependencies": [
"build:dev:eleventy",
"build:dev:ts"
"build:dev:ts",
"build:type-check"
]
},
"build:dev:eleventy": {
Expand Down Expand Up @@ -66,12 +67,16 @@
"clean": "if-file-deleted",
"output": [
"tsconfig.tsbuildinfo"
],
"dependencies": [
"..:build"
]
},
"build:prod": {
"dependencies": [
"build:prod:eleventy",
"build:prod:ts"
"build:prod:ts",
"build:type-check"
]
},
"build:prod:eleventy": {
Expand Down
11 changes: 11 additions & 0 deletions catalog/src/types/is-land.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/**
* @license
* Copyright 2023 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/

declare module '@11ty/is-land' {
export class Island extends HTMLElement {
forceFallback(): void;
}
}
3 changes: 2 additions & 1 deletion catalog/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"useDefineForClassFields": false,
"forceConsistentCasingInFileNames": true,
"noEmit": true,
"skipLibCheck": true
"skipLibCheck": true,
"types": []
},
"include": ["src/**/*", "stories/*", "stories/components"],
"exclude": []
Expand Down

0 comments on commit 07668e6

Please sign in to comment.