Gathering detailed insights and metrics for @sequencemedia/react-router-redux-render
Gathering detailed insights and metrics for @sequencemedia/react-router-redux-render
Gathering detailed insights and metrics for @sequencemedia/react-router-redux-render
Gathering detailed insights and metrics for @sequencemedia/react-router-redux-render
npm install @sequencemedia/react-router-redux-render
67.1
Supply Chain
85.3
Quality
96.6
Maintenance
100
Vulnerability
100
License
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
2 Stars
1,655 Commits
1 Watching
1 Branches
1 Contributors
Updated on 28 Nov 2024
JavaScript (94.7%)
Shell (5.3%)
Cumulative downloads
Total Downloads
Last day
-89.8%
9
Compared to previous day
Last week
-33.9%
181
Compared to previous week
Last month
45.6%
1,898
Compared to previous month
Last year
-56.1%
37,666
Compared to previous year
Render isomorphic React apps and components in Node.
Compatible with React Router 5.
An example implementation can be found in react-router-pagination-io.
In Express:
1const express = require('express') 2 3const app = express() 4const port = 3000 5 6const { 7 configureStore 8} = require('./path/to/store') 9 10const store = configureStore() 11 12const routes = require('./path/to/routes') 13 14const { 15 renderToString 16} = require('react-router-redux-render') 17 18app.get('/', ({ url: { path: pathname = '/' } }, res) => res.send(renderToString(store, routes, pathname))) 19 20app.listen(port, () => console.log(`Express ${port}`))
If React Router matches the pathname
to a <Route />
then renderToString
returns a string.
If renderToString
encounters an error then it throwa a 500 Internal Server Error
.
If renderToString
cannot match the pathname
to a <Route />
then it throws a 404 Not Found
.
react-router-redux-render
exports three functions:
renderToString
renderToStaticMarkup
render
renderToString
generates <html />
including the attributes that React uses in ReactDOM.hydrate()
. It implements ReactDOMServer.renderToString()
.
renderToStaticMarkup
doesn't include those attributes. It's useful for using React as a rendering engine for static pages. It implements ReactDOMServer.renderToStaticMarkup()
.
render
executes renderToString
but returns a Promise
which resolves to a string.
@sequencemedia/react-router-redux-render
for React Router apps (with Redux)@sequencemedia/react-router-render
for React Router apps (without Redux)@sequencemedia/react-redux-render
for React Redux apps (without React Router)No vulnerabilities found.
Reason
no binaries found in the repo
Reason
30 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 10
Reason
0 existing vulnerabilities detected
Reason
Found 0/30 approved changesets -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
license file not detected
Details
Reason
project is not fuzzed
Details
Score
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More