question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Do you have any option to write to a file while using CLI.

I tried to use it in my angular project using but it throws an error `‘use strict’; const excelToJson = require(‘convert-excel-to-json’);

const result = excelToJson({ sourceFile: ‘SOME-EXCEL-FILE.xlsx’ });` image

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
DiegoZoracKycommented, Jul 10, 2018

@naresh217 Get the new version 1.4.0. You were right. When defining outputJSON both versions were being printed on stdout (JSON and raw Object Literal). Now the outputJSON is not needed anymore. I took the time to also make some improvements that were on my todo list, on the usage via CLI.

From now on you can pass only the sourceFile option instead of the whole config in JSON format. Example:

$ convert-excel-to-json --sourceFile="tests/test-data.xlsx"

Also, it has now a better help section:

$ convert-excel-to-json --help

You can check more info about it here: https://github.com/DiegoZoracKy/convert-excel-to-json#cli

Thanks for opening this issue.

0reactions
DiegoZoracKycommented, Jul 10, 2018

Great 🤘

Read more comments on GitHub >

github_iconTop Results From Across the Web

Python File Write - W3Schools
Write to an Existing File. To write to an existing file, you must add a parameter to the open() function: "a" - Append...
Read more >
Writing to file in Python - GeeksforGeeks
There are two ways to write in a file. write() : Inserts the string str1 in a single line in the text file....
Read more >
Java - Write to File - Baeldung
In this tutorial, we'll explore different ways to write to a file using Java. We'll make use of BufferedWriter, PrintWriter, FileOutputStream, ...
Read more >
How to write to a text file - C# Programming Guide
The third example shows how to add text to a file when you have to process each line individually as you write to...
Read more >
Writing to a file - FutureLearn
Storing data is important as it enables the user to retain information for future use. Learn how to open and write to a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found