Skip to content

feat(@formatjs/intl-getcanonicallocales)!: convert to esm#5457

Closed
longlho wants to merge 1 commit intomainfrom
12-14-feat_formatjs_intl-getcanonicallocales_convert_to_esm
Closed

feat(@formatjs/intl-getcanonicallocales)!: convert to esm#5457
longlho wants to merge 1 commit intomainfrom
12-14-feat_formatjs_intl-getcanonicallocales_convert_to_esm

Conversation

@longlho
Copy link
Member

@longlho longlho commented Dec 14, 2025

TL;DR

Convert intl-getcanonicallocales package to ESM format.

What changed?

  • Added "type": "module" to package.json
  • Updated import paths to include .js extensions
  • Added exports field to package.json to define entry points
  • Removed main field from package.json
  • Added skip_cjs = True to the Bazel build configuration

How to test?

  1. Import the package in an ESM environment
  2. Verify that all exports work correctly
  3. Test the polyfill functionality
  4. Run existing tests to ensure functionality is preserved

Why make this change?

This change modernizes the package to use ES Modules format, which is the standard module system for JavaScript. This improves compatibility with modern tooling and bundlers while maintaining the same functionality. The explicit .js extensions in import paths and the exports field in package.json ensure proper resolution in ESM environments.

@longlho longlho marked this pull request as ready for review December 14, 2025 17:10
Copy link
Member Author

longlho commented Dec 14, 2025

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • main - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has required the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@graphite-app graphite-app bot changed the base branch from 12-14-feat_intl-messageformat_convert_to_esm to graphite-base/5457 December 14, 2025 17:15
@graphite-app graphite-app bot force-pushed the graphite-base/5457 branch from 7d98a7c to e6459ea Compare December 14, 2025 17:15
@graphite-app graphite-app bot force-pushed the 12-14-feat_formatjs_intl-getcanonicallocales_convert_to_esm branch from 3f8d1a4 to 3568809 Compare December 14, 2025 17:15
@graphite-app graphite-app bot changed the base branch from graphite-base/5457 to main December 14, 2025 17:16
@graphite-app graphite-app bot force-pushed the 12-14-feat_formatjs_intl-getcanonicallocales_convert_to_esm branch from 3568809 to 9a8d514 Compare December 14, 2025 17:16
@longlho longlho force-pushed the 12-14-feat_formatjs_intl-getcanonicallocales_convert_to_esm branch from 9a8d514 to 7a4a4bd Compare December 14, 2025 17:23
@graphite-app
Copy link

graphite-app bot commented Dec 14, 2025

Merge activity

  • Dec 14, 5:25 PM UTC: longlho added this pull request to the Graphite merge queue.
  • Dec 14, 5:25 PM UTC: CI is running for this pull request on a draft pull request (#5461) due to your merge queue CI optimization settings.
  • Dec 14, 5:27 PM UTC: Merged by the Graphite merge queue via draft PR: #5461.

graphite-app bot pushed a commit that referenced this pull request Dec 14, 2025
### TL;DR

Convert `intl-getcanonicallocales` package to ESM format.

### What changed?

- Added `"type": "module"` to package.json
- Updated import paths to include `.js` extensions
- Added `exports` field to package.json to define entry points
- Removed `main` field from package.json
- Added `skip_cjs = True` to the Bazel build configuration

### How to test?

1. Import the package in an ESM environment
2. Verify that all exports work correctly
3. Test the polyfill functionality
4. Run existing tests to ensure functionality is preserved

### Why make this change?

This change modernizes the package to use ES Modules format, which is the standard module system for JavaScript. This improves compatibility with modern tooling and bundlers while maintaining the same functionality. The explicit `.js` extensions in import paths and the `exports` field in package.json ensure proper resolution in ESM environments.
@graphite-app graphite-app bot closed this Dec 14, 2025
@graphite-app graphite-app bot deleted the 12-14-feat_formatjs_intl-getcanonicallocales_convert_to_esm branch December 14, 2025 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant