Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Design Meeting Notes, 1/11/2023 #52199

Closed
DanielRosenwasser opened this issue Jan 11, 2023 · 1 comment
Closed

Design Meeting Notes, 1/11/2023 #52199

DanielRosenwasser opened this issue Jan 11, 2023 · 1 comment
Labels
Design Notes Notes from our design meetings

Comments

@DanielRosenwasser
Copy link
Member

Incorrectly Formatted Packages in --moduleResolution bundler/node16

#51973

  • Test to see what breaks if node is redirected to bundler.
  • Previously types would have been resolved.
    • Now the exports.import condition is resolved as per Node 16 rules.
  • Now providing a better error message when we can detect this. You'd get the same error in node16.
    • The messages are still bad because we provide an absolute path to the file instead of a relative path.
    • Presumably we did this because the relative path isn't the correct thing when printing paths in the command line.
  • Aside: would be good to do the same tests for redirecting node16/nodenext

LKG versus node_modules

  • ESLint relies on node_modules, our builds rely on LKG builds in lib.
  • Would be nice if they could agree with each other!
  • Would also be nice to get rid of lib and use npm for boostrapping.
    • But then people can't clone TypeScript and just run from lib.
    • But we could just do that on release branches anyway.
  • Not great to snapshot 40MB of JS on every LKG!
  • So switch to nightlies on npm instead of building from lib?
    • Have to always npm ci on git pull
    • Technically true today, but it's rare that that even makes a difference. So you can get away with it.
    • But it would also be rare for us too. How often do we update LKG?
    • EXCEPT you still need to when you're bisecting!
      • Ugh - annoying. But might be worth it long term.
  • Edge case - ESLint looks at the current package typescript/ instead of the typescript/node_modules/typescript.
    • Follow up on if this is true.
  • So
    • Switch to using npm and node_modules
    • Delete lib
    • lib gets .gitignore'd
    • We force-add lib on release-X.Y branches and commit it.
    • lib gets published on npm.
    • When we need to take advantage of a new feature sooner than the same day, we can publish an insiders or early nightly instead.
@DanielRosenwasser DanielRosenwasser added the Design Notes Notes from our design meetings label Jan 11, 2023
@jakebailey
Copy link
Member

Edge case - ESLint looks at the current package typescript/ instead of the typescript/node_modules/typescript.

Just to clarify, this was only observed when I was testing "type": "module" with export maps on our own package, since it's a self import at that point, but then I couldn't repro it live in the meeting, so... IDK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Design Notes Notes from our design meetings
Projects
None yet
Development

No branches or pull requests

3 participants