
Research
NPM targeted by malware campaign mimicking familiar library names
Socket uncovered npm malware campaign mimicking popular Node.js libraries and packages from other ecosystems; packages steal data and execute remote code.
@dapperlabs/react-launch-darkly
Advanced tools
Convenience component for creating a Launch Darkly feature flags context.
Convenience component for creating a Launch Darkly feature flags context.
isReady
: boolean indicating connection to LD service has been established.clientSideId
: your launch darkly client idinitialFlags
: the set of flags to use on mount. Example: if you use SSR, you should fetch your initial flags from the API and set them here so that initial render has the correct values. These will get overwritten as necessary from the connection to LD when ready.user
: (optional) user object to define the user for fetching flags from launch darkly. If none is provided, will default to an anonymous user. See Launch Darkly documentation on user objectsImport the provider and wrap your application in it.
import { FeatureFlagsProvider } from '@dapperlabs/react-launch-darkly';
function Root() {
return (
<FeatureFlagsProvider
clientSideId={process.env.LAUNCH_DARKLY_CLIENT_SIDE_ID}
initialFlags={{ foo: 'bar' }}
user={{
key: user.id,
email: user.email,
}}
>
<MyDApp />
</FeatureFlagsProvider>
)
}
Context is directly available via import { FeatureFlagsContext } from '@dapperlabs/react-launch-darkly'
and can be consumed however you'd like:
useContext(FeatureFlagsContext)
👈IDEAL 😎static contextType = FeatureFlagsContext
<FeatureFlagsContext.Consumer />
Decorates your component with the above context values as a prop called featureFlags
.
FAQs
Convenience component for creating a Launch Darkly feature flags context.
The npm package @dapperlabs/react-launch-darkly receives a total of 6 weekly downloads. As such, @dapperlabs/react-launch-darkly popularity was classified as not popular.
We found that @dapperlabs/react-launch-darkly demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovered npm malware campaign mimicking popular Node.js libraries and packages from other ecosystems; packages steal data and execute remote code.
Research
Socket's research uncovers three dangerous Go modules that contain obfuscated disk-wiping malware, threatening complete data loss.
Research
Socket uncovers malicious packages on PyPI using Gmail's SMTP protocol for command and control (C2) to exfiltrate data and execute commands.