Skip to content

Commit bacd13a

Browse files
committed
feat: react-native-date - High-performance native date library
0 parents  commit bacd13a

142 files changed

Lines changed: 39700 additions & 0 deletions

File tree

Some content is hidden

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

.github/workflows/ci.yml

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
lint-and-test:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
15+
- name: Setup Node.js
16+
uses: actions/setup-node@v4
17+
with:
18+
node-version: '20'
19+
cache: 'yarn'
20+
21+
- name: Install dependencies
22+
run: yarn install --frozen-lockfile
23+
24+
- name: Lint
25+
run: yarn workspace @rn-packages/native-date lint
26+
27+
- name: Type check
28+
run: yarn workspace @rn-packages/native-date typecheck
29+
30+
- name: Run tests
31+
run: yarn workspace @rn-packages/native-date test
32+
33+
- name: Build
34+
run: yarn workspace @rn-packages/native-date prepare
35+
36+
build-android:
37+
runs-on: ubuntu-latest
38+
needs: lint-and-test
39+
steps:
40+
- uses: actions/checkout@v4
41+
42+
- name: Setup Node.js
43+
uses: actions/setup-node@v4
44+
with:
45+
node-version: '20'
46+
cache: 'yarn'
47+
48+
- name: Setup Java
49+
uses: actions/setup-java@v4
50+
with:
51+
distribution: 'zulu'
52+
java-version: '17'
53+
54+
- name: Install dependencies
55+
run: yarn install --frozen-lockfile
56+
57+
- name: Build library
58+
run: yarn workspace @rn-packages/native-date prepare
59+
60+
- name: Cache Gradle
61+
uses: actions/cache@v4
62+
with:
63+
path: |
64+
~/.gradle/caches
65+
~/.gradle/wrapper
66+
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
67+
restore-keys: |
68+
${{ runner.os }}-gradle-
69+
70+
- name: Build Android example
71+
working-directory: packages/native-date/example/android
72+
run: ./gradlew assembleDebug --no-daemon
73+
74+
build-ios:
75+
runs-on: macos-latest
76+
needs: lint-and-test
77+
steps:
78+
- uses: actions/checkout@v4
79+
80+
- name: Setup Node.js
81+
uses: actions/setup-node@v4
82+
with:
83+
node-version: '20'
84+
cache: 'yarn'
85+
86+
- name: Install dependencies
87+
run: yarn install --frozen-lockfile
88+
89+
- name: Build library
90+
run: yarn workspace @rn-packages/native-date prepare
91+
92+
- name: Cache CocoaPods
93+
uses: actions/cache@v4
94+
with:
95+
path: packages/native-date/example/ios/Pods
96+
key: ${{ runner.os }}-pods-${{ hashFiles('**/Podfile.lock') }}
97+
restore-keys: |
98+
${{ runner.os }}-pods-
99+
100+
- name: Install CocoaPods
101+
working-directory: packages/native-date/example/ios
102+
run: pod install
103+
104+
- name: Build iOS example
105+
working-directory: packages/native-date/example/ios
106+
run: |
107+
xcodebuild \
108+
-workspace NativeDateExample.xcworkspace \
109+
-scheme NativeDateExample \
110+
-sdk iphonesimulator \
111+
-configuration Debug \
112+
-destination 'platform=iOS Simulator,name=iPhone 15' \
113+
build \
114+
CODE_SIGNING_ALLOWED=NO

.github/workflows/docs.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Deploy Docs
2+
3+
on:
4+
push:
5+
branches: [main]
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
13+
concurrency:
14+
group: pages
15+
cancel-in-progress: false
16+
17+
jobs:
18+
build:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Checkout
22+
uses: actions/checkout@v4
23+
with:
24+
fetch-depth: 0
25+
26+
- name: Setup Node
27+
uses: actions/setup-node@v4
28+
with:
29+
node-version: 20
30+
cache: yarn
31+
32+
- name: Setup Pages
33+
uses: actions/configure-pages@v4
34+
35+
- name: Install dependencies
36+
run: yarn install --frozen-lockfile
37+
38+
- name: Build docs
39+
run: yarn docs:build
40+
41+
- name: Upload artifact
42+
uses: actions/upload-pages-artifact@v3
43+
with:
44+
path: docs/.vitepress/dist
45+
46+
deploy:
47+
environment:
48+
name: github-pages
49+
url: ${{ steps.deployment.outputs.page_url }}
50+
needs: build
51+
runs-on: ubuntu-latest
52+
steps:
53+
- name: Deploy to GitHub Pages
54+
id: deployment
55+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
# Dependencies
2+
node_modules/
3+
.yarn/*
4+
!.yarn/patches
5+
!.yarn/plugins
6+
!.yarn/releases
7+
!.yarn/sdks
8+
!.yarn/versions
9+
10+
# Build outputs
11+
lib/
12+
dist/
13+
build/
14+
*.tsbuildinfo
15+
16+
# iOS
17+
ios/Pods/
18+
ios/build/
19+
ios/*.xcworkspace
20+
ios/*.xcodeproj/xcuserdata/
21+
ios/*.xcodeproj/project.xcworkspace/xcshareddata/
22+
ios/DerivedData/
23+
*.pbxuser
24+
*.mode1v3
25+
*.mode2v3
26+
*.perspectivev3
27+
*.hmap
28+
*.ipa
29+
*.xcuserstate
30+
*.moved-aside
31+
**/.xcode.env.local
32+
33+
# Android
34+
android/.gradle/
35+
android/build/
36+
android/app/build/
37+
android/local.properties
38+
android/*.iml
39+
android/.idea/
40+
*.keystore
41+
!debug.keystore
42+
.cxx/
43+
44+
# React Native
45+
*.bundle
46+
.metro-health-check*
47+
48+
# Gradle
49+
.gradle/
50+
51+
# Logs
52+
*.log
53+
npm-debug.log*
54+
yarn-debug.log*
55+
yarn-error.log*
56+
lerna-debug.log*
57+
58+
# Runtime data
59+
pids/
60+
*.pid
61+
*.seed
62+
*.pid.lock
63+
64+
# Coverage
65+
coverage/
66+
.nyc_output/
67+
68+
# IDEs and editors
69+
.idea/
70+
.vscode/*
71+
!.vscode/extensions.json
72+
!.vscode/settings.json
73+
*.swp
74+
*.swo
75+
*~
76+
.project
77+
.classpath
78+
.settings/
79+
*.sublime-workspace
80+
*.sublime-project
81+
82+
# OS files
83+
.DS_Store
84+
.DS_Store?
85+
._*
86+
.Spotlight-V100
87+
.Trashes
88+
ehthumbs.db
89+
Thumbs.db
90+
91+
# Environment
92+
.env
93+
.env.local
94+
.env.*.local
95+
*.local
96+
97+
# Turbo
98+
.turbo/
99+
100+
# Testing
101+
__snapshots__/
102+
103+
# Docs build
104+
docs/.vitepress/dist/
105+
docs/.vitepress/cache/
106+
107+
# Temporary files
108+
tmp/
109+
temp/
110+
*.tmp
111+
*.temp
112+
113+
# Pack files
114+
*.tgz
115+
116+
# Benchmark results (optional - uncomment to track)
117+
# benchmark-results/
118+
119+
# Lefthook
120+
.lefthook-local/
121+
122+
# Nitro generated (keep in git but ignore local changes)
123+
# nitrogen/generated/
124+
125+
# Example app specific
126+
packages/native-date/example/ios/Pods/
127+
packages/native-date/example/ios/build/
128+
packages/native-date/example/android/.gradle/
129+
packages/native-date/example/android/build/
130+
packages/native-date/example/android/app/build/
131+
132+
133+
.vscode/

.yarn/install-state.gz

1.23 MB
Binary file not shown.

0 commit comments

Comments
 (0)