
Security Fundamentals
Turtles, Clams, and Cyber Threat Actors: Shell Usage
The Socket Threat Research Team uncovers how threat actors weaponize shell techniques across npm, PyPI, and Go ecosystems to maintain persistence and exfiltrate data.
@splunk/react-ui
Advanced tools
Library of React components that implement the Splunk design language
A library of UI components that implement the Splunk design language in React.
Install the package and its dependencies.
npm install react@^16 react-dom@^16 styled-components@^5
npm install @splunk/react-ui
@splunk/react-ui
and React support production and development builds. The production build removes warnings and guidance from the output. To create a production build, set the environment variable NODE_ENV
to "production"
and use the webpack DefinePlugin to inject the variable into the code.
Nearly all components accept node
children. Only components that
require specific constraints include information about the children
prop in
its documentation.
Pass style to control layout, margins, or positioning. See the following example:
<Button label="Hello" style={{ flexBasis: '200px' }} />
Alternatively, you can use a component's inline
prop to switch between
inline-block/inline-flex
and block/flex
. You can use this prop instead
of passing a style prop. See the following example:
<Button inline={false} />
Avoid using className
.
Avoid overriding style sheets. When selector specificity changes, the change can break style sheet overrides.
The generated markup isn't an API and may change at any time without notice, even in a patch release. The selector specificity also isn't an API and may change at any time without notice.
All components support an elementRef
prop. It behaves similar to a React ref,
but its value is guaranteed to be the main DOM element of the component, if mounted. In contrast, the value of a regular ref
on a
mounted class component is the component instance.
The component library doesn't include fonts. You must define and load fonts in a @font-face
declaration. By default, the components render in "Splunk Platform Sans", an alias of "Proxima Nova", and "Splunk Platform Mono", an alias of "Inconsolata".
Please make sure to obtain all required font licenses.
For quick reference, most themes use the following font-family stack:
Sans (default): Splunk Platform Sans, Proxima Nova, Roboto, Droid, Helvetica Neue,
Helvetica, Arial, sans-serif;
Mono: Splunk Platform Mono, Inconsolata, Consolas, Droid Sans Mono, Monaco,
Courier New, Courier, monospace;
Individual themes might use different fonts.
It is strongly recommended to include only one instance of @splunk/react-ui
in an application bundle. Likewise,
using multiple instances of this library on the same page is discouraged.
| Multiple instances | @splunk/react-ui 4.x | @splunk/react-ui 4.x and 3.x |
| ------------------ | ----------------------- | ---------------------------- |
| In the same bundle | Deduplicate | Avoid |
| On the same page | Avoid | Avoid |
Multiple instances of @splunk/react-ui
in the same bundle should be avoided.
For example, instead of 4.0.0
and 4.1.0
only 4.1.0
should be used.
Multiple versions of 3.x
are not supported.
Use a package manager (Yarn or NPM) or a module bundler (Webpack) to deduplicate versions.
yarn
and npm
resolve dependencies to avoid duplicate versions.
Pros:
4.x
and 3.x
in the same bundle.Cons:
@splunk/react-ui
dependency with a major version (@^4.0
or @^4.1
),
not a minor version (@~4.0
).Webpack's alias
feature can force a single version of @splunk/react-ui
to be used throughout
the dependency tree.
Pros:
@splunk/react-ui
.Cons:
3.x
and 4.x
are required by different dependencies.While it's generally discouraged to run multiple instances of @splunk/react-ui
on the same page, legacy environments
exist that may have this requirement. A utility that can help with this scenario is LayerStackGlobalProvider
in the
Layer
component.
If React Hooks are used, the react
and react-dom
packages should be deduplicated as described above.
styled-components
, a dependency of this library, comes with its own rules and restrictions regarding multiple instances.
It should always be deduplicated, and using its SC_ATTR
feature is recommended. @splunk/webpack-configs
enables it by default.
Further reading:
FAQs
Library of React components that implement the Splunk design language
The npm package @splunk/react-ui receives a total of 1,828 weekly downloads. As such, @splunk/react-ui popularity was classified as popular.
We found that @splunk/react-ui demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Security Fundamentals
The Socket Threat Research Team uncovers how threat actors weaponize shell techniques across npm, PyPI, and Go ecosystems to maintain persistence and exfiltrate data.
Security News
At VulnCon 2025, NIST scrapped its NVD consortium plans, admitted it can't keep up with CVEs, and outlined automation efforts amid a mounting backlog.
Product
We redesigned our GitHub PR comments to deliver clear, actionable security insights without adding noise to your workflow.