https://github.com/facundovictor/jsfiddle-downloader
It allows to download all your jsFiddles' scripts, just using a NodeJS script
https://github.com/facundovictor/jsfiddle-downloader
fiddle jsfiddle jsfiddle-downloader nodejs
Last synced: about 1 year ago
JSON representation
It allows to download all your jsFiddles' scripts, just using a NodeJS script
- Host: GitHub
- URL: https://github.com/facundovictor/jsfiddle-downloader
- Owner: facundovictor
- License: mit
- Created: 2015-11-19T21:27:35.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2019-04-27T14:58:33.000Z (about 7 years ago)
- Last Synced: 2025-05-04T01:01:52.522Z (about 1 year ago)
- Topics: fiddle, jsfiddle, jsfiddle-downloader, nodejs
- Language: JavaScript
- Homepage:
- Size: 93.8 KB
- Stars: 11
- Watchers: 3
- Forks: 11
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# jsfiddle-downloader
[](https://travis-ci.org/facundovictor/jsfiddle-downloader) [](https://badge.fury.io/js/jsfiddle-downloader) [](https://raw.githubusercontent.com/facundovictor/jsfiddle-downloader/master/LICENSE) [](https://npm-stat.com/charts.html?package=jsfiddle-downloader)
[](https://app.fossa.io/projects/git%2Bgithub.com%2Ffacundovictor%2Fjsfiddle-downloader?ref=badge_shield)
Download fiddles from jsFiddle.net, just using a NodeJS script and save it as a single HTML file.

**Installation**:
```
npm install jsfiddle-downloader -g
```
**How to use it**:
```
Usage: jsfiddle-downloader [options]
Options:
-h, --help output usage information
-V, --version output the version number
-u, --user Save all the users fiddles
-l, --link Url of the fiddle to save
-o, --output Target path to download the data
-c, --compressed Compress the spaces of the HTML output
-i, --identifier Identifier of the fiddle to save
-f, --force-http Use http when the URI method is undefined
-v, --verbose Verbose output
-I, --filename-identifier Use fiddle identifier as filename (default)
-T, --filename-title Use fiddle title as filename
-IT, --filename-identifier-title Use fiddle identifier and title as filename
-S, --filename-spaces Keep spaces in filename (default: replace by underscores)
```
To download a single fiddle from its id:
```
jsfiddle-downloader -i [-o ] [-f]
```
To download a single fiddle from its url:
```
jsfiddle-downloader -l [-o ]
jsfiddle-downloader -l jsfiddle.net//
jsfiddle-downloader -l jsfiddle.net///
jsfiddle-downloader -l https://jsfiddle.net/
jsfiddle-downloader -l https://jsfiddle.net//
jsfiddle-downloader -l https://jsfiddle.net///show/ -o myfiddle.html
```
To download all scripts of a determinated 'user' from jsFiddle.net:
```
jsfiddle-downloader -u [-o ]
```
It'll download all backups in the currrent directory, the jsFiddles scripts will be named by default as:
```
[/].html
```
To save the files using the fiddle's title, provide the parameter `-T`:
```
jsfiddle-downloader -T -u [-o ]
```
It'll download all backups in the currrent directory, the jsFiddles scripts will be named as:
```
[/].html
```
To avoid running a local server for resolving URIs that doesn't have an URI method defined. Use the `-f` parameter:
```
jsfiddle-downloader -f -i
jsfiddle-downloader -f -l
jsfiddle-downloader -f -u
```
This will replace all the `http://` in the href of link tags and in the src of script tags.
You can make the filenames more informative with these options:
`-T` : `.html` (title given to the fiddle to make it public)
`-IT`: `_.html` (combined identifier and title)
`-S` : Keep spaces in filename (default: replace by underscores)
**Tests:**
In the project directory `jsfiddle-downloader` run
`mocha test [--keep]`
If you run tests with option `--keep`, the temporary directories containing
html files downloaded during tests will be preserved for inspection.
## License
[](https://app.fossa.io/projects/git%2Bgithub.com%2Ffacundovictor%2Fjsfiddle-downloader?ref=badge_large)