Skip to content

Conversation

@arkaitzgarro
Copy link

There is a typo in the example to bootstrap LaunchDarkly client, which prevents the application to work properly if you copy and paste the code directly.

@eli-darkly
Copy link
Contributor

Thanks for spotting this!

@eli-darkly
Copy link
Contributor

eli-darkly commented Jun 6, 2018

Actually, wait a moment. What's your basis for saying the "localStorage" parameter would make things not work? It looks to me like the client is using a case-insensitive comparison by uppercasing the whole string first:

options.bootstrap.toUpperCase() === 'LOCALSTORAGE'

That should work correctly regardless of whether the string is "localStorage" or "localstorage".

@arkaitzgarro
Copy link
Author

We are facing some issues bootstrapping the application, and that was the answer from support:

Knowing that the array of flags was empty, I took another look at your settings object. I noticed that you have localstorage specified in camel case as ‘localStorage’ in your settings object. This is case sensitive, so this would explain why your client was being initialized empty. I believe that changing your settings object should resolve the issue you were having with the previous setup.

That’s the reason of this PR. We will keep investigating then.

eli-darkly pushed a commit that referenced this pull request Aug 25, 2018
…hed NPM package (#94)

TIL that `npm pack` will build the tarball that actually gets uploaded to the NPM servers.

If you want to verify this works,

```sh
  npm run clean
  npm run prepublishOnly # simulate build that occurs before publishing
  npm pack # generate the tarball that will end up on NPM servers
```

Since we don't include anything from `src/`, I moved the TypeScript typings to the package root to avoid having to copy things around.
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.

2 participants