🚀 flutterjs_web: Multi-Page Navigation, SSR Improvements & Runtime Fixes#15
Merged
Conversation
…js exports) - Fixed @flutterjs/runtime package.json main entry point. - Updated ThemeData to initialize textTheme with TextStyle objects. - Enhanced BuildIntegrationGenerator to robustly filter app.js imports against actual exports. - Fixed bare specifier mapping for @flutterjs/material imports. - Updated ImportRewriter to handle export aliases.
Refactors the IR for map literals to use a unified elements list (entries, conditionals, spreads) instead of only entries, and updates code generation to handle conditional and spread elements in map literals. Adds verbose logging support to extraction and codegen passes, and introduces conditional import/export configuration extraction. Removes duplicate MapEntryIR definition and updates widget analyzer to handle new map IR structure.
…ass field and parameter names being incorrectly imported as external symbols - Add suffix-aware filename matching in ImportAnalyzer for UrlStyle/WindowsStyle/PosixStyle - Filter loop variables, class fields, method params from import symbols - Fix IIFE parenthesis placement in statement generator
Add JS interop runtime and rendering stub, tooling, and several fixes: - New example `try_test` with minimal try/catch/finally tests and .gitignore. - Add dart:js_interop and dart:js_interop_unsafe implementations (src + built dist + sourcemaps) and wire them into packages/flutterjs_dart package.json and exports.json. - Implement pattern-matching support in StatementExtractionPass: handle if-case statements, new _extractPattern routine, update pattern-condition extraction, and add a debug print for TryStmt extraction. This enables Dart 3 pattern matching extraction. - Fix JS optimizer to track try/finally blocks and avoid removing finally code or treating code inside try as unreachable. - Improve codegen logging in FileCodeGen (capture stacktrace on errors, log classes, functions) and add a small import map tweak. - Add @flutterjs/rendering package stub with build script (build.js) that enumerates source files, generates exports and an exports.json manifest for the Dart generator. - Update pubjs PackageBuilder to stop skipping node_modules builds (enable building 3rd-party packages), add a debug print, and include standard node_modules paths when resolving builds. - Misc: updated build_info timestamps for several packages. These changes provide JS interop runtime support for generated code, add a rendering package scaffold, and fix the analyzer/optimizer to correctly handle Dart 3 patterns and try/finally semantics.
…obust URI matching
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.
📝 Description
This PR introduces robust runtime, compiler, and rendering improvements for
flutterjs_web. It fixes multiple runtime and import resolution issues, enhances SSR support, improves JS interop, and refactors IR/codegen for better stability.Highlights
HTMLIFrameElementexport andBaseRequestimport resolution using robust URI matchingtry/finallycopyWitherror, app.js export mismatch)🔗 Related Issue
Fixes # (add issue number if applicable)
🏗️ Type of Change
📋 Checklist
📸 Screenshots (if applicable)
🧪 How to Test
flutterjs_webexample/site.copyWithcrash.try/finallyhandling in transpiled output.HTMLIFrameElement,BaseRequest, and alias exports.