Scala.js facades for core react-native utilities and components.
It uses excellent scalajs-reactjs binding/facade library.
val scommonsReactNativeVer = "1.0.0-SNAPSHOT"
libraryDependencies ++= Seq(
"org.scommons.react-native" %%% "scommons-react-native-core" % scommonsReactNativeVer,
"org.scommons.react-native" %%% "scommons-react-native-community" % scommonsReactNativeVer,
"org.scommons.react-native" %%% "scommons-react-navigation" % scommonsReactNativeVer,
"org.scommons.react-native" %%% "scommons-expo" % scommonsReactNativeVer,
// ui module already includes all above modules
"org.scommons.react-native" %%% "scommons-react-native-ui" % scommonsReactNativeVer,
// mocks of native Components and APIs
"org.scommons.react-native" %%% "scommons-react-native-test" % scommonsReactNativeVer % "test"
)
Latest SNAPSHOT
version is published to Sonatype Repo, just make sure you added
the proper dependency resolver to your build.sbt
settings:
resolvers += "Sonatype Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots/"
See showcase/README.md for how to build and run it.
- app => tests
- controller => tests
- screen => tests
- state => tests
- TaskController => tests
- Screens with API calls
- Reusable Custom UI Components
- ChoiceGroup => tests
Note: Many examples are from an excellent book React Native in Action by Nader Dabit
- Border Style => tests
- Border Radius => tests
- Margin => tests
- Padding => tests
- Position => tests
- TextStyle => tests
- ProfileCard (with Images) => tests
-
- ActivityIndicator => tests
- Button => tests
- FlatList => tests
- Image => tests
- KeyboardAvoidingView => tests
- Modal => tests
- ScrollView => tests
- StatusBar => tests
- Switch => tests
- TextInput => tests
- TouchableHighlight => tests
- TouchableOpacity => tests
-
APIs:
- @react-native-picker/picker
- react-native-safe-area-context
- react-native-svg
- react-native-webview => tests
- react-native-htmlview => tests
- react-native-syntax-highlighter => tests
- expo-asset => tests
- expo-font => tests
- @expo/vector-icons => tests
- expo-av
- expo-sqlite
- SQLite => tests
- See scommons-websql for how to:
- use high-level
scommons-websql-io
module with expo SQLite - use
scommons-websql-migrations
to automate your DB schema versioning
- use high-level
To build and run all the tests use the following command:
sbt test
You can find more documentation here
You can find more examples here