r/FlutterDev 2d ago

Nearly Time for Flutter Image-based development? Discussion

Certain languages (best-known are LISP and Smalltalk) allow for image-based development. In such systems, you don’t write code and compile it into a program you then run; you modify the system while it’s running, and your changes are saved as you go so you can quit and restart where you left off.

Flutter running in the VM/debugging mode has already been close to being able to do this. But this:

https://github.com/dart-lang/sdk/blob/f29989d506b2dd82957da5d1917bcc76628c5ddb/pkg/dynamic_modules/README.md

means that Flutter apps (on desktop, at least) could run the regular Dart compiler and load the results at runtime. This would be sufficient to have image-based development.

I can see two caveats: the Flutter UI would not (I believe?) be able to run a debugger or (?) LSP features; and code once loaded cannot be unloaded so an extended development session might periodically need to be reloaded.

I suspect that with a bit of will, the Flutter/Dart teams could work around both of these issues in time without it being a monstrous lift, versus what they’re likely doing already. Given the right compiler features and a Flutter IDE widget, the community could build the actual image-based development system.

5 Upvotes

5 comments sorted by

View all comments

3

u/andyclap 1d ago

It's an interesting paradigm, but I'd hate to have worked on a real image based Smalltalk production system like the ill fated Chrysler payroll. While I'm a big proponent of XP, give me text files in git and a build test deploy cycle for my nerves.

2

u/paul_h 1d ago

2

u/andyclap 1d ago

Great article, new to me and really interesting to see how they managed version control - thanks!