Security News
Input Validation Vulnerabilities Dominate MITRE's 2024 CWE Top 25 List
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
[![NPM](https://nodei.co/npm/m1js.png?downloads=true&stars=true)](https://nodei.co/npm/m1js/)
The goal is to create simple graphs at server end and save it to png, so the client can load it instead of preparing it.
###Install
$npm install m1js
###Types of Graphs
###Usage
#####Pie Chart
var m1js = require('m1js');
m1js.createAPie({
data : [{
labels : "Car",
data : 45
},{
labels : "Cycle",
data : 10
},{
labels : "Walk",
data : 10
},{
labels : "Bus",
data : 20
}],
outputFolder : __dirname,
labelPath : "labels"
},function(imgPath){
//...
});
#####Bar Chart
var m1js = require('m1js');
m1js.createABar({
data : [{
label : "2012",
data : 50
},{
label : "2013",
data : 35
},{
label : "2014",
data : 45
},{
label : "2015",
data : 20
},{
label : "2016",
data : 80
}],
outputFolder : __dirname
},function(imgPath){
//....
});
#####Line Chart
var m1js = require('m1js');
m1js.createALine({
data : [{
label : "Sun",
data : 45
},{
label : "Mon",
data : 20
},{
label : "Tue",
data : 80
},{
label : "Wed",
data : 45
},{
label : "Thr",
data : 20
},{
label : "Fri",
data : 80
},{
label : "Sat",
data : 50
}],
outputFolder : __dirname
},function(imgPath){
//...
});
#####Donut Chart
var m1js = require('m1js');
m1js.createADonut({
data : [{
labels : "jQuery",
data : 45
},{
labels : "Ruby",
data : 20
},{
labels : "Python",
data : 20
}],
outputFolder : __dirname,
labelPath : "labels"
},function(imgPath){
//...
});
#####HBar Chart
var m1js = require('m1js');
m1js.createAHBar({
data : [{
labels : "USA",
data : 45
},{
labels : "Europe",
data : 50
},{
labels : "Asia",
data : 60
}],
outputFolder : __dirname,
labelPath : "labels"
},function(imgPath){
//...
});
####RoadMap
####FAQ's
Having issues installing canvas
Install lib through the below command. sudo apt-get install libcairo2-dev libjpeg-dev libgif-dev
Make sure you have G++ 4.8. sudo apt-get install g++-4.8
####Preview
FAQs
[![NPM](https://nodei.co/npm/m1js.png?downloads=true&stars=true)](https://nodei.co/npm/m1js/)
We found that m1js 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
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.