Skip to content

Update intl-tel-input w/ npm auto-update - #2228

Merged
MattIPv4 merged 3 commits into
cdnjs:masterfrom
simonabadoiu:fix/intl-tel-input-esm
Nov 23, 2026
Merged

MattIPv4 merged 3 commits into
cdnjs:masterfrom
simonabadoiu:fix/intl-tel-input-esm

Conversation

@simonabadoiu

@simonabadoiu simonabadoiu commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

📎 clopy sim-ai

Change

Add js/*.mjs and js/*.d.ts to the existing npm dist file map. The npm tarball ships three self-contained ESM builds (data.mjs, intlTelInput.mjs, intlTelInputWithUtils.mjs) and four matching declarations (data, intlTelInput, locale, utils), but the current map only selects JS, CSS, locales, and images. Existing paths and the default file are unchanged.

The ESM builds can be imported straight from cdnjs with no bundler, and the declarations serve URL-import consumers such as Deno. cdnjs published intlTelInput.d.ts under the old git layout (e.g. 25.5.2). css/styles.d.ts is left out; it only types CSS-module imports.

This does not restore the old git build/, react/build/, or vue/build/ paths. React and Vue now ship as separate npm packages (@intl-tel-input/react, @intl-tel-input/vue), which are not on cdnjs.

Verification

  • With the file-map matcher on npm 29.5.11, the 83 files already selected stay selected, plus the three .mjs and four .d.ts (90 total). The .mjs files also match on 28.0.0.
  • The three modules pass node --check --input-type=module and have no external imports.
  • The local checker is a Linux binary and Docker is unavailable here; CI still needs to validate the config.

Refs #2114. This only affects future imports; already-published versions keep their current files.

Map the three self-contained dist/js/*.mjs modules alongside the existing browser JS/CSS assets. They are supported by cdnjs and available on npm, but were omitted when the package switched from git to npm in cdnjs#2219. Existing versions need reingestion to gain the modules. Refs cdnjs#2114
Map the four dist/js/*.d.ts files that pair with the ESM builds, for consumers importing from a URL (e.g. Deno). cdnjs published intlTelInput.d.ts under the old git layout. css/styles.d.ts is left out: it only types CSS-module imports.
@simonabadoiu simonabadoiu changed the title Publish intl-tel-input ESM builds from npm Publish intl-tel-input ESM builds and type declarations from npm Nov 23, 2026
Comment thread packages/i/intl-tel-input.json Resolved
@MattIPv4 MattIPv4 changed the title Publish intl-tel-input ESM builds and type declarations from npm Update intl-tel-input w/ npm auto-update Nov 23, 2026
@MattIPv4
MattIPv4 merged commit a471b6d into cdnjs:master Nov 23, 2026
1 check passed
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.

2 participants