Skip to content

Impossible to initialize SDK when using Secure Mode #116

@qidydl

Description

@qidydl

Describe the bug
We are building an application dealing with both financial and health information, so Secure Mode is a pretty strong requirement for us. However, if it is enabled, you cannot initialize the SDK to start with when calling withLDProvider (because the user hasn't logged in yet, we don't have user information or a hash), and you can't defer initialization and identify the user later because there's no LDClient instance returned from useLDClient to call identify on!

To reproduce
Enable Secure Mode, and try to use the React Client SDK.

Expected behavior
useLDClient always returns an LDClient so we can call identify after login has completed and finish initialization.

SDK version
2.25.0, latest as of this report

Language version, developer tools
node.js 16.13.0
React 17.0.2

OS/platform
Windows 10, Chrome

Additional context
This may have sort of been reported already in comments on #67 but the developer there apparently just fixed the problem by turning secure mode off, which is not a viable option for us.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions