Skip to content

Commit

Permalink
Updated docs
Browse files Browse the repository at this point in the history
IonicaBizau committed Sep 8, 2017
1 parent e80a7c2 commit 246ca75
Showing 3 changed files with 20 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -3,3 +3,6 @@
*~
*.log
node_modules
*.env
.DS_Store
package-lock.json
5 changes: 5 additions & 0 deletions DOCUMENTATION.md
Original file line number Diff line number Diff line change
@@ -7,6 +7,7 @@ This is the constructor that creates a new instance containing the needed
methods.

#### Params

- **Object** `options`: The options for creating the new invoice:
- `config` (Object):
- `template` (String): The HTML root template.
@@ -23,12 +24,14 @@ methods.
Inits the HTML templates.

#### Params

- **Function** `callback`: The callback function.

### `toHtml(output, callback)`
Renders the invoice in HTML format.

#### Params

- **String** `output`: An optional path to the output file.
- **Function** `callback`: The callback function.

@@ -40,6 +43,7 @@ Converts a currency into another currency according to the currency
balance provided in the options

#### Params

- **Number** `input`: The number that should be converted

#### Return
@@ -49,6 +53,7 @@ balance provided in the options
Renders invoice as pdf

#### Params

- **Object|String|Stream** `options`: The path the output pdf file, the stream object, or an object containing:

- `output` (String|Stream): The path to the output file or the stream object.
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
<!-- Please do not edit this file. Edit the `blah` field in the `package.json` instead. If in doubt, open an issue. -->


[![nodeice](http://i.imgur.com/NuF1OI0.png)](#)

# nodeice

[![Support me on Patreon][badge_patreon]][patreon] [![Buy me a book][badge_amazon]][amazon] [![PayPal][badge_paypal_donate]][paypal-donations] [![Version](https://img.shields.io/npm/v/nodeice.svg)](https://www.npmjs.com/package/nodeice) [![Downloads](https://img.shields.io/npm/dt/nodeice.svg)](https://www.npmjs.com/package/nodeice)
[![Support me on Patreon][badge_patreon]][patreon] [![Buy me a book][badge_amazon]][amazon] [![PayPal][badge_paypal_donate]][paypal-donations] [![Ask me anything](https://img.shields.io/badge/ask%20me-anything-1abc9c.svg)](https://github.com/IonicaBizau/ama) [![Version](https://img.shields.io/npm/v/nodeice.svg)](https://www.npmjs.com/package/nodeice) [![Downloads](https://img.shields.io/npm/dt/nodeice.svg)](https://www.npmjs.com/package/nodeice)

> Another PDF invoice generator
@@ -127,13 +129,15 @@ require("http").createServer((req, res) => {
}).listen(8000);
```



## :question: Get Help

There are few ways to get help:

1. Please [post questions on Stack Overflow](https://stackoverflow.com/questions/ask). You can open issues with questions, as long you add a link to your Stack Overflow question.
2. For bug reports and feature requests, open issues. :bug:
3. For direct and quick help from me, you can [use Codementor](https://www.codementor.io/johnnyb). :rocket:
3. For direct and quick help, you can [use Codementor](https://www.codementor.io/johnnyb). :rocket:


## :memo: Documentation
@@ -144,6 +148,7 @@ This is the constructor that creates a new instance containing the needed
methods.

#### Params

- **Object** `options`: The options for creating the new invoice:
- `config` (Object):
- `template` (String): The HTML root template.
@@ -160,12 +165,14 @@ methods.
Inits the HTML templates.

#### Params

- **Function** `callback`: The callback function.

### `toHtml(output, callback)`
Renders the invoice in HTML format.

#### Params

- **String** `output`: An optional path to the output file.
- **Function** `callback`: The callback function.

@@ -177,6 +184,7 @@ Converts a currency into another currency according to the currency
balance provided in the options

#### Params

- **Number** `input`: The number that should be converted

#### Return
@@ -186,6 +194,7 @@ balance provided in the options
Renders invoice as pdf

#### Params

- **Object|String|Stream** `options`: The path the output pdf file, the stream object, or an object containing:

- `output` (String|Stream): The path to the output file or the stream object.
@@ -209,6 +218,7 @@ this takes time. You can integrate and use these projects in your applications *
However, if you get some profit from this or just want to encourage me to continue creating stuff, there are few ways you can do it:

- Starring and sharing the projects you like :rocket:
- [![Buy me a book][badge_amazon]][amazon]—I love books! I will remember you after years if you buy me one. :grin: :book:
- [![PayPal][badge_paypal]][paypal-donations]—You can make one-time donations via PayPal. I'll probably buy a ~~coffee~~ tea. :tea:
- [![Support me on Patreon][badge_patreon]][patreon]—Set up a recurring monthly donation and you will get interesting news about what I'm doing (things that I don't share with everyone).
- **Bitcoin**—You can send me bitcoins at this address (or scanning the code below): `1P9BRsmazNQcuyTxEqveUsnf5CERdq35V6`

0 comments on commit 246ca75

Please sign in to comment.