File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed
Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 11import { NativeModules } from 'react-native' ;
22import { type ImageObjectNative } from './NativePdfFromImage' ;
33import { paperSizes } from './contants' ;
4- import type { ImageObjectJs } from './types' ;
4+ import type { File , ImageObjectJs } from './types' ;
55
66// @ts -ignore We want to check whether __turboModuleProxy exitst, it may not
77const isTurboModuleEnabled = global . __turboModuleProxy != null ;
@@ -10,7 +10,7 @@ const pdffromimage = isTurboModuleEnabled
1010 ? require ( './NativePdfFromImage' ) . default
1111 : NativeModules . PdfFromImage ;
1212
13- export function createPdf ( params : ImageObjectJs ) {
13+ export function createPdf ( params : ImageObjectJs ) : File {
1414 // Sanitize document name by removing file extension
1515 const sanitizedName = params . name . replace ( / \. [ ^ / . ] + $ / , '' ) ;
1616
Original file line number Diff line number Diff line change @@ -41,3 +41,7 @@ export type ImageObjectJs = {
4141 | 'Executive'
4242 | 'Folio' ;
4343} ;
44+
45+ export type File = {
46+ filePath : string ;
47+ } ;
You can’t perform that action at this time.
0 commit comments