Skip to content
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

Feature/muhammara recipe #253

Merged
merged 23 commits into from
Jan 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@ muhammarajs
build
.DS_Store
tests/output
tests/**/output
binding
node_modules
aws.json
etc
recipe-docs/

#all the binaries
# Compiled source #
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
### Added

- Pre builts for arm64 / musl architecture (M1 using alpine)
- Hummus-recipe / Muhammara-recipe as part of this lib

### Fixed

Expand Down
41 changes: 35 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,28 @@
[![NPM version](http://img.shields.io/npm/v/muhammara.svg?style=flat)](https://www.npmjs.org/package/muhammara)
[![Build status](https://github.com/julianhille/MuhammaraJS/actions/workflows/build.yml/badge.svg?branch=develop)](https://github.com/julianhille/MuhammaraJS/actions/workflows/build.yml)

Welcome to MuhammaraJS.
A Fast NodeJS Module for Creating, Parsing an Manipulating PDF Files and Streams.

Original Project (CPP base version)
Project site is [here](http://www.pdfhummus.com).

If you are looking for a C++ Library go [here](https://github.com/galkahana/PDF-Writer).

## Hummus JS is the base

This is a drop in replacement for hummusJS originally made by Galkahana.
He did an awesome job, but discontinued hummusjs.

The documentation for MuhammaraJS / HummusJS is still located at the
hummusJS github wiki: available [here](https://github.com/galkahana/HummusJS/wiki)

Welcome to HummusJS.
A Fast NodeJS Module for Creating, Parsing an Manipulating PDF Files and Streams.
## muhammara-recipe '(formerly known as hummus-recipe) as been added

Original Project
Project site is [here](http://www.pdfhummus.com).
Muhammara-recipe and hummus-recipe has been integrated, dependencies updated
and is now shipped along with muhammara itself.

If you are looking for a C++ Library go [here](https://github.com/galkahana/PDF-Writer).
It serves as a drop in replacement.

# Caution

Expand All @@ -36,7 +45,7 @@ npm install muhammara

```

# Replace hummusJS with MuhammaraJS
# Replace hummusJS with MuhammaraJS for hummus

Replace:

Expand All @@ -50,6 +59,26 @@ With:
let muhammara = require('muhammara')
```

# Replace hummus-recipe or muhammara-recipe with MuhammaraJS

Replace:

`const HummusRecipe = require('hummus-recipe');`

With:

```
const HummusRecipe = require('muhammara').Receipe;
```

# Documentation

## Muhammara

You can find samples and documentation [here](./docs/Home.md)

### Muhammara Recipe:

To generate the documentation you could clone this repo and execute:

`npm run recipe-jsdoc`
2 changes: 1 addition & 1 deletion docs/Custom-streams.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ The `write` function should write the byte in the input array of bytes. It shoul

The `getCurrentPosition()` function should return the current writing position. If you've been good kids, it's ok to simply sum up the number of bytes written from all the `write` calls so far, and you should be fine.

To see an example implementation see what i did for the response stream [here](../PDFStreamForResponse.js).
To see an example implementation see what i did for the response stream [here](../lib/PDFStreamForResponse.js).

# Reading streams

Expand Down
Binary file added fonts/Courier New.ttf
Binary file not shown.
Binary file added fonts/Georgia.ttf
Binary file not shown.
Binary file added fonts/Helvetica-bold-italic.ttf
Binary file not shown.
Binary file added fonts/Helvetica-bold.ttf
Binary file not shown.
Binary file added fonts/Helvetica-italic.ttf
Binary file not shown.
Binary file added fonts/Helvetica.ttf
Binary file not shown.
Binary file added fonts/Roboto.ttf
Binary file not shown.
Binary file added fonts/arial.ttf
Binary file not shown.
24 changes: 24 additions & 0 deletions jsdoc.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"tags": {
"allowUnknownTags": false
},
"source": {
"include": "./lib/",
"includePattern": "(Recipe\\.js)|(recipe/.*\\.js)$",
"excludePattern": "(node_modules/|docs)"
},
"plugins": [
"plugins/markdown"
],
"opts": {
"template": "node_modules/docdash",
"encoding": "utf8",
"destination": "recipe-docs/",
"recurse": true,
"verbose": true
},
"templates": {
"cleverLinks": false,
"monospaceLinks": false
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading