Description
The federated plugin design describes having a dartPluginClass for each platform, allowing the registration of Dart plugin implementation details on a per-platform basis. Currently actually doing that is only possible on Web (AFAICT).
This is currently blocking implementation of path_provider
and shared_preferences
on Linux, where there's no need to use anything but pure Dart, because there's no way to bind the implementation to the interface package. (This is would also be very useful in conjunction with FFI; e.g., the Windows path_provider
implementation could easily be Dart + FFI to a couple of system calls, significantly reducing the amount of code involved.)
Greg and I looked at this a little bit at the end of last week. Adding the auto-generation of a Dart registrant is simple, but we got stuck on actually injecting the call to that registrant in a way that doesn't break existing functionality (in particular, passing an arbitrary start point to the embedder API). I'm not sure if there was already a plan/design in place to address that.
/cc @amirh