Skip to content

Conversation

@Mahrukhizhar
Copy link

No description provided.

src/index.js Outdated

const isPublicSdkKey = clientSdkKey.split('-')[1] == 'public' ? true : false
if(!isPublicSdkKey){
console.warn("To obtain the API key, please sign in to the Unlaunch Console at https://app.unlaunch.io"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're using NOT using public key to connect to Unlaunch. If your application is client-side, not using public key can compromise security. To obtain the public API key, please sign in ...

}

if(clientSdkKey.split('-')[1] !== 'public'){
console.warn("You're using NOT using public key to connect to Unlaunch. If your application is client-side, not using public key can compromise security. To obtain the public SDK key, please sign in the Unlaunch Console at https://app.unlaunch.io"
Copy link
Contributor

@umermansoor umermansoor Nov 2, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We detected that you're not using the public SDK key to connect to Unlaunch from a browser SDK. For security reasons, we highly recommend using the public SDK key to access Unlaunch from JavaScript or other public SDKs. To obtain the public SDK key, please sign in the Unlaunch Console at https://app.unlaunch.io"
+". Then on the right sidebar, click on 'Settings'. Then from the 'Projects' tab. Copy the 'Browser / Public Key' for the "
+"environment you want to connect to, and provide it to this SDK. For more information, visit: https://docs.unlaunch.io/docs/sdks/sdk-keys"

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants