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
[babel 8] Publish .d.ts for every package #16416
base: main
Are you sure you want to change the base?
Conversation
} | ||
const exports = []; | ||
for (const prop of obj.properties) { | ||
+ // Rollup generates an object of getters for re-exports sometimes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rollup-plugin-dts
currently crashes on namespace objects generated by Rollup. I will open a PR upstream.
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/56861 |
Uhm it looks like |
I'm not sure if we can somehow check compatibility with There is also a long-standing problem where we cannot declare type dependencies, which may result in users having to manually install the dependencies in each type. |
packages/babel-parser/src/index.ts
Outdated
@@ -22,6 +22,7 @@ import { | |||
} from "./tokenizer/types.ts"; | |||
|
|||
import type { Expression, File } from "./types.ts"; | |||
export type { File }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's also export Expression
because there is parseExpression
.
d4bab9e
to
4e399b3
Compare
@@ -3,8 +3,7 @@ import fs from "fs"; | |||
import { join } from "path"; | |||
import { URL, fileURLToPath } from "url"; | |||
import { minify } from "terser"; | |||
import { transformSync } from "@babel/core"; | |||
import presetTypescript from "@babel/preset-typescript"; | |||
import { babel, presetTypescript } from "$repo-utils/babel-top-level"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is because now this package has a devDependency
on @babel/core@workspace
(for types), but we need the root dependency to compile.
Wow CI seems to be green (except for e2e) |
Fixes #1, Fixes #2
Some examples:
@babel/plugin-proposal-decorators
@babel/preset-env
@babel/core
@babel/traverse