@umituz/react-native-ai-generation-content 1.17.231 โ 1.17.233
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 +236 -261
- package/package.json +1 -1
- package/src/domains/content-moderation/README.md +239 -296
- package/src/domains/creations/README.md +242 -325
- package/src/domains/face-detection/README.md +228 -307
- package/src/domains/prompts/README.md +242 -312
- package/src/features/ai-hug/README.md +381 -219
- package/src/features/ai-kiss/README.md +388 -219
- package/src/features/anime-selfie/README.md +327 -256
- package/src/features/audio-generation/README.md +352 -309
- package/src/features/colorization/README.md +332 -228
- package/src/features/couple-future/README.md +387 -212
- package/src/features/future-prediction/README.md +391 -221
- package/src/features/hd-touch-up/README.md +339 -252
- package/src/features/image-captioning/README.md +359 -299
- package/src/features/image-to-image/README.md +398 -357
- package/src/features/image-to-video/README.md +337 -292
- package/src/features/inpainting/README.md +348 -244
- package/src/features/meme-generator/README.md +350 -269
- package/src/features/photo-restoration/README.md +338 -225
- package/src/features/remove-background/README.md +335 -234
- package/src/features/remove-object/README.md +341 -288
- package/src/features/replace-background/README.md +353 -236
- package/src/features/script-generator/README.md +358 -287
- package/src/features/shared/README.md +254 -223
- package/src/features/sketch-to-image/README.md +331 -234
- package/src/features/style-transfer/README.md +336 -237
- package/src/features/text-to-video/README.md +360 -193
- package/src/features/text-to-voice/README.md +382 -272
- package/src/features/upscaling/README.md +340 -191
- package/src/presentation/components/result/ResultStoryCard.tsx +1 -1
package/README.md
CHANGED
|
@@ -2,345 +2,320 @@
|
|
|
2
2
|
|
|
3
3
|
> Provider-agnostic AI generation orchestration for React Native
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
## ๐ Features
|
|
8
|
-
|
|
9
|
-
- **๐จ Text to Image**: Generate stunning images from text descriptions
|
|
10
|
-
- **๐ฌ Text to Video**: Create videos from text prompts
|
|
11
|
-
- **๐ค Text to Voice**: Convert text to natural-sounding speech
|
|
12
|
-
- **๐ Face Swap**: Swap faces between images with AI
|
|
13
|
-
- **๐ผ๏ธ Style Transfer**: Apply artistic styles to photos
|
|
14
|
-
- **โจ Photo Restoration**: Restore and enhance old photos
|
|
15
|
-
- **๐ Upscaling**: Increase image resolution while maintaining quality
|
|
16
|
-
- **๐ญ AI Hug & Kiss**: Generate creative AI-powered interactions
|
|
17
|
-
- **๐
Background Removal/Replacement**: Remove or replace image backgrounds
|
|
18
|
-
- **๐ช Anime Selfie**: Convert photos to anime style
|
|
19
|
-
- **๐ Image Captioning**: Generate descriptive captions for images
|
|
20
|
-
- **๐ต Audio Generation**: Create audio content with AI
|
|
21
|
-
- **๐ Script Generator**: Generate scripts for videos and podcasts
|
|
22
|
-
- **๐ฎ Future Prediction**: See yourself in future scenarios
|
|
5
|
+
Comprehensive React Native library for AI-powered content generation. Support multiple providers with 25+ AI features including image generation, video creation, text-to-speech, face swap, and more.
|
|
23
6
|
|
|
24
|
-
##
|
|
7
|
+
## ๐ฏ Library Purpose
|
|
25
8
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
9
|
+
Provider-agnostic AI generation orchestration layer. Focus on business logic and user experience while handling multiple AI providers seamlessly. Clean architecture with domain-driven design for maintainable, scalable AI features.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## ๐ Feature Overview
|
|
14
|
+
|
|
15
|
+
### Image Generation
|
|
16
|
+
- **Text to Image**: Generate images from descriptions
|
|
17
|
+
- **Image to Image**: Transform images with prompts
|
|
18
|
+
- **Style Transfer**: Apply artistic styles
|
|
19
|
+
- **Photo Restoration**: Restore old photos
|
|
20
|
+
- **Upscaling**: Increase resolution
|
|
21
|
+
- **HD Touch Up**: Enhance quality
|
|
22
|
+
|
|
23
|
+
### Face & Person Features
|
|
24
|
+
- **Face Swap**: Swap faces between images
|
|
25
|
+
- **AI Hug**: Generate hug images (2 people)
|
|
26
|
+
- **AI Kiss**: Generate kiss images (2 people)
|
|
27
|
+
- **Couple Future**: Future predictions for couples
|
|
28
|
+
- **Future Prediction**: Individual future scenarios
|
|
29
|
+
|
|
30
|
+
### Video & Animation
|
|
31
|
+
- **Text to Video**: Generate videos from text
|
|
32
|
+
- **Image to Video**: Convert images to video
|
|
33
|
+
|
|
34
|
+
### Background & Editing
|
|
35
|
+
- **Remove Background**: Remove image backgrounds
|
|
36
|
+
- **Replace Background**: Replace with new background
|
|
37
|
+
- **Inpainting**: Fill masked areas
|
|
38
|
+
- **Remove Object**: Remove unwanted objects
|
|
39
|
+
- **Colorization**: Add color to B&W photos
|
|
40
|
+
|
|
41
|
+
### Creative & Audio
|
|
42
|
+
- **Meme Generator**: Create memes with text
|
|
43
|
+
- **Sketch to Image**: Convert sketches to images
|
|
44
|
+
- **Anime Selfie**: Anime style conversion
|
|
45
|
+
- **Audio Generation**: Generate audio content
|
|
46
|
+
- **Text to Voice**: Text-to-speech synthesis
|
|
47
|
+
- **Script Generator**: Generate content scripts
|
|
48
|
+
|
|
49
|
+
### Analysis
|
|
50
|
+
- **Image Captioning**: Generate image descriptions
|
|
51
|
+
|
|
52
|
+
---
|
|
29
53
|
|
|
30
|
-
|
|
54
|
+
## ๐ฆ Installation
|
|
31
55
|
|
|
32
56
|
```bash
|
|
33
|
-
|
|
57
|
+
npm install @umituz/react-native-ai-generation-content
|
|
34
58
|
```
|
|
35
59
|
|
|
36
|
-
##
|
|
60
|
+
## ๐ Quick Start
|
|
37
61
|
|
|
38
|
-
###
|
|
62
|
+
### Configuration
|
|
39
63
|
|
|
40
|
-
```
|
|
64
|
+
```typescript
|
|
41
65
|
import { configureAppServices } from '@umituz/react-native-ai-generation-content';
|
|
42
66
|
|
|
43
|
-
// Configure required services
|
|
44
67
|
configureAppServices({
|
|
45
68
|
networkService: {
|
|
46
69
|
baseUrl: 'https://your-api.com',
|
|
47
70
|
apiKey: 'your-api-key',
|
|
48
71
|
},
|
|
49
72
|
creditService: {
|
|
50
|
-
checkCredits: async (userId, cost) =>
|
|
51
|
-
|
|
52
|
-
return true;
|
|
53
|
-
},
|
|
54
|
-
deductCredits: async (userId, cost) => {
|
|
55
|
-
// Deduct credits from user
|
|
56
|
-
},
|
|
73
|
+
checkCredits: async (userId, cost) => true,
|
|
74
|
+
deductCredits: async (userId, cost) => {},
|
|
57
75
|
},
|
|
58
76
|
paywallService: {
|
|
59
|
-
showPaywall: async () =>
|
|
60
|
-
// Show paywall if needed
|
|
61
|
-
return true;
|
|
62
|
-
},
|
|
77
|
+
showPaywall: async () => true,
|
|
63
78
|
},
|
|
64
79
|
});
|
|
65
80
|
```
|
|
66
81
|
|
|
67
|
-
###
|
|
82
|
+
### Basic Usage
|
|
68
83
|
|
|
69
|
-
```
|
|
84
|
+
```typescript
|
|
70
85
|
import { useTextToImageFeature } from '@umituz/react-native-ai-generation-content';
|
|
71
86
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
console.log('Image generated:', result.imageUrl);
|
|
78
|
-
},
|
|
87
|
+
const feature = useTextToImageFeature({
|
|
88
|
+
config: {
|
|
89
|
+
model: 'imagen-3',
|
|
90
|
+
onProcessingComplete: (result) => {
|
|
91
|
+
console.log('Generated:', result.imageUrl);
|
|
79
92
|
},
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
<TextInput
|
|
86
|
-
placeholder="Describe the image you want..."
|
|
87
|
-
onChangeText={feature.setPrompt}
|
|
88
|
-
value={feature.state.prompt}
|
|
89
|
-
/>
|
|
90
|
-
|
|
91
|
-
<Button
|
|
92
|
-
title="Generate Image"
|
|
93
|
-
onPress={() => feature.generate()}
|
|
94
|
-
disabled={!feature.isReady}
|
|
95
|
-
/>
|
|
96
|
-
|
|
97
|
-
{feature.state.isProcessing && (
|
|
98
|
-
<Text>Generating... {feature.state.progress}%</Text>
|
|
99
|
-
)}
|
|
100
|
-
|
|
101
|
-
{feature.state.imageUrl && (
|
|
102
|
-
<Image source={{ uri: feature.state.imageUrl }} />
|
|
103
|
-
)}
|
|
104
|
-
</View>
|
|
105
|
-
);
|
|
106
|
-
}
|
|
93
|
+
},
|
|
94
|
+
userId: 'user-123',
|
|
95
|
+
});
|
|
96
|
+
|
|
97
|
+
// Use feature.state, feature.generate(), etc.
|
|
107
98
|
```
|
|
108
99
|
|
|
109
|
-
|
|
100
|
+
---
|
|
101
|
+
|
|
102
|
+
## โ ๏ธ Critical Rules
|
|
110
103
|
|
|
111
|
-
|
|
112
|
-
import { AIFeatureScreen } from '@umituz/react-native-ai-generation-content';
|
|
104
|
+
### MUST FOLLOW
|
|
113
105
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
/>
|
|
120
|
-
);
|
|
121
|
-
}
|
|
122
|
-
```
|
|
106
|
+
1. **Configuration**
|
|
107
|
+
- MUST configure app services before using features
|
|
108
|
+
- MUST provide valid userId for tracking
|
|
109
|
+
- MUST implement credit checking
|
|
110
|
+
- MUST handle errors properly
|
|
123
111
|
|
|
124
|
-
|
|
112
|
+
2. **State Management**
|
|
113
|
+
- MUST check isReady before enabling actions
|
|
114
|
+
- MUST handle isProcessing state
|
|
115
|
+
- MUST display progress to users
|
|
116
|
+
- MUST implement error handling
|
|
125
117
|
|
|
126
|
-
|
|
127
|
-
-
|
|
128
|
-
-
|
|
129
|
-
-
|
|
118
|
+
3. **Performance**
|
|
119
|
+
- MUST implement debouncing (300ms)
|
|
120
|
+
- MUST cache results locally
|
|
121
|
+
- MUST handle large files properly
|
|
122
|
+
- MUST NOT block main thread
|
|
130
123
|
|
|
131
|
-
|
|
132
|
-
-
|
|
133
|
-
-
|
|
134
|
-
-
|
|
135
|
-
-
|
|
136
|
-
- [HD Touch Up](./src/features/hd-touch-up/README.md)
|
|
137
|
-
- [Colorization](./src/features/colorization/README.md)
|
|
138
|
-
- [Image to Image](./src/features/image-to-image/README.md)
|
|
124
|
+
4. **Privacy & Ethics**
|
|
125
|
+
- MUST obtain consent for person-based features
|
|
126
|
+
- MUST implement content moderation
|
|
127
|
+
- MUST comply with regulations
|
|
128
|
+
- MUST provide clear usage terms
|
|
139
129
|
|
|
140
|
-
|
|
141
|
-
- [Remove Background](./src/features/remove-background/README.md)
|
|
142
|
-
- [Replace Background](./src/features/replace-background/README.md)
|
|
143
|
-
- [Remove Object](./src/features/remove-object/README.md)
|
|
144
|
-
- [Inpainting](./src/features/inpainting/README.md)
|
|
130
|
+
---
|
|
145
131
|
|
|
146
|
-
|
|
147
|
-
- [AI Hug](./src/features/ai-hug/README.md)
|
|
148
|
-
- [AI Kiss](./src/features/ai-kiss/README.md)
|
|
149
|
-
- [Anime Selfie](./src/features/anime-selfie/README.md)
|
|
150
|
-
- [Meme Generator](./src/features/meme-generator/README.md)
|
|
151
|
-
- [Couple Future](./src/features/couple-future/README.md)
|
|
152
|
-
- [Future Prediction](./src/features/future-prediction/README.md)
|
|
153
|
-
- [Sketch to Image](./src/features/sketch-to-image/README.md)
|
|
132
|
+
## ๐ซ Prohibitions
|
|
154
133
|
|
|
155
|
-
###
|
|
156
|
-
- [Image to Video](./src/features/image-to-video/README.md)
|
|
157
|
-
- [Audio Generation](./src/features/audio-generation/README.md)
|
|
134
|
+
### MUST AVOID
|
|
158
135
|
|
|
159
|
-
|
|
160
|
-
-
|
|
161
|
-
-
|
|
136
|
+
โ **NEVER**:
|
|
137
|
+
- Skip configuration
|
|
138
|
+
- Use without userId
|
|
139
|
+
- Ignore error handling
|
|
140
|
+
- Process without user action
|
|
141
|
+
- Violate privacy/consent
|
|
142
|
+
- Block main thread
|
|
143
|
+
- Hardcode API keys
|
|
162
144
|
|
|
163
|
-
|
|
145
|
+
---
|
|
164
146
|
|
|
165
|
-
|
|
147
|
+
## ๐ค AI Agent Directions
|
|
166
148
|
|
|
167
|
-
|
|
149
|
+
When implementing with AI code generation:
|
|
168
150
|
|
|
169
151
|
```
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
152
|
+
REQUIREMENTS:
|
|
153
|
+
1. Import from @umituz/react-native-ai-generation-content
|
|
154
|
+
2. Configure app services first
|
|
155
|
+
3. Use feature-specific hooks
|
|
156
|
+
4. Implement proper state management
|
|
157
|
+
5. Handle errors gracefully
|
|
158
|
+
6. Show progress to users
|
|
159
|
+
7. Implement cleanup on unmount
|
|
160
|
+
|
|
161
|
+
CRITICAL RULES:
|
|
162
|
+
- MUST configure before using features
|
|
163
|
+
- MUST provide valid userId
|
|
164
|
+
- MUST check isReady before actions
|
|
165
|
+
- MUST handle isProcessing state
|
|
166
|
+
- MUST implement error handling
|
|
167
|
+
- MUST respect user privacy
|
|
168
|
+
|
|
169
|
+
FEATURE HOOKS:
|
|
170
|
+
- useTextToImageFeature: Image generation
|
|
171
|
+
- useFaceSwapFeature: Face swapping
|
|
172
|
+
- useTextToVoiceFeature: Text-to-speech
|
|
173
|
+
- useAIHugFeature: AI hug generation
|
|
174
|
+
- And 21+ more features
|
|
175
|
+
|
|
176
|
+
STRICTLY FORBIDDEN:
|
|
177
|
+
- No skipping configuration
|
|
178
|
+
- No missing userId
|
|
179
|
+
- No ignoring errors
|
|
180
|
+
- No auto-processing
|
|
181
|
+
- No privacy violations
|
|
182
|
+
- No blocked UI
|
|
183
|
+
- No hardcoded credentials
|
|
180
184
|
```
|
|
181
185
|
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
- **Prompts Domain**: AI prompt management and generation
|
|
185
|
-
- **Content Moderation**: Content safety and filtering
|
|
186
|
-
- **Creations**: Gallery for managing AI-generated content
|
|
187
|
-
- **Face Detection**: Face detection and analysis
|
|
188
|
-
|
|
189
|
-
## ๐จ UI Components
|
|
186
|
+
---
|
|
190
187
|
|
|
191
|
-
|
|
188
|
+
## ๐ Documentation Structure
|
|
192
189
|
|
|
193
|
-
```
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
190
|
+
```
|
|
191
|
+
@umituz/react-native-ai-generation-content/
|
|
192
|
+
โโโ src/
|
|
193
|
+
โ โโโ features/ # 25 AI features (each with README)
|
|
194
|
+
โ โ โโโ text-to-image/
|
|
195
|
+
โ โ โโโ face-swap/
|
|
196
|
+
โ โ โโโ ai-hug/
|
|
197
|
+
โ โ โโโ ...
|
|
198
|
+
โ โโโ domains/ # Shared domains
|
|
199
|
+
โ โ โโโ content-moderation/
|
|
200
|
+
โ โ โโโ prompts/
|
|
201
|
+
โ โ โโโ creations/
|
|
202
|
+
โ โ โโโ face-detection/
|
|
203
|
+
โ โโโ features/shared/ # Shared functionality
|
|
204
|
+
โโโ docs/ # Additional documentation
|
|
205
|
+
โโโ ARCHITECTURE.md # Architecture details
|
|
206
|
+
โโโ FAQ.md # Common questions
|
|
207
|
+
โโโ MIGRATION_GUIDE.md # Migration guide
|
|
203
208
|
```
|
|
204
209
|
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
### Provider Configuration
|
|
210
|
+
### Feature Documentation
|
|
208
211
|
|
|
209
|
-
|
|
210
|
-
|
|
212
|
+
Each feature has comprehensive documentation:
|
|
213
|
+
- **Import paths** (only code in README)
|
|
214
|
+
- **Usage strategy** (when to use/not use)
|
|
215
|
+
- **Critical rules** (MUST follow)
|
|
216
|
+
- **Prohibitions** (MUST avoid)
|
|
217
|
+
- **AI agent directions** (prompt templates)
|
|
218
|
+
- **Configuration strategy**
|
|
219
|
+
- **State management**
|
|
220
|
+
- **Best practices**
|
|
221
|
+
- **Common pitfalls**
|
|
211
222
|
|
|
212
|
-
|
|
213
|
-
providerRegistry.registerProvider({
|
|
214
|
-
id: 'my-provider',
|
|
215
|
-
name: 'My AI Provider',
|
|
216
|
-
capabilities: {
|
|
217
|
-
textToImage: true,
|
|
218
|
-
textToVideo: false,
|
|
219
|
-
// ...
|
|
220
|
-
},
|
|
221
|
-
execute: async (request) => {
|
|
222
|
-
// Provider-specific implementation
|
|
223
|
-
},
|
|
224
|
-
});
|
|
225
|
-
```
|
|
223
|
+
**Example**: See `src/features/text-to-image/README.md`
|
|
226
224
|
|
|
227
|
-
|
|
225
|
+
---
|
|
228
226
|
|
|
229
|
-
|
|
230
|
-
import {
|
|
231
|
-
createCreditCheckMiddleware,
|
|
232
|
-
createHistoryTrackingMiddleware,
|
|
233
|
-
} from '@umituz/react-native-ai-generation-content';
|
|
227
|
+
## ๐จ Architecture
|
|
234
228
|
|
|
235
|
-
|
|
236
|
-
const creditMiddleware = createCreditCheckMiddleware({
|
|
237
|
-
creditCost: 1,
|
|
238
|
-
paywallThreshold: 5,
|
|
239
|
-
});
|
|
229
|
+
### Clean Architecture
|
|
240
230
|
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
231
|
+
```
|
|
232
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
233
|
+
โ Presentation Layer โ
|
|
234
|
+
โ (Components, Hooks) โ
|
|
235
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
236
|
+
โ
|
|
237
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
238
|
+
โ Domain Layer โ
|
|
239
|
+
โ (Types, Interfaces) โ
|
|
240
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
241
|
+
โ
|
|
242
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
243
|
+
โ Infrastructure Layer โ
|
|
244
|
+
โ (Services, Repositories) โ
|
|
245
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
245
246
|
```
|
|
246
247
|
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
### Face Swap
|
|
250
|
-
|
|
251
|
-
```tsx
|
|
252
|
-
import { useFaceSwapFeature } from '@umituz/react-native-ai-generation-content';
|
|
248
|
+
### Key Principles
|
|
253
249
|
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
onSelectSourceImage: async () => { /* ... */ },
|
|
260
|
-
onSelectTargetImage: async () => { /* ... */ },
|
|
261
|
-
onSaveImage: async (url) => { /* ... */ },
|
|
262
|
-
});
|
|
250
|
+
- **Separation of Concerns**: Each layer has specific responsibility
|
|
251
|
+
- **Dependency Inversion**: Depend on abstractions, not implementations
|
|
252
|
+
- **Provider Agnostic**: Support multiple AI providers
|
|
253
|
+
- **Type Safety**: Comprehensive TypeScript types
|
|
254
|
+
- **Testability**: Clean, testable code
|
|
263
255
|
|
|
264
|
-
|
|
265
|
-
```
|
|
256
|
+
---
|
|
266
257
|
|
|
267
|
-
|
|
258
|
+
## ๐ Security & Privacy
|
|
268
259
|
|
|
269
|
-
|
|
270
|
-
|
|
260
|
+
### API Keys
|
|
261
|
+
- Never store in code
|
|
262
|
+
- Use environment variables
|
|
263
|
+
- Implement rotation
|
|
271
264
|
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
onSelectPhoto: async () => { /* ... */ },
|
|
277
|
-
onSaveResult: async (url) => { /* ... */ },
|
|
278
|
-
});
|
|
265
|
+
### Content Moderation
|
|
266
|
+
- Enable for user-generated content
|
|
267
|
+
- Configure rules appropriately
|
|
268
|
+
- Monitor for violations
|
|
279
269
|
|
|
280
|
-
|
|
281
|
-
|
|
270
|
+
### User Data
|
|
271
|
+
- Anonymize analytics
|
|
272
|
+
- Secure storage
|
|
273
|
+
- GDPR/CCPA compliance
|
|
282
274
|
|
|
283
|
-
|
|
275
|
+
---
|
|
284
276
|
|
|
285
|
-
|
|
286
|
-
import { useTextToVideoFeature } from '@umituz/react-native-ai-generation-content';
|
|
277
|
+
## ๐ Performance
|
|
287
278
|
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
});
|
|
279
|
+
### Optimization
|
|
280
|
+
- Lazy load features
|
|
281
|
+
- Cache results
|
|
282
|
+
- Optimize images
|
|
283
|
+
- Background processing
|
|
294
284
|
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
285
|
+
### Best Practices
|
|
286
|
+
- Implement debouncing
|
|
287
|
+
- Use pagination
|
|
288
|
+
- Compress uploads
|
|
289
|
+
- Monitor performance
|
|
300
290
|
|
|
301
|
-
|
|
291
|
+
---
|
|
302
292
|
|
|
303
|
-
|
|
304
|
-
import { renderHook, waitFor } from '@testing-library/react-native';
|
|
305
|
-
import { useTextToImageFeature } from '@umituz/react-native-ai-generation-content';
|
|
293
|
+
## ๐ค Contributing
|
|
306
294
|
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
})
|
|
313
|
-
);
|
|
314
|
-
|
|
315
|
-
await act(async () => {
|
|
316
|
-
await result.current.generate({ prompt: 'Test prompt' });
|
|
317
|
-
});
|
|
318
|
-
|
|
319
|
-
await waitFor(() => {
|
|
320
|
-
expect(result.current.state.imageUrl).toBeTruthy();
|
|
321
|
-
});
|
|
322
|
-
});
|
|
323
|
-
```
|
|
295
|
+
Contributions welcome! Please:
|
|
296
|
+
- Follow code style
|
|
297
|
+
- Add tests
|
|
298
|
+
- Update docs
|
|
299
|
+
- Submit PR
|
|
324
300
|
|
|
325
|
-
|
|
301
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md)
|
|
326
302
|
|
|
327
|
-
|
|
303
|
+
---
|
|
328
304
|
|
|
329
305
|
## ๐ License
|
|
330
306
|
|
|
331
|
-
MIT
|
|
307
|
+
MIT
|
|
332
308
|
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
- [Documentation](./docs)
|
|
336
|
-
- [Examples](./examples)
|
|
337
|
-
- [Changelog](./CHANGELOG.md)
|
|
338
|
-
- [Report Issues](https://github.com/umituz/react-native-ai-generation-content/issues)
|
|
309
|
+
---
|
|
339
310
|
|
|
340
|
-
##
|
|
311
|
+
## ๐ Support
|
|
341
312
|
|
|
342
|
-
|
|
313
|
+
- **Issues**: GitHub Issues
|
|
314
|
+
- **Docs**: `/docs` folder
|
|
315
|
+
- **FAQ**: [FAQ.md](FAQ.md)
|
|
316
|
+
- **Migration**: [MIGRATION_GUIDE.md](MIGRATION_GUIDE.md)
|
|
343
317
|
|
|
344
318
|
---
|
|
345
319
|
|
|
346
|
-
|
|
320
|
+
**Version**: 2.0.0 (Strategy-based Documentation)
|
|
321
|
+
**Last Updated**: 2025-01-08
|
package/package.json
CHANGED