fix: exp post build script to strip Table_Internal#6326
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthrough
ChangesInternal type adoption and .d.ts rewrite
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
View your CI Pipeline Execution ↗ for commit 4e7d50a
☁️ Nx Cloud last updated this comment at |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@scripts/rewrite-table-core-dts.mjs`:
- Around line 92-109: The regex pattern in the replacer function does not match
TypeScript's `import type { ... }` syntax, only `import { ... }` and `export {
... }`. Modify the regex pattern to make the `type` keyword optional between the
import/export keyword and the opening brace, so that both `import { ... }` and
`import type { ... }` statements are properly matched and processed by the
filtering logic.
- Around line 73-87: The removeTypeAlias function currently searches for the
pattern `type ${typeName}` but does not account for the `export` keyword that
may precede it in the TypeScript declaration file. When an exported type alias
is found, the function only removes from the word `type` onward, leaving behind
the dangling `export` keyword. Fix this by checking if the character sequence
before the start position contains `export ` (including the space), and if so,
adjust the start position to include and remove the export keyword as well. This
ensures that both exported and non-exported type aliases are completely removed
without leaving orphaned tokens.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: ba3a2dcc-5fa1-4116-817b-c15b906fae24
📒 Files selected for processing (4)
packages/table-core/package.jsonpackages/table-core/src/core/headers/coreHeadersFeature.types.tspackages/table-core/src/types/Column.tsscripts/rewrite-table-core-dts.mjs
🎯 Changes
✅ Checklist
pnpm test:pr.Summary by CodeRabbit