-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Mega Refactor: Reorganize into single package.json, fix all types, im…
…prove imports, improve organization (#120) * remove package json for dev server api * fix server not proxying to api properly * checkpoint root package json can run frontend * remove frontend package json * remove package locks and example project package * simplify example project package.json * fix build issue with cli packages * improve open test * no need to run server tests explicitly * fix import issue * fix server imports * fix minor bug with package exmaples not updating on change * checkpoint, refactor to fix type performance and new dir structure * checkpoint, fixing type errors, rename api directory * more refactoring to simplify dir structure * more api fixes for refactor * more fixes to adapt index * refactor to cli directory * fix many type issues * wip fixing type issues, ~20 remaining * fix type errors * add typecheck github action * fix workflows to not use bootstrap * fix typecheck to use bun * typecheck workflow fix * test fix * fix formatbot to format * formatbot: Automatically format code * couple test to db instance * fix test parallelization issue --------- Co-authored-by: tscircuitbot <[email protected]>
- Loading branch information
1 parent
76b185d
commit a12b9f3
Showing
206 changed files
with
431 additions
and
18,925 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# Created using @tscircuit/plop (npm install -g @tscircuit/plop) | ||
name: Type Check | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
type-check: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup bun | ||
uses: oven-sh/setup-bun@v1 | ||
with: | ||
bun-version: latest | ||
|
||
- name: Install dependencies | ||
run: bun i | ||
|
||
- name: Build (required for dist imports) | ||
run: bun run build | ||
|
||
- name: Run format check | ||
run: bunx tsc --noEmit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,3 +9,5 @@ dist | |
|
||
.vscode | ||
.aider* | ||
package-lock.json | ||
**/package-lock.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
# Getting Started with Development for @tscircuit/cli | ||
|
||
1. Run `bun install` | ||
2. Run `bun bootstrap` | ||
2. Run `bun run dev` | ||
|
||
You now have a development server running on http://localhost:5173 (don't use | ||
the one on port 3020, it won't auto-reload frontend changes) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions
4
dev-server-api/src/middlewares/with-db.ts → api/lib/middlewares/with-db.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
dev-server-api/routes/api/db/download.ts → api/routes/api/db/download.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...routes/api/dev_package_examples/create.ts → ...routes/api/dev_package_examples/create.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...pi/routes/api/dev_package_examples/get.ts → api/routes/api/dev_package_examples/get.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...i/routes/api/dev_package_examples/list.ts → api/routes/api/dev_package_examples/list.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...routes/api/dev_package_examples/update.ts → ...routes/api/dev_package_examples/update.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...server-api/routes/api/dev_server/reset.ts → api/routes/api/dev_server/reset.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 1 addition & 3 deletions
4
...r-api/routes/api/export_files/download.ts → api/routes/api/export_files/download.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 3 additions & 4 deletions
7
...-api/routes/api/export_requests/create.ts → api/routes/api/export_requests/create.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 3 additions & 6 deletions
9
...ver-api/routes/api/export_requests/get.ts → api/routes/api/export_requests/get.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 2 additions & 3 deletions
5
...er-api/routes/api/export_requests/list.ts → api/routes/api/export_requests/list.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 3 additions & 5 deletions
8
...-api/routes/api/export_requests/update.ts → api/routes/api/export_requests/update.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ver-api/routes/api/package_info/create.ts → api/routes/api/package_info/create.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 3 additions & 2 deletions
5
...server-api/routes/api/package_info/get.ts → api/routes/api/package_info/get.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
// import { WinterSpecRouteMap } from "@winterspec/types" | ||
|
||
const routeMap = { | ||
"/api/db/download": (await import('./routes/api/db/download.ts')).default, | ||
"/api/dev_package_examples/create": (await import('./routes/api/dev_package_examples/create.ts')).default, | ||
"/api/dev_package_examples/get": (await import('./routes/api/dev_package_examples/get.ts')).default, | ||
"/api/dev_package_examples/list": (await import('./routes/api/dev_package_examples/list.ts')).default, | ||
"/api/dev_package_examples/update": (await import('./routes/api/dev_package_examples/update.ts')).default, | ||
"/api/dev_server/reset": (await import('./routes/api/dev_server/reset.ts')).default, | ||
"/api/export_files/create": (await import('./routes/api/export_files/create.ts')).default, | ||
"/api/export_files/download": (await import('./routes/api/export_files/download.ts')).default, | ||
"/api/export_requests/create": (await import('./routes/api/export_requests/create.ts')).default, | ||
"/api/export_requests/get": (await import('./routes/api/export_requests/get.ts')).default, | ||
"/api/export_requests/list": (await import('./routes/api/export_requests/list.ts')).default, | ||
"/api/export_requests/update": (await import('./routes/api/export_requests/update.ts')).default, | ||
"/api/health": (await import('./routes/api/health.ts')).default, | ||
"/api/package_info/create": (await import('./routes/api/package_info/create.ts')).default, | ||
"/api/package_info/get": (await import('./routes/api/package_info/get.ts')).default, | ||
"/health": (await import('./routes/health.ts')).default, | ||
"/": (await import('./routes/index.ts')).default | ||
} | ||
|
||
export default routeMap |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.