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

add an experimental 'flutter build web' call to the backend #2599

Merged
merged 2 commits into from
Jul 21, 2023

Conversation

devoncarew
Copy link
Member

@devoncarew devoncarew commented Jul 18, 2023

Add an experimental 'flutter build web' call to the backend:

  • add an experimental api/v2/_flutterBuild call to the backend
  • it's given a source file and invokes flutter build web; this is currently slower than we'd want but I believe there's some room for improvement in the execution time of flutter build web
  • the flutter web frontend has been updated to use this compile call for both dart and flutter snippets

Many of the changes here are multiple copies of the proto related files. With this change, the new front-end can now run flutter snippets.


  • I’ve reviewed the contributor guide and applied the relevant portions to this PR.
Contribution guidelines:

Note that many Dart repos have a weekly cadence for reviewing PRs - please allow for some latency before initial review feedback.

@devoncarew
Copy link
Member Author

Screenshot 2023-07-18 at 10 41 43 AM

Copy link
Contributor

@johnpryan johnpryan left a comment

Choose a reason for hiding this comment

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

Is this still in the draft stage? Or would you prefer to merge it into main?

pkgs/sketch_pad/README.md Show resolved Hide resolved
pkgs/sketch_pad/lib/model.dart Outdated Show resolved Hide resolved
Copy link
Member Author

@devoncarew devoncarew left a comment

Choose a reason for hiding this comment

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

Is this still in the draft stage? Or would you prefer to merge it into main?

I'd prefer to merge it - it'll make it easier to iterate on (the restful API is named w/ an underscore - _flutterBuild - to help make sure we communicate 'do not use' to people).

pkgs/sketch_pad/lib/model.dart Outdated Show resolved Hide resolved
pkgs/sketch_pad/README.md Show resolved Hide resolved
// This disables minification.
'--dart2js-optimization=O1',

// With the web renderer, we don't need to load other (skiawasm) resources.
Copy link
Member Author

Choose a reason for hiding this comment

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

@kevmoo has asked that we look into instead using the skiawasm backend (likely loaded from a CDN). I'll add a todo.

@devoncarew devoncarew merged commit d5d6317 into main Jul 21, 2023
10 checks passed
@devoncarew devoncarew deleted the flutter_build_experimental branch July 21, 2023 01:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants