@thelacanians/vue-native-runtime 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +108 -0
- package/dist/index.cjs +1686 -59
- package/dist/index.d.cts +1942 -131
- package/dist/index.d.ts +1942 -131
- package/dist/index.js +1644 -49
- package/package.json +2 -2
package/README.md
ADDED
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# @thelacanians/vue-native-runtime
|
|
2
|
+
|
|
3
|
+
Vue 3 custom renderer for building native iOS and Android apps.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @thelacanians/vue-native-runtime
|
|
9
|
+
# or
|
|
10
|
+
bun add @thelacanians/vue-native-runtime
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Usage
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
import { createApp } from 'vue'
|
|
17
|
+
import App from './App.vue'
|
|
18
|
+
|
|
19
|
+
const app = createApp(App)
|
|
20
|
+
app.start()
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
> **Note:** The Vite plugin aliases `'vue'` to this package automatically, so you import from `'vue'` in your app code.
|
|
24
|
+
|
|
25
|
+
## What's included
|
|
26
|
+
|
|
27
|
+
### Components
|
|
28
|
+
|
|
29
|
+
| Component | Description |
|
|
30
|
+
|-----------|-------------|
|
|
31
|
+
| `VView` | Flexbox container (like `<div>`) |
|
|
32
|
+
| `VText` | Text display |
|
|
33
|
+
| `VButton` | Pressable button |
|
|
34
|
+
| `VInput` | Text input field |
|
|
35
|
+
| `VSwitch` | Toggle switch |
|
|
36
|
+
| `VSlider` | Numeric slider |
|
|
37
|
+
| `VScrollView` | Scrollable container with pull-to-refresh |
|
|
38
|
+
| `VList` | Virtualized list (UITableView / RecyclerView) |
|
|
39
|
+
| `VImage` | Image display (local + remote) |
|
|
40
|
+
| `VSafeArea` | Safe area insets container |
|
|
41
|
+
| `VKeyboardAvoiding` | Keyboard-aware container |
|
|
42
|
+
| `VModal` | Modal overlay |
|
|
43
|
+
| `VAlertDialog` | Native alert dialog |
|
|
44
|
+
| `VActionSheet` | Action sheet |
|
|
45
|
+
| `VStatusBar` | Status bar configuration |
|
|
46
|
+
| `VWebView` | Embedded web view |
|
|
47
|
+
| `VProgressBar` | Progress indicator |
|
|
48
|
+
| `VPicker` | Value picker |
|
|
49
|
+
| `VSegmentedControl` | Segmented control |
|
|
50
|
+
| `VActivityIndicator` | Loading spinner |
|
|
51
|
+
|
|
52
|
+
### Composables
|
|
53
|
+
|
|
54
|
+
| Composable | Description |
|
|
55
|
+
|------------|-------------|
|
|
56
|
+
| `useAnimation` | Timing and spring animations |
|
|
57
|
+
| `useAsyncStorage` | Persistent key-value storage |
|
|
58
|
+
| `useBackHandler` | Hardware back button (Android) |
|
|
59
|
+
| `useBiometry` | Face ID / Touch ID / Fingerprint |
|
|
60
|
+
| `useCamera` | Camera access |
|
|
61
|
+
| `useClipboard` | System clipboard |
|
|
62
|
+
| `useColorScheme` | Light/dark mode |
|
|
63
|
+
| `useDeviceInfo` | Device model, OS, screen size |
|
|
64
|
+
| `useGeolocation` | GPS location |
|
|
65
|
+
| `useHaptics` | Haptic feedback |
|
|
66
|
+
| `useHttp` | HTTP client (fetch wrapper) |
|
|
67
|
+
| `useKeyboard` | Keyboard visibility and height |
|
|
68
|
+
| `useLinking` | Deep links and URL opening |
|
|
69
|
+
| `useNetwork` | Network connectivity status |
|
|
70
|
+
| `useNotifications` | Local notifications |
|
|
71
|
+
| `usePermissions` | Runtime permissions |
|
|
72
|
+
| `useShare` | Native share sheet |
|
|
73
|
+
| `useAppState` | App foreground/background state |
|
|
74
|
+
|
|
75
|
+
### Utilities
|
|
76
|
+
|
|
77
|
+
- `createStyleSheet()` - Type-safe style definitions with dev-mode validation
|
|
78
|
+
- `vShow` - Directive for toggling visibility
|
|
79
|
+
- `NativeBridge` - Low-level native interop
|
|
80
|
+
|
|
81
|
+
## Styling
|
|
82
|
+
|
|
83
|
+
```ts
|
|
84
|
+
import { createStyleSheet } from 'vue'
|
|
85
|
+
|
|
86
|
+
const styles = createStyleSheet({
|
|
87
|
+
container: {
|
|
88
|
+
flex: 1,
|
|
89
|
+
justifyContent: 'center',
|
|
90
|
+
alignItems: 'center',
|
|
91
|
+
backgroundColor: '#ffffff',
|
|
92
|
+
},
|
|
93
|
+
title: {
|
|
94
|
+
fontSize: 24,
|
|
95
|
+
fontWeight: 'bold',
|
|
96
|
+
color: '#1a1a1a',
|
|
97
|
+
},
|
|
98
|
+
})
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Platforms
|
|
102
|
+
|
|
103
|
+
- **iOS 16+** — JavaScriptCore + UIKit via [VueNativeCore](https://github.com/abdul-hamid-achik/vue-native/tree/main/native/ios) Swift package
|
|
104
|
+
- **Android 5.0+** — V8 (J2V8) + Android Views via [VueNativeCore](https://github.com/abdul-hamid-achik/vue-native/tree/main/native/android) Kotlin library
|
|
105
|
+
|
|
106
|
+
## License
|
|
107
|
+
|
|
108
|
+
MIT
|