Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
forked fromwuba/Fair

doc

Directory actions

More options

Directory actions

More options

Latest commit

 

History

History
 
 

doc

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
homeheroImageactionTextactionLinkfeaturesfooter
true
/logo.png
Get Started →
/guide/
titledetails
Lightweight Runtime
The core runtime contains only 2.6k lines of Dart. No worry about size.
titledetails
Seamless Integration
Coding with pure Dart. Integrate package with few configuration.
titledetails
Expandable Widgets
Custom/3rd Widgets mapping can be easily extended with annotation.
Copyright © 2020 58.com | Powered by The Fair Authors

Use Flutter Fair require few steps.

step1:download fair project source code

It is recommended to downloadfair to the local and dependencies on the relative path.

The download method is as follows:

git clone https://github.com/wuba/fair.git

step2:Add dependency insidepubspec.yaml

Assuming that the fair project and your own project are in the same folder:

# add Fair dependencydependencies:fair:path:../fair/fair# add compiler dependencydev_dependencies:build_runner:^1.4.0fair_compiler:path:../fair/compiler# switch "fair_version" according to the local Flutter SDK versiondependency_overrides:fair_version:path:../fair/flutter_version/flutter_2_0_6

step3:Wrap your app with FairApp Widget

voidmain() {WidgetsFlutterBinding.ensureInitialized();FairApp.runApplication(_getApp(),    plugins: {    },  );}dynamic_getApp()=>FairApp(  modules: {  },  delegate: {  },  child:MaterialApp(    home:FairWidget(            name:'DynamicWidget',            path:'assets/bundle/lib_src_page_dynamic_widget.fair.json',            data: {"fairProps": json.encode({})}),  ),);

step4:Import a dynamic widget as FairWidget

FairWidget(  name:'DynamicWidget',  path:'assets/bundle/lib_src_page_dynamic_widget.fair.json',  data: {"fairProps": json.encode({})}),

[8]ページ先頭

©2009-2025 Movatter.jp