Skip to content

Undeclared variable QUOTE #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
sfmoreno opened this issue Jul 7, 2021 · 7 comments · May be fixed by #10
Closed

Undeclared variable QUOTE #7

sfmoreno opened this issue Jul 7, 2021 · 7 comments · May be fixed by #10

Comments

@sfmoreno
Copy link

sfmoreno commented Jul 7, 2021

Hi, there's an error in the line 21524 of the file xlsx.js. The variable QUOTE is not declared, and this generates an error when you build a project using this library.

var APOS = "'"; QUOTE = '"'

It looks like a typo, I just changed the ; for a , and it works perfectly.

Thanks.

@ShanaMaid
Copy link
Owner

welcome to pr!

@mephasor
Copy link

mephasor commented Nov 3, 2021

Did I miss something or is the typo still there?

pascalgn added a commit to pascalgn/sheetjs-style that referenced this issue Mar 2, 2022
@pascalgn
Copy link

pascalgn commented Mar 2, 2022

@ShanaMaid I've created a PR for it: #10 🙏

@JJWins
Copy link

JJWins commented Nov 23, 2022

@ShanaMaid Please merge this, I am not able to use this library due to this type error.

Please take a look at the images below
image
image

@WiharlleyWill
Copy link

Use XLSX lib.

`import * as XLSX from 'xlsx';
...

exportToExcel() {
const fileName = 'test.xlsx';

	const ws: XLSX.WorkSheet = XLSX.utils.json_to_sheet(this.arr);
	const wb: XLSX.WorkBook = XLSX.utils.book_new();
	XLSX.utils.book_append_sheet(wb, ws, 'test');

	XLSX.writeFile(wb, fileName);

}
`

@SweydManaf
Copy link

has vulnerabilities

@sagarpatelpro
Copy link

I have a work around.
Just declare "QUOTE" as global variable.

In my case, I am writing a react application, so I just added it to the index.html file.

In index.html file, before including any other source code script.
<script type="text/javascript"> var QUOTE; </script>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants