Gatsby: Update gatsby-transformer-excel's default options

Created on 31 Aug 2018  路  4Comments  路  Source: gatsbyjs/gatsby

Summary

gatsby-transformer-excel is essentially a wrapper around the excellent js-xlsx library. Currently one of the default transformer options is the opposite of the equivalent option in js-xlsx. This seems confusing, so it should probably be changed.

Refs: https://github.com/gatsbyjs/gatsby/pull/7780

Basic example

If you don't specify the raw or rawOutput option, a value of true will be used in the underlying js-xlsx function. This is opposite the library's default value of false.

Motivation

Reverting the default option is a breaking change, but means that the transformer plugin matches the underlying library defaults.

help wanted

All 4 comments

The default option in question was a mistake. The original version of gatsby-transformer-excel intentionally forced the option raw:true.

We've hesitated to change any of the defaults in the library, but this is probably as good a time as any to fix the problem. Will touch base once the change is made and the next version is released

As I was going through the js-xlsx lib and the gatsby plugin I actually felt the default for the raw option should have been true, glad to hear it will be fixed in the underlying lib.

Sounds like once that change is in we'll just need to update to the newest version.

@mikelax @m-allanson xlsx version 0.14.0 flipped the default.

great, thanks @SheetJSDev . @m-allanson I'll take this ticket and create a quick PR for this.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

theduke picture theduke  路  3Comments

rossPatton picture rossPatton  路  3Comments

andykais picture andykais  路  3Comments

brandonmp picture brandonmp  路  3Comments

signalwerk picture signalwerk  路  3Comments