Skip to content

Fix broken typing #4

Description

@guopengliang

The types export seems to be broken. When using the default Expo typescript config expo/tsconfig.base, all methods imported has the any type instead of what was declared in the source codes.

The module import { ... } from 'rn-encryption' resolves to node_modules/rn-encryption/lib/typescript/module/src/index which has the following content:

// File: `node_modules/rn-encryption/lib/typescript/module/src/index.d.ts`

export declare const generateAESKey: any, encryptAES: any, decryptAES: any, encryptRSA: any, decryptRSA: any, generateRSAKeyPair: any, generateHMACKey: any, hmacSHA256: any, hmacSHA512: any, hashSHA256: any, hashSHA512: any, generateRandomString: any, base64Encode: any, base64Decode: any, generateECDSAKeyPair: any, signDataECDSA: any, verifySignatureECDSA: any, encryptAsyncAES: any, decryptAsyncAES: any, encryptAsyncRSA: any, decryptAsyncRSA: any, encryptFile: any, decryptFile: any, getPublicRSAkey: any, getPublicECDSAKey: any;
//# sourceMappingURL=index.d.ts.map

Maybe this is a library bundling issue?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions