https://github.com/vigneshshanmugam/react-memorystats
React Component for Memory Stats
https://github.com/vigneshshanmugam/react-memorystats
component memory react
Last synced: 9 months ago
JSON representation
React Component for Memory Stats
- Host: GitHub
- URL: https://github.com/vigneshshanmugam/react-memorystats
- Owner: vigneshshanmugam
- License: mit
- Created: 2015-06-30T18:16:20.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2022-12-07T07:46:27.000Z (over 3 years ago)
- Last Synced: 2025-09-01T00:20:17.892Z (10 months ago)
- Topics: component, memory, react
- Language: JavaScript
- Size: 420 KB
- Stars: 42
- Watchers: 5
- Forks: 7
- Open Issues: 17
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# react-memory-stats
This Component is based on Paul Irish's [memory-stats](https://github.com/paulirish/memory-stats.js).

### Installation
```javascript
yarn add react-memorystats
```
### Usage
```
import { render } from 'react-dom';
import MemoryStatsComponent from 'react-memorystats';
render(
,
document.getElementById("container")
);
```
#### Config
+ corner - topLeft, topRight (default), bottomLeft, bottomRight
check the example code [here](https://github.com/vigneshshanmugam/react-memory-stats/blob/master/example).
### Start Chrome with `--enable-precise-memory-info`
```
# Linux
google-chrome --enable-precise-memory-info --enable-memory-info
#MacOS
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --enable-precise-memory-info --enable-memory-info
```
Otherwise the results from performance.memory are bucketed and less useful.
### Development
```javascript
// install dependencies
yarn install
// run example locally and start server
yarn start
```