简体   繁体   中英

Can we create shared library or assembly like .dll in flutter package project?

I'm getting problem with flutter/dart. I created one flutter-package using dart lang, there is so many dart files. But i didn't get any option to make single lib file or assembly like dll (dll in Xamarin). I want to use that API in flutter mobile app [Android/iOS]. So is it possible to make single lib file in dart? I don't want to show a source code to that person, who will use my API in Android/iOS & I don't want to publish my code to pub.dev.

I hope this is possible.

Thanks, i would be grateful.

You can store your package on your git repository and access them.

If the package is located at the root of the repo, use the following syntax:

dependencies:
  plugin1:
    git:
      url: git://github.com/test/plugin1.git

https://flutter.dev/docs/development/packages-and-plugins/using-packages

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM