
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
@metamask/design-system-twrnc-preset
Advanced tools
@metamask/design-system-twrnc-preset
Design System twrnc preset
First, install the package:
yarn add @metamask/design-system-twrnc-preset
or
npm install @metamask/design-system-twrnc-preset
This package requires the following peer dependencies to be installed in your project:
yarn add react@^18.2.0 react-native@0.72.15 twrnc@^4.5.1
or
npm install react@^18.2.0 react-native@0.72.15 twrnc@^4.5.1
import {
ThemeProvider,
Theme,
useTailwind,
} from '@metamask/design-system-twrnc-preset';
function App() {
return (
<ThemeProvider theme={Theme.Light}>
<MyComponent />
</ThemeProvider>
);
}
function MyComponent() {
const tw = useTailwind();
return (
<View style={tw`p-4 bg-background-default`}>
<Text style={tw`text-text-default text-heading-lg`}>
Hello MetaMask Design System!
</Text>
</View>
);
}
To get Tailwind IntelliSense and ESLint plugin support, use the config generator:
TypeScript:
// tailwind.config.ts
import {
generateTailwindConfig,
Theme,
} from '@metamask/design-system-twrnc-preset/tailwind.config';
export default {
content: ['./src/**/*.{js,jsx,ts,tsx}'],
...generateTailwindConfig(Theme.Light),
};
JavaScript:
// tailwind.config.js
const {
generateTailwindConfig,
Theme,
} = require('@metamask/design-system-twrnc-preset/tailwind.config');
module.exports = {
content: ['./src/**/*.{js,jsx,ts,tsx}'],
...generateTailwindConfig(Theme.Light),
};
Custom content paths:
// tailwind.config.ts
import {
generateTailwindConfig,
Theme,
} from '@metamask/design-system-twrnc-preset/tailwind.config';
export default {
content: [
'./src/**/*.{js,jsx,ts,tsx}',
'./app/**/*.{js,jsx,ts,tsx}',
'./components/**/*.{js,jsx,ts,tsx}',
'./screens/**/*.{js,jsx,ts,tsx}',
'./lib/**/*.{js,jsx,ts,tsx}',
],
...generateTailwindConfig(Theme.Light),
};
This provides:
eslint-plugin-tailwindcss
This package is part of a monorepo. Instructions for contributing can be found in the monorepo README.
FAQs
Design System twrnc Preset
The npm package @metamask/design-system-twrnc-preset receives a total of 29,144 weekly downloads. As such, @metamask/design-system-twrnc-preset popularity was classified as popular.
We found that @metamask/design-system-twrnc-preset demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 9 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
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.