JS: Adds basic support for webpack-dev-server and importing from neighbouring packages.#3630
Conversation
asgerf
left a comment
There was a problem hiding this comment.
Cool! Nice and simple.
The import resolution is indeed something I wanted to handle via the monorepo support I've been working on, but given the simplicity of this solution I see no harm in landing that first.
| * An Express router. | ||
| */ | ||
| class RouterDefinition extends InvokeExpr { | ||
| class RouterDefinition extends Expr { |
There was a problem hiding this comment.
Hm, an unfortunate breaking change. Would it make sense to add a case in isRouter instead of this change? That's also how we incorporate type information in here.
|
A performance evaluation came back, and it doesn't look too good. But, the performance penalty comes from resolving extra imports. For example: (The rebase below didn't change anything, it just added tests and a change-note). |
|
I think we should go ahead with this. The performance cost is unfortunate but not really the fault of this PR. Resolving imports is definitely the right thing to do. |
Gets a TP for CVE-2018-6342
Does 2 things, and I'm somewhat unsure about both.
webpack-dev-server.Example:
It is essentially very basic non-TypeScript monorepo support.
The
resolveNeighbourPackagepredicate is outsideImportclass because I got join-order issues otherwise. (Same reason forpragma[noinline]).TODO: