Updated JQuery; Added resize sensor library; Updated the admin code (prior to changing gears to use Meteor).
This commit is contained in:
15
csv.js
Normal file
15
csv.js
Normal file
@@ -0,0 +1,15 @@
|
||||
|
||||
var fs = require("fs");
|
||||
var csv = require('csv-parse');
|
||||
|
||||
module.exports = {
|
||||
read: function(csvFilePath, callback) {
|
||||
var parser = csv({delimiter: '\t'}, function(error, data) {
|
||||
if(error) callback(error);
|
||||
else callback(null, data);
|
||||
});
|
||||
|
||||
|
||||
fs.createReadStream(csvFilePath).pipe(parser);
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user