Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

vweevers/node-phpexcel-stream

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-phpexcel-stream

Memory-efficient spreadsheet to CSV converter. Won't make you love PHP, but it handles big files well and supports 8 different file formats.

npm status Travis build status AppVeyor build status Dependency status

example

var excel      = require('phpexcel-stream')
  , fs         = require('fs')
  , csvParser  = require('csv-parser')
  , JSONStream = require('jsonstream')

fs.createReadStream('test/air_pollution_nl.xlsx')
  .pipe( excel() )
  .pipe( csvParser() )
  .pipe( JSONStream.stringify() )
  .pipe( process.stdout )

api

excel([extension])

Returns a duplex stream - give it a spreadsheet, get back CSV. Optionally pass extension as a file format hint to PHPExcel (format is autodetected otherwise).

supported file formats

  • Office Open XML (.xlsx) (Excel 2007 and above)
  • SpreadsheetML (.xml) (Excel 2003)
  • BIFF 5-8 (.xls) (Excel 95 and above)
  • Open Document Format/OASIS (.ods)
  • Gnumeric (GNOME)
  • HTML (why)
  • SYLK (no idea)
  • CSV (but you can and should use csv-parser in node)

requirements

  • PHP >= 5.4.0, must be available in PATH

install

With npm do:

npm install phpexcel-stream

license

MIT © Vincent Weevers. Test data © Statistics Netherlands, The Hague/Heerlen.

About

Memory-efficient spreadsheet to CSV converter

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published