
Security News
OpenClaw Advisory Surge Highlights Gaps Between GHSA and CVE Tracking
A recent burst of security disclosures in the OpenClaw project is drawing attention to how vulnerability information flows across advisory and CVE systems.
react-native-extensible-stylesheet
Advanced tools
Extensible stylesheets for react-native
A simple & tiny drop-in replacement for the react-native StyleSheet module,
which add support for extending stylesheets and defining variables. Uses
react-native's StyleSheet under the hood.
Install via npm:
npm install --save react-native-extensible-stylesheet
We can create a new StyleSheet just as we would with react-native's
StyleSheet.create(). For example, let's create a 'theme' stylesheet:
// file: theme.js
import StyleSheet from 'react-native-extensible-stylesheet'
export default StyleSheet.create({
centeredText: {
textAlign: 'center'
},
fade: {
opacity: 0.5
},
header: {
fontSize: 22,
fontWeight: 'bold'
}
})
We can then import the theme stylesheet elsewhere and extend() it. When we
extend a stylesheet we get all the definitions from the original. We can also
add new definitions, and extend or completely override existing definitions.
In the example below, we just add a new definition, myNewStyle. The
resulting stylesheet will contain myNewStyle, plus everything defined in
theme.js (centeredText, fade and header).
// file: MyAmazingComponent/styles.js
import theme from '../theme.js'
export default theme.extend({
myNewStyle: {
color: '#FF0000'
}
})
In the next example we add a new rule to the existing header definition to
make the text gray, and override it's fontSize value. The text will still
be bold as we will inherit fontSize: 'bold' from theme.js:
// file MyAmazingComponent/styles.js
import theme from '../theme.js'
export default theme.extend({
header: {
fontSize: 26, // Overrides fontSize from theme.js
color: '#AAAAAA'
}
})
We can also define variables by prefixing property names with $:
// file: theme.js
import StyleSheet from 'react-native-extensible-stylesheet'
export default StyleSheet.create({
$primaryColor: '#FF0000',
header: {
color: '$primaryColor' // Variables can be referenced using their names
}
})
Variables are included in any extensions of the stylesheets:
// file: MyAmazingComponent/styles.js
import theme from '../theme.js'
export default theme.extend({
myNewStyle: {
color: '$primaryColor'
}
})
Coming soon to an example/ folder near you!
npm testnpm run lintindex.js2nd August 2016 - v0.0.3 - Ensure statics from base StyleSheet are copied onto ExtensibleStyleSheet22nd April 2016 - v0.0.2 - Add missing devDependency harmony-reflect22nd April 2016 - v0.0.1 - First released versionFAQs
Extensible stylesheets for react-native
We found that react-native-extensible-stylesheet demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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 News
A recent burst of security disclosures in the OpenClaw project is drawing attention to how vulnerability information flows across advisory and CVE systems.

Research
/Security News
Mixed-script homoglyphs and a lookalike domain mimic imToken’s import flow to capture mnemonics and private keys.

Security News
Latio’s 2026 report recognizes Socket as a Supply Chain Innovator and highlights our work in 0-day malware detection, SCA, and auto-patching.