Skip to content

v6 does not allow for named imports with TypeScript Change #291

@ajcrites

Description

@ajcrites

In v5, you could do things like import { getItem } from 'react-native-sensitive-info' which was doing module.exports.

The change to export default no longer allows you do this, and you have to import SInfo ....

This can be fixed by using export = instead of export default or otherwise changing everything over to named exports. For now, my preference would just be to use export =.

In case the maintainers don't want to make this change, the TypeScript declarations need to be updated to remove the exported functions which are no longer exported.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions