Skip to content

Commit

Permalink
Revert "Update typescript setup (#1542)"
Browse files Browse the repository at this point in the history
This reverts commit f4e3a3a.
  • Loading branch information
sndrs authored Jun 17, 2024
1 parent f4e3a3a commit 9979941
Show file tree
Hide file tree
Showing 57 changed files with 1,371 additions and 2,558 deletions.
5 changes: 0 additions & 5 deletions .changeset/fresh-poems-compare.md

This file was deleted.

8 changes: 0 additions & 8 deletions .changeset/serious-bulldogs-unite.md

This file was deleted.

1 change: 0 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ jobs:
matrix:
include:
- task: formatting:check
- task: tsc
- task: lint
- task: test
- task: e2e
Expand Down
78 changes: 4 additions & 74 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -46,33 +46,27 @@ verify-dist: env

# checks all projects for lint errors
.PHONY: lint
lint: env
lint: install
$(call log,"Linting projects")
@corepack pnpm -r lint
@node ./tools/scripts/check-packages-for-tslib.mjs

# check repo for formatting errors
.PHONY: formatting\:check
formatting\:check: env
formatting\:check: install
$(call log,"Checking formatting across repo")
@corepack pnpm prettier --ignore-unknown --cache --check .

# attemps to fix lint errors across all projects
.PHONY: fix
fix: env
fix: install
$(call log,"Attempting to fix issues across all projects")
@corepack pnpm -r fix
@corepack pnpm prettier --ignore-unknown --cache --write .

# type-checking all projects
.PHONY: tsc
tsc: env
$(call log,"Checking types across all projects")
@corepack pnpm -r tsc

# makes sure absolutely everything is working
.PHONY: validate
validate: env tsc lint test e2e build verify-dist build-storybook
validate: env lint test e2e build verify-dist build-storybook

##################################### BUILD ####################################

Expand Down Expand Up @@ -163,10 +157,6 @@ install: check-node-version
@guardian/ab-core\:test: env
@corepack pnpm --filter @guardian/ab-core test

.PHONY: @guardian/ab-core\:tsc
@guardian/ab-core\:tsc: env
@corepack pnpm --filter @guardian/ab-core tsc

.PHONY: @guardian/ab-core\:verify-dist
@guardian/ab-core\:verify-dist: env
@corepack pnpm --filter @guardian/ab-core verify-dist
Expand All @@ -191,10 +181,6 @@ install: check-node-version
@guardian/ab-react\:test: env
@corepack pnpm --filter @guardian/ab-react test

.PHONY: @guardian/ab-react\:tsc
@guardian/ab-react\:tsc: env
@corepack pnpm --filter @guardian/ab-react tsc

.PHONY: @guardian/ab-react\:verify-dist
@guardian/ab-react\:verify-dist: env
@corepack pnpm --filter @guardian/ab-react verify-dist
Expand All @@ -207,10 +193,6 @@ install: check-node-version
@guardian/browserslist-config\:lint: env
@corepack pnpm --filter @guardian/browserslist-config lint

.PHONY: @guardian/browserslist-config\:tsc
@guardian/browserslist-config\:tsc: env
@corepack pnpm --filter @guardian/browserslist-config tsc

.PHONY: @guardian/browserslist-config\:update-readme
@guardian/browserslist-config\:update-readme: env
@corepack pnpm --filter @guardian/browserslist-config update-readme
Expand All @@ -223,10 +205,6 @@ install: check-node-version
@guardian/cobalt-plugin-ts\:lint: env
@corepack pnpm --filter @guardian/cobalt-plugin-ts lint

.PHONY: @guardian/cobalt-plugin-ts\:tsc
@guardian/cobalt-plugin-ts\:tsc: env
@corepack pnpm --filter @guardian/cobalt-plugin-ts tsc

.PHONY: @guardian/core-web-vitals\:build
@guardian/core-web-vitals\:build: env
@corepack pnpm --filter @guardian/core-web-vitals build
Expand All @@ -247,10 +225,6 @@ install: check-node-version
@guardian/core-web-vitals\:test: env
@corepack pnpm --filter @guardian/core-web-vitals test

.PHONY: @guardian/core-web-vitals\:tsc
@guardian/core-web-vitals\:tsc: env
@corepack pnpm --filter @guardian/core-web-vitals tsc

.PHONY: @guardian/core-web-vitals\:verify-dist
@guardian/core-web-vitals\:verify-dist: env
@corepack pnpm --filter @guardian/core-web-vitals verify-dist
Expand All @@ -267,10 +241,6 @@ install: check-node-version
@guardian/design-tokens\:lint: env
@corepack pnpm --filter @guardian/design-tokens lint

.PHONY: @guardian/design-tokens\:tsc
@guardian/design-tokens\:tsc: env
@corepack pnpm --filter @guardian/design-tokens tsc

.PHONY: @guardian/eslint-config\:fix
@guardian/eslint-config\:fix: env
@corepack pnpm --filter @guardian/eslint-config fix
Expand All @@ -279,10 +249,6 @@ install: check-node-version
@guardian/eslint-config\:lint: env
@corepack pnpm --filter @guardian/eslint-config lint

.PHONY: @guardian/eslint-config\:tsc
@guardian/eslint-config\:tsc: env
@corepack pnpm --filter @guardian/eslint-config tsc

.PHONY: @guardian/eslint-config-typescript\:fix
@guardian/eslint-config-typescript\:fix: env
@corepack pnpm --filter @guardian/eslint-config-typescript fix
Expand All @@ -291,10 +257,6 @@ install: check-node-version
@guardian/eslint-config-typescript\:lint: env
@corepack pnpm --filter @guardian/eslint-config-typescript lint

.PHONY: @guardian/eslint-config-typescript\:tsc
@guardian/eslint-config-typescript\:tsc: env
@corepack pnpm --filter @guardian/eslint-config-typescript tsc

.PHONY: @guardian/identity-auth\:build
@guardian/identity-auth\:build: env
@corepack pnpm --filter @guardian/identity-auth build
Expand All @@ -315,10 +277,6 @@ install: check-node-version
@guardian/identity-auth\:test: env
@corepack pnpm --filter @guardian/identity-auth test

.PHONY: @guardian/identity-auth\:tsc
@guardian/identity-auth\:tsc: env
@corepack pnpm --filter @guardian/identity-auth tsc

.PHONY: @guardian/identity-auth\:verify-dist
@guardian/identity-auth\:verify-dist: env
@corepack pnpm --filter @guardian/identity-auth verify-dist
Expand All @@ -343,10 +301,6 @@ install: check-node-version
@guardian/identity-auth-frontend\:test: env
@corepack pnpm --filter @guardian/identity-auth-frontend test

.PHONY: @guardian/identity-auth-frontend\:tsc
@guardian/identity-auth-frontend\:tsc: env
@corepack pnpm --filter @guardian/identity-auth-frontend tsc

.PHONY: @guardian/identity-auth-frontend\:verify-dist
@guardian/identity-auth-frontend\:verify-dist: env
@corepack pnpm --filter @guardian/identity-auth-frontend verify-dist
Expand Down Expand Up @@ -379,10 +333,6 @@ install: check-node-version
@guardian/libs\:test: env
@corepack pnpm --filter @guardian/libs test

.PHONY: @guardian/libs\:tsc
@guardian/libs\:tsc: env
@corepack pnpm --filter @guardian/libs tsc

.PHONY: @guardian/libs\:verify-dist
@guardian/libs\:verify-dist: env
@corepack pnpm --filter @guardian/libs verify-dist
Expand All @@ -403,10 +353,6 @@ install: check-node-version
@guardian/newsletter-types\:lint: env
@corepack pnpm --filter @guardian/newsletter-types lint

.PHONY: @guardian/newsletter-types\:tsc
@guardian/newsletter-types\:tsc: env
@corepack pnpm --filter @guardian/newsletter-types tsc

.PHONY: @guardian/prettier\:fix
@guardian/prettier\:fix: env
@corepack pnpm --filter @guardian/prettier fix
Expand All @@ -415,10 +361,6 @@ install: check-node-version
@guardian/prettier\:lint: env
@corepack pnpm --filter @guardian/prettier lint

.PHONY: @guardian/prettier\:tsc
@guardian/prettier\:tsc: env
@corepack pnpm --filter @guardian/prettier tsc

.PHONY: @guardian/source\:build
@guardian/source\:build: env
@corepack pnpm --filter @guardian/source build
Expand Down Expand Up @@ -455,10 +397,6 @@ install: check-node-version
@guardian/source\:test: env
@corepack pnpm --filter @guardian/source test

.PHONY: @guardian/source\:tsc
@guardian/source\:tsc: env
@corepack pnpm --filter @guardian/source tsc

.PHONY: @guardian/source\:verify-dist
@guardian/source\:verify-dist: env
@corepack pnpm --filter @guardian/source verify-dist
Expand Down Expand Up @@ -491,10 +429,6 @@ install: check-node-version
@guardian/source-development-kitchen\:test: env
@corepack pnpm --filter @guardian/source-development-kitchen test

.PHONY: @guardian/source-development-kitchen\:tsc
@guardian/source-development-kitchen\:tsc: env
@corepack pnpm --filter @guardian/source-development-kitchen tsc

.PHONY: @guardian/source-development-kitchen\:verify-dist
@guardian/source-development-kitchen\:verify-dist: env
@corepack pnpm --filter @guardian/source-development-kitchen verify-dist
Expand All @@ -511,10 +445,6 @@ github-pages\:dev: env
github-pages\:start: env
@corepack pnpm --filter github-pages start

.PHONY: github-pages\:tsc
github-pages\:tsc: env
@corepack pnpm --filter github-pages tsc

.PHONY: storybooks\:dev
storybooks\:dev: env
@corepack pnpm --filter storybooks dev
Expand Down
17 changes: 0 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ Tasks that apply to all projects are defined in the [`Makefile`](./Makefile):
- `make ls` _lists available `make` targets_
- `make storybooks` _runs storybook for all projects in single instance_
- `make test` _runs the unit tests for all projects_
- `make tsc` _type-checking all projects_
- `make validate` _makes sure absolutely everything is working_
- `make verify-dist` _runs unit tests against dist for all projects_

Expand All @@ -78,7 +77,6 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/ab-core:fix`
- `make @guardian/ab-core:lint`
- `make @guardian/ab-core:test`
- `make @guardian/ab-core:tsc`
- `make @guardian/ab-core:verify-dist`

#### @guardian/ab-react
Expand All @@ -88,21 +86,18 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/ab-react:fix`
- `make @guardian/ab-react:lint`
- `make @guardian/ab-react:test`
- `make @guardian/ab-react:tsc`
- `make @guardian/ab-react:verify-dist`

#### @guardian/browserslist-config

- `make @guardian/browserslist-config:fix`
- `make @guardian/browserslist-config:lint`
- `make @guardian/browserslist-config:tsc`
- `make @guardian/browserslist-config:update-readme`

#### @guardian/cobalt-plugin-ts

- `make @guardian/cobalt-plugin-ts:fix`
- `make @guardian/cobalt-plugin-ts:lint`
- `make @guardian/cobalt-plugin-ts:tsc`

#### @guardian/core-web-vitals

Expand All @@ -111,27 +106,23 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/core-web-vitals:fix`
- `make @guardian/core-web-vitals:lint`
- `make @guardian/core-web-vitals:test`
- `make @guardian/core-web-vitals:tsc`
- `make @guardian/core-web-vitals:verify-dist`

#### @guardian/design-tokens

- `make @guardian/design-tokens:build`
- `make @guardian/design-tokens:fix`
- `make @guardian/design-tokens:lint`
- `make @guardian/design-tokens:tsc`

#### @guardian/eslint-config

- `make @guardian/eslint-config:fix`
- `make @guardian/eslint-config:lint`
- `make @guardian/eslint-config:tsc`

#### @guardian/eslint-config-typescript

- `make @guardian/eslint-config-typescript:fix`
- `make @guardian/eslint-config-typescript:lint`
- `make @guardian/eslint-config-typescript:tsc`

#### @guardian/identity-auth

Expand All @@ -140,7 +131,6 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/identity-auth:fix`
- `make @guardian/identity-auth:lint`
- `make @guardian/identity-auth:test`
- `make @guardian/identity-auth:tsc`
- `make @guardian/identity-auth:verify-dist`

#### @guardian/identity-auth-frontend
Expand All @@ -150,7 +140,6 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/identity-auth-frontend:fix`
- `make @guardian/identity-auth-frontend:lint`
- `make @guardian/identity-auth-frontend:test`
- `make @guardian/identity-auth-frontend:tsc`
- `make @guardian/identity-auth-frontend:verify-dist`

#### @guardian/libs
Expand All @@ -162,7 +151,6 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/libs:fix`
- `make @guardian/libs:lint`
- `make @guardian/libs:test`
- `make @guardian/libs:tsc`
- `make @guardian/libs:verify-dist`

#### @guardian/newsletter-types
Expand All @@ -171,13 +159,11 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/newsletter-types:dev`
- `make @guardian/newsletter-types:fix`
- `make @guardian/newsletter-types:lint`
- `make @guardian/newsletter-types:tsc`

#### @guardian/prettier

- `make @guardian/prettier:fix`
- `make @guardian/prettier:lint`
- `make @guardian/prettier:tsc`

#### @guardian/source

Expand All @@ -190,7 +176,6 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/source:lint`
- `make @guardian/source:storybook`
- `make @guardian/source:test`
- `make @guardian/source:tsc`
- `make @guardian/source:verify-dist`

#### @guardian/source-development-kitchen
Expand All @@ -202,15 +187,13 @@ Project-specific tasks are defined as `scripts` in their `package.json`, and can
- `make @guardian/source-development-kitchen:lint`
- `make @guardian/source-development-kitchen:storybook`
- `make @guardian/source-development-kitchen:test`
- `make @guardian/source-development-kitchen:tsc`
- `make @guardian/source-development-kitchen:verify-dist`

#### github-pages

- `make github-pages:build`
- `make github-pages:dev`
- `make github-pages:start`
- `make github-pages:tsc`

#### storybooks

Expand Down
15 changes: 1 addition & 14 deletions apps/github-pages/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
"scripts": {
"build": "wireit",
"dev": "wireit",
"start": "wireit",
"tsc": "wireit"
"start": "wireit"
},
"devDependencies": {
"@astrojs/check": "0.7.0",
Expand Down Expand Up @@ -55,18 +54,6 @@
"files": [
"dist/**"
]
},
"tsc": {
"command": "tsc --pretty",
"files": [
"src/**/*",
"tsconfig.json",
"../../libs/@guardian/tsconfig/tsconfig.json",
"../../@types/**",
"../../tsconfig.base.json",
"!(dist)/**"
],
"output": []
}
}
}
Loading

0 comments on commit 9979941

Please sign in to comment.