Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 19, 2024 via pnpm

styled-jsx 3.4.4

Full CSS support for JSX without compromises
Package summary
Share
4
issues
1
critical severity
vulnerability
1
2
high severity
vulnerability
2
1
low severity
license
1
4
licenses
22
MIT
1
BSD-2-Clause
1
BSD-3-Clause
1
CC0-1.0
Package created
5 Dec 2016
Version published
16 Feb 2021
Maintainers
3
Total deps
25
Direct deps
10
License
MIT

Issues

4

1 critical severity issue

critical
Recommendation: Upgrade to version 1.4.1 or later
via: loader-utils@1.2.3
Collapse
Expand

2 high severity issues

high
Recommendation: Upgrade to version 1.4.2 or later
via: loader-utils@1.2.3
Recommendation: Upgrade to version 1.4.2 or later
via: loader-utils@1.2.3
Collapse
Expand

1 low severity issue

low
Recommendation: Read and validate the license terms
via: string-hash@1.1.3
Collapse
Expand

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
22 Packages, Including:
@babel/helper-module-imports@7.12.5
@babel/helper-string-parser@7.24.1
@babel/helper-validator-identifier@7.24.5
@babel/types@7.24.5
@babel/types@7.8.3
babel-plugin-syntax-jsx@6.18.0
big.js@5.2.2
convert-source-map@1.7.0
emojis-list@2.1.0
js-tokens@4.0.0
json5@1.0.2
loader-utils@1.2.3
lodash@4.17.21
loose-envify@1.4.0
minimist@1.2.8
object-assign@4.1.1
react@17.0.2
safe-buffer@5.1.2
styled-jsx@3.4.4
stylis-rule-sheet@0.0.10
stylis@3.5.4
to-fast-properties@2.0.0

BSD 2-Clause "Simplified" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
esutils@2.0.3

BSD 3-Clause "New" or "Revised" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
use-trademark
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
source-map@0.7.3

Creative Commons Zero v1.0 Universal

Public Domain
Not OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
Cannot
Must
1 Packages, Including:
string-hash@1.1.3
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

10
All Dependencies CSV
β“˜ This is a list of styled-jsx 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
@babel/helper-module-imports7.12.54.1 kBMIT
prod
@babel/types7.8.386.81 kBMIT
prod
babel-plugin-syntax-jsx6.18.0720 BMIT
prod
convert-source-map1.7.03.84 kBMIT
prod
loader-utils1.2.38.73 kBMIT
prod
1
2
react17.0.272.94 kBMIT
prod peer
source-map0.7.383.92 kBBSD-3-Clause
prod
string-hash1.1.31.42 kBCC0-1.0
prod
1
stylis-rule-sheet0.0.101.09 kBMIT
prod
stylis3.5.431.57 kBMIT
prod peer

Visualizations

Frequently Asked Questions

What does styled-jsx do?

Styled-jsx is a lightweight library developed by Vercel providing complete foolproof CSS support for your JSX files (React components). It enables isolated component-friendly CSS support for both server-rendered and client-rendered applications. The library ensures complete CSS isolation by applying unique classnames to your styles. It leverages the CSSOM APIs for a blazing fast CSS rules injection system and fully supports CSS source maps. Additionally, you get automatic vendor prefixing and dynamic styles and themes support with Styled-jsx, keeping your codebase future-proof. The runtime size of Styled-jsx is only 3kb, making it a preference for performance-sensitive applications.

How do you use styled-jsx?

To use styled-jsx, first, install it via npm by running npm install --save styled-jsx from your terminal. After installing the package, add styled-jsx/babel to plugins in your babel configuration:

{
  "plugins": ["styled-jsx/babel"]
}

Styled-jsx allows you to write isolated CSS code inside your components using <style jsx> tags. For instance:

export default () => (
  <div>
    <p>only this paragraph will get the style :)</p>

    <style jsx>{`
      p {
        color: red;
      }
    `}</style>
  </div>
)

In the above example, the p tag inside the div will get the style specified in <style jsx>.

Where are the styled-jsx docs?

Complete styled-jsx documentation and usage is available in the GitHub repo at https://github.com/vercel/styled-jsx. This documentation includes getting started instructions, configuration options, features, usage details, and more.