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

Fix ESM build to contain import statements with full file extensions #49

Merged
merged 3 commits into from
Jun 22, 2024

Conversation

shtaif
Copy link
Owner

@shtaif shtaif commented Jun 21, 2024

Up until now, the what used to be built into the ./dist/esm;

"outDir": "./dist/esm",

seems to not have actually been 100% proper ESM code, if not outright invalid, since all the generated import statements appearing in the output files did not include fully qualified file paths including the file extension.

  • This should make all built output contain fully qualified import file paths (including the CJS build, harmlessly).

  • Set the pnpm version that's installed during CI to a fixed earlier pnpm^8 one since the latest is not compatible with the old Node 16 that's used across the CI (which should be tackled separately in some future PR).

  • Also some TypeScript-related improvements which should make IDE detect the tsconfig better and also load a proper tsconfig configuration for the files in ./spec dir which I suspect I couldn't do up until now.

@shtaif shtaif self-assigned this Jun 21, 2024
…which is compatible with the Node version 16.14.0 that's used in the meantime
@shtaif shtaif force-pushed the fix-esm-build-import-file-extensions branch from 2232136 to 43f4ac7 Compare June 21, 2024 23:39
@shtaif shtaif marked this pull request as ready for review June 21, 2024 23:41
@shtaif shtaif changed the title Fix ESM build to contain imports statements with full file extensions Fix ESM build to contain import statements with full file extensions Jun 22, 2024
@shtaif shtaif merged commit 2aad91d into master Jun 22, 2024
6 checks passed
@shtaif shtaif deleted the fix-esm-build-import-file-extensions branch June 22, 2024 20:29
shtaif pushed a commit that referenced this pull request Jun 22, 2024
## [1.2.5](v1.2.4...v1.2.5) (2024-06-22)

### Bug Fixes

* fix ESM build to contain `import` statements with full file extensions ([#49](#49)) ([2aad91d](2aad91d))

### Refactor

* internal logic fix in the multicast channel code (no public behavior impact) - ensure to mark a channel's iterator as closed for further pull attempts as soon as it realizes its parent channel itself had already ended/errored out ([#47](#47)) ([d11a74b](d11a74b))

### Tests

* split the single current test file into two - one having all the tests relevant only for the `iterified` function and the other all the tests relevant only for `iterifiedUnwrapped` ([#48](#48)) ([815d357](815d357))
Copy link

🎉 This PR is included in version 1.2.5 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant