Add .js extensions to ES module imports in @object-ui/core#347
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…orts - Add .js extension to all relative imports in @object-ui/core package - Remove stale compiled .js and .d.ts files from src/ directory - Fixes CI test failures: "Directory import is not supported resolving ES modules" Co-authored-by: hotlong <50353452+hotlong@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix error in action step execution
Add .js extensions to ES module imports in @object-ui/core
Feb 2, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds .js extensions to ES module imports in @object-ui/core to fix Node.js runtime errors. The package uses "type": "module" which requires explicit file extensions for ES modules. TypeScript preserves these .js extensions during compilation.
Changes:
- Added
.jsextensions to all relative imports/exports in barrel files (index.ts) and internal TypeScript imports - Removed stale build artifacts (
.jsand.d.tsfiles) from thesrc/directory that should only exist indist/
Reviewed changes
Copilot reviewed 15 out of 21 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| packages/core/src/validation/validators/index.ts | Added .js extension to object-validation-engine import |
| packages/core/src/validation/schema-validator.js | Deleted build artifact from src/ |
| packages/core/src/validation/schema-validator.d.ts | Deleted build artifact from src/ |
| packages/core/src/validation/index.ts | Added .js extensions to all module exports |
| packages/core/src/utils/filter-converter.js | Deleted build artifact from src/ |
| packages/core/src/utils/filter-converter.d.ts | Deleted build artifact from src/ |
| packages/core/src/types/index.js | Deleted build artifact from src/ |
| packages/core/src/types/index.d.ts | Deleted build artifact from src/ |
| packages/core/src/registry/PluginSystem.ts | Added .js extensions to internal imports |
| packages/core/src/registry/PluginScopeImpl.ts | Added .js extension to Registry import |
| packages/core/src/query/index.ts | Added .js extension to query-ast export |
| packages/core/src/index.ts | Added .js extensions to all barrel exports |
| packages/core/src/index.js | Deleted build artifact from src/ |
| packages/core/src/index.d.ts | Deleted build artifact from src/ |
| packages/core/src/evaluator/index.ts | Added .js extensions to all module exports |
| packages/core/src/evaluator/ExpressionEvaluator.ts | Added .js extensions to internal imports |
| packages/core/src/builder/schema-builder.js | Deleted build artifact from src/ |
| packages/core/src/builder/schema-builder.d.ts | Deleted build artifact from src/ |
| packages/core/src/adapters/index.js | Deleted build artifact from src/ |
| packages/core/src/adapters/index.d.ts | Deleted build artifact from src/ |
| packages/core/src/actions/index.ts | Added .js extension to ActionRunner export |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Node.js ES modules require explicit file extensions. The compiled output was using directory imports (
export * from './types') which fail at runtime with "Directory import is not supported resolving ES modules".Changes
Added
.jsextension to all relative imports/exports in@object-ui/coresource files:src/index.ts- main barrel exportssrc/*/index.ts- module barrel exportssrc/evaluator/ExpressionEvaluator.ts,src/registry/*.ts- internal importsRemoved stale
.jsand.d.tsfiles fromsrc/(build artifacts belong indist/)Before:
After:
TypeScript preserves the
.jsextensions during compilation, satisfying Node.js ESM requirements while maintainingmoduleResolution: "bundler"for development.Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.