Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
am-xlsx2json
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Aksimaya
am-xlsx2json
Commits
8fa552db
Commit
8fa552db
authored
Nov 05, 2015
by
Heddi Heryadi
💪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
initial upload
parents
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
72 additions
and
0 deletions
+72
-0
.gitignore
.gitignore
+2
-0
README.md
README.md
+50
-0
index.js
index.js
+1
-0
package.json
package.json
+19
-0
No files found.
.gitignore
0 → 100644
View file @
8fa552db
/node_modules
\ No newline at end of file
README.md
0 → 100644
View file @
8fa552db
# am-xlsx2json
Converting xlsx file to json files using nodejs (js-xlsx)
## Install
```
npm install https://repo.aksimaya.id/aksimaya/am-xlsx2json.git
```
## Usage
```
javascript
xlsxj
=
require
(
"
am-xlsx2json
"
);
xlsxj
({
input
:
"
sample.xlsx
"
,
output
:
"
output.json
"
},
function
(
err
,
result
)
{
if
(
err
)
{
console
.
error
(
err
);
}
else
{
console
.
log
(
result
);
}
});
```
### Specifying a target sheet
You can optionally provide a sheet name to extract from that sheet
```
javascript
xlsxj
=
require
(
"
am-xlsx2json
"
);
xlsxj
({
input
:
"
sample.xlsx
"
,
output
:
"
output.json
"
,
sheet
:
"
tags
"
},
function
(
err
,
result
)
{
if
(
err
)
{
console
.
error
(
err
);
}
else
{
console
.
log
(
result
);
}
});
```
In config object, you have to enter an input path. But If you don't want to output any file you can set to
`null`
.
## License
\ No newline at end of file
index.js
0 → 100644
View file @
8fa552db
index
.
js
package.json
0 → 100644
View file @
8fa552db
{
"name"
:
"am-xlsx2json"
,
"version"
:
"1.0.0"
,
"description"
:
"just for test"
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"node index.js"
},
"author"
:
"Aksimaya Dev"
,
"license"
:
"
ISC
"
,
"dependencies"
:
{
"
csv
"
:
"
^0.4.6
"
,
"
xlsx
"
:
"
^0.8.0
"
},
"devDependencies"
:
{
"
mocha
"
:
"
^2.3.3
"
,
"
should
"
:
"
^7.1.1
"
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment