Skip to content

Commit ea78eb7

Browse files
authored
chore: upgrade project structure (#4)
1 parent 374766a commit ea78eb7

File tree

376 files changed

+4951
-23935
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

376 files changed

+4951
-23935
lines changed

example/react-native/.eslintrc.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
module.exports = {
2+
root: true,
3+
extends: '@react-native',
4+
};

example/react-native/.gitignore

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
# OSX
2+
#
3+
.DS_Store
4+
5+
# Xcode
6+
#
7+
build/
8+
*.pbxuser
9+
!default.pbxuser
10+
*.mode1v3
11+
!default.mode1v3
12+
*.mode2v3
13+
!default.mode2v3
14+
*.perspectivev3
15+
!default.perspectivev3
16+
xcuserdata
17+
*.xccheckout
18+
*.moved-aside
19+
DerivedData
20+
*.hmap
21+
*.ipa
22+
*.xcuserstate
23+
**/.xcode.env.local
24+
25+
# Android/IntelliJ
26+
#
27+
build/
28+
.idea
29+
.gradle
30+
local.properties
31+
*.iml
32+
*.hprof
33+
.cxx/
34+
*.keystore
35+
!debug.keystore
36+
.kotlin/
37+
38+
# node.js
39+
#
40+
node_modules/
41+
npm-debug.log
42+
yarn-error.log
43+
44+
# fastlane
45+
#
46+
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
47+
# screenshots whenever they are needed.
48+
# For more information about the recommended setup visit:
49+
# https://docs.fastlane.tools/best-practices/source-control/
50+
51+
**/fastlane/report.xml
52+
**/fastlane/Preview.html
53+
**/fastlane/screenshots
54+
**/fastlane/test_output
55+
56+
# Bundle artifact
57+
*.jsbundle
58+
59+
# Ruby / CocoaPods
60+
**/Pods/
61+
/vendor/bundle/
62+
63+
# Temporary files created by Metro to check the health of the file watcher
64+
.metro-health-check*
65+
66+
# testing
67+
/coverage
68+
69+
# Yarn
70+
.yarn/*
71+
!.yarn/patches
72+
!.yarn/plugins
73+
!.yarn/releases
74+
!.yarn/sdks
75+
!.yarn/versions
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
module.exports = {
2+
arrowParens: 'avoid',
3+
singleQuote: true,
4+
trailingComma: 'all',
5+
};

native-modules/react-native-background-thread/example/.watchmanconfig renamed to example/react-native/.watchmanconfig

File renamed without changes.

example/react-native/App.tsx

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
/**
2+
* Sample React Native App
3+
* https://github.com/facebook/react-native
4+
*
5+
* @format
6+
*/
7+
8+
import { StatusBar, StyleSheet, useColorScheme, View } from 'react-native';
9+
import {
10+
SafeAreaProvider,
11+
useSafeAreaInsets,
12+
} from 'react-native-safe-area-context';
13+
import { Router } from './route';
14+
15+
function App() {
16+
const isDarkMode = useColorScheme() === 'dark';
17+
18+
return (
19+
<SafeAreaProvider>
20+
<StatusBar barStyle={isDarkMode ? 'light-content' : 'dark-content'} />
21+
<AppContent />
22+
</SafeAreaProvider>
23+
);
24+
}
25+
26+
function AppContent() {
27+
const safeAreaInsets = useSafeAreaInsets();
28+
29+
return (
30+
<View style={styles.container}>
31+
<Router safeAreaInsets={safeAreaInsets} />
32+
</View>
33+
);
34+
}
35+
36+
const styles = StyleSheet.create({
37+
container: {
38+
flex: 1,
39+
},
40+
});
41+
42+
export default App;

native-modules/react-native-background-thread/example/Gemfile renamed to example/react-native/Gemfile

File renamed without changes.

native-modules/react-native-background-thread/example/README.md renamed to example/react-native/README.md

File renamed without changes.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/**
2+
* @format
3+
*/
4+
5+
import React from 'react';
6+
import ReactTestRenderer from 'react-test-renderer';
7+
import App from '../App';
8+
9+
test('renders correctly', async () => {
10+
await ReactTestRenderer.act(() => {
11+
ReactTestRenderer.create(<App />);
12+
});
13+
});

native-modules/react-native-cloud-kit-module/example/android/app/build.gradle renamed to example/react-native/android/app/build.gradle

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ react {
1111
hermesCommand = new File(["node", "--print", "require.resolve('react-native/package.json')"].execute(null, rootDir).text.trim()).getParentFile().getAbsolutePath() + "/sdks/hermesc/%OS-BIN%/hermesc"
1212
codegenDir = new File(["node", "--print", "require.resolve('@react-native/codegen/package.json')"].execute(null, rootDir).text.trim()).getParentFile().getAbsoluteFile()
1313
enableBundleCompression = (findProperty('android.enableBundleCompression') ?: false).toBoolean()
14-
1514
/* Folders */
1615
// The root of your project, i.e. where "package.json" lives. Default is '../..'
1716
// root = file("../../")
@@ -82,9 +81,9 @@ android {
8281
buildToolsVersion rootProject.ext.buildToolsVersion
8382
compileSdk rootProject.ext.compileSdkVersion
8483

85-
namespace "cloudkitmodule.example"
84+
namespace "com.example"
8685
defaultConfig {
87-
applicationId "cloudkitmodule.example"
86+
applicationId "com.example"
8887
minSdkVersion rootProject.ext.minSdkVersion
8988
targetSdkVersion rootProject.ext.targetSdkVersion
9089
versionCode 1

native-modules/react-native-background-thread/example/android/app/debug.keystore renamed to example/react-native/android/app/debug.keystore

File renamed without changes.

0 commit comments

Comments
 (0)