Skip to content

Commit

Permalink
add license, update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
AugusteLef committed Feb 7, 2024
1 parent 826c3e9 commit e78ce79
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 53 deletions.
7 changes: 7 additions & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Copyright 2024 CodeMuse, Inc

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
82 changes: 61 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,58 +14,98 @@
</div>

---
# Introduction

A collection of high-quality, unstyled components for creating beautiful PDFs using React and TypeScript. Forget about docx, latex, or painful outdates libraries. With react-print, embrace a new way you create PDFs, designed by and for developers.

# Why

At [Onedoc](https://www.onedoclabs.com/), we believe documents are the core of communication. Invoice, contracts, resume, bill, etc. Documents are the #1 way to exchange information with others in a professional way, so why are we still using decades old technology to create them ? We believe that you deserve better. Document production needs to be modernized. Start today and create your next PDF the same way you build a webapp. And yes, it includes automation of data integration into your documents.

# Getting started

## 1. Installation

Get the react-print component library.

<CodeGroup>

### With npm
```sh npm
npm install -s @onedoc/react-print
```

### With yarn
```sh yarn
yarn add @onedoc/react-print
```

### With pnpm
```sh pnpm
pnpm add @onedoc/react-print
```

</CodeGroup>

## 2. Import component

Import a component as follow:
Import the components you need to your PDF template from our list of pre-build components :

```javascript
import { PageTop, PageBottom, PageBreak } from '@onedoc/react-print';
```

## 3. Integrate in your document:

Integrate your components and include styles where needed.

```javascript
export const document = ({props}) => {
return (
<div>
<PageTop>
<span>Hello #1</span>
</PageTop>
<div>
<PageTop>
<span>Hello #1</span>
</PageTop>
<div>
Hello #2
</div>
<PageBottom>
<div className="text-gray-400 text-sm">
Hello #3
</div>
</PageBottom>
<PageBreak />
<span>Hello #4, but on a new page ! </span>
Hello #2
</div>
);
<PageBottom>
<div className="text-gray-400 text-sm">
Hello #3
</div>
</PageBottom>
<PageBreak />
<span>Hello #4, but on a new page ! </span>
</div>
);
};
```

# Components
A set of standard components to help you build amazing documents without having to deal with the mess of creating complex layouts and maintaining archaic markup. Help us increasing the length of this list by contributing actively and adding your favorite components !

* [Footnote](https://github.com/OnedocLabs/react-print/tree/main/src/Footnote)
* [Shell](https://github.com/OnedocLabs/react-print/tree/main/src/Shell)
* [Running Header](https://github.com/OnedocLabs/react-print/tree/main/src/RunningHeader)

# Integrations

PDFs generated by *React Print* can be hosted (and more) on your favorite document management providers.

* [Onedoc](https://app.onedoclabs.com/login) **(our preferred system, designed by and for developers)**
* Google Drive *(coming soon..)*
* Microsoft SharePoint *(coming soon..)*

# Contributing

This project is open-source and is meant to be maintained and build by and for the developers. </br>

Wanna help ? Awesome! There are many ways you can contribute ! Take a look at:

* (Contributing Guide)[www.google.com]

# Authors

* Auguste L. ([@thisisnotFranck](https://twitter.com/thisisnotfranck))
* Pierre D. ([@pierre_dge120](https://twitter.com/pedro_dge120))
* Titouan L. ([@titouan325](https://twitter.com/titouan325))

# License

[MIT License]()

---
32 changes: 0 additions & 32 deletions docs/README.md

This file was deleted.

0 comments on commit e78ce79

Please sign in to comment.