Skip to content

build(ios27): resolve ESM imports during compilation - #235

Merged
rdlabo merged 1 commit into
mainfrom
fix/build-esm-output
Sep 28, 2026
Merged

rdlabo merged 1 commit into
mainfrom
fix/build-esm-output

Conversation

@rdlabo

@rdlabo rdlabo commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

The iOS 27 theme's emitted ESM contained extensionless imports, so direct Node imports could fail. Keep TypeScript source imports extensionless, matching Ionic's source style, and resolve them automatically during the normal build.

  • Use @rdlabo/ionic-theme-utils@0.1.2 for the shared rdlabo-build-theme and rdlabo-check-esm CLIs.
  • Retain tsc --noEmit for type checking and use tsdown to emit ESM JavaScript and declarations with resolved relative specifiers. Source files are unchanged; dependencies stay external and CSS output is preserved.
  • Declare "type": "module", use TypeScript's bundler resolution mode, and rename the CommonJS Prettier configuration to .cjs.
  • Add packed ESM and declaration checks to CI and document the shared build commands.

This follows the build-time approach discussed in #222. Shared tooling: rdlabo-dev/ionic-theme-utils#5.

Validation on Node 24.17.0:

  • Full package build and formatting checks.
  • npm tarball imports and relative JavaScript/declaration references.
  • NodeNext consumer type checking without skipLibCheck.
  • Angular demo production build and lint.
  • Demo unit tests: 62 passed.

Additional local validation:

  • Playwright in the Linux v1.58.2 container: 372 passed and 1 passed on retry. The flaky crossfade test then passed three consecutive runs with retries disabled. Existing screenshot baselines were unchanged.
  • The production demo rendered successfully in Chromium and WebKit without page errors.
  • Both the demo and a separate consumer of the npm tarball built successfully for iOS 27 Simulator.
  • Two targeted XCUITests passed on rerun: dark appearance/rotation and the packaged native plugin. Normal CLI launch also displayed the demo and native tabs.
  • The full native suite is not green: the initial run failed all 11 cases with blank screens or launch timeouts. A full rerun was stopped after recurring launch timeouts. No code changes were made between these runs, and the cause is not yet established.
  • No physical-device testing was performed.

Devin Review

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Playwright test results

passed  373 passed

Details

stats  373 tests across 20 suites
duration  3 minutes, 45 seconds
commit  7d2c45f
info  This detailed result covers Ionic 9 only. Ionic 8 runs against the same screenshots in a separate matrix job; check the workflow run for both results. To update the screenshots, comment with /update-screenshots.

github-actions Bot added a commit that referenced this pull request Sep 28, 2026
github-actions Bot added a commit that referenced this pull request Sep 28, 2026
@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

📊 Ionic 9 Playwright Test Report

View the detailed Ionic 9 report: https://rdlabo-dev.github.io/ionic-theme-ios27/pr-235/

Ionic 8 runs against the same screenshots in a separate matrix job. View both results in the workflow run.

github-actions Bot added a commit that referenced this pull request Sep 28, 2026
@rdlabo
rdlabo merged commit 8267cff into main Sep 28, 2026
28 of 33 checks 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.

1 participant