wasp/waspc/packages/ts-inspect
2023-06-22 15:37:07 -04:00
..
src [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
test [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
.gitignore [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
eslintrc.cjs [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
jest.config.js [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
package-lock.json [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
package.json [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
README.md [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00
tsconfig.json [waspls] diagnostics for external imports and goto definition (#1268) 2023-06-22 15:37:07 -04:00

NOTE: typescript is purposefully a normal dependency instead of a dev dependency.

Run the program node ./dist/index.js and pass a list of export requests over stdin:

[
  { "filenames": ["./src/exports.ts"] },
  {
    "tsconfig": "~/dev/wasp-todoapp/src/client/tsconfig.json",
    "filenames": ["~/dev/wasp-todoapp/src/client/MainPage.tsx"]
  }
]

It will respond with an object mapping filenames to exports, something like:

{
  "./src/exports.ts": [
    { "type": "named", "name": "getExportsOfFiles" },
    { "type": "default" }
  ]
}