
Product
Introducing GitHub Actions Scanning Support
Detect malware, unsafe data flows, and license issues in GitHub Actions with Socket’s new workflow scanning support.
@centrifuge/centrifuge-react
Advanced tools
This package contains React components and utilities, combining centrifuge-js and fabric
To start using this package, install the package and its peer dependencies:
# yarn
yarn add @centrifuge/centrifuge-react @centrifuge/centrifuge-js @centrifuge/fabric react react-dom styled-components
# npm
npm install --save @centrifuge/centrifuge-react @centrifuge/centrifuge-js @centrifuge/fabric react react-dom styled-components
Import the Provider component, Fabric's FabricProvider component and a theme, and add them to the root of your React app.
import { Provider } from '@centrifuge/centrifuge-react'
import { FabricProvider, GlobalStyle, centrifugeLight } from '@centrifuge/fabric'
import centrifugeLight from '@centrifuge/fabric/dist/theme/centrifugeLight'
// Optionally override the config for CentrifugeJS
// Needs to me memoized, so as not to recreate an instance of CentrifugeJS each render
const config = {
network: 'altair',
}
function App() {
return (
<Provider centrifugeConfig={config}>
<FabricProvider theme={centrifugeLight}>
<GlobalStyle />
{/* Rest of your React app */}
</FabricProvider>
</Provider>
)
}
$ yarn storybook
Will start the Storybook to allow development of the components in isolation
$ yarn start
Will build locally and listen for changes, allowing to see the changes directly when working on centrifuge-app, for example
Create a new branch and run yarn bump, which bumps the package version, updates the changelog, creates a commit and tags it. Push the branch/tag, which should publish the version to NPM. Open a PR to merge the changes to main. For generating the changelog, make sure to use the conventional commits spec in your commits, with centrifuge-react as the scope, e.g.: feat(centrifuge-react): Add useCentrifugeQuery
FAQs
Centrifuge React Library
We found that @centrifuge/centrifuge-react 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.

Product
Detect malware, unsafe data flows, and license issues in GitHub Actions with Socket’s new workflow scanning support.

Product
Add real-time Socket webhook events to your workflows to automatically receive pull request scan results and security alerts in real time.

Research
The Socket Threat Research Team uncovered malicious NuGet packages typosquatting the popular Nethereum project to steal wallet keys.