Skip to content

Commit

Permalink
[docs] Setup docs github pages (#77)
Browse files Browse the repository at this point in the history
* [docs] Cleanup docs generation script

Docs generation script now uses correct paths, gitignore now allows
committing docs.

* [docs] Update README

* [docs] Publish alpha version of documentation

* [docs] Change README links to be absolute

These links are used both on the README and on the typedoc docs, so
they need to be absolute to work properly.
  • Loading branch information
gregnazario authored Oct 17, 2023
1 parent 2a47af7 commit 3a1129b
Show file tree
Hide file tree
Showing 222 changed files with 50,280 additions and 11 deletions.
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,3 @@ tmp/

# Vim swap files
*.swp

# Doc generation output
docs/
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,30 +7,30 @@
The Aptos TypeScript SDK provides a convenient way to interact with the Aptos blockchain using TypeScript. It offers a
set of utility functions, classes, and types to simplify the integration process and enhance developer productivity.

This repository supports version >= 2.0.0 of the [Aptos SDK npm package](https://www.npmjs.com/package/aptos).
This repository supports version >= 0.0.0 of the [Aptos SDK npm package](https://www.npmjs.com/package/@aptos-labs/ts-sdk).

## Installation

##### For use in Node.js or a web application

Install with your favorite package manager such as npm, yarn, or pnpm:
```bash
npm install aptos
npm install @aptos-labs/ts-sdk
```

##### For use in a browser

You can add the SDK to your web application using a script tag:
```html
<script src="https://unpkg.com/aptos@latest/dist/index.global.js" />
<script src="https://unpkg.com/@aptos-labs/ts-sdk@latest/dist/index.global.js" />
```
Then, the SDK can be accessed through `window.aptosSDK`.
## Documentation and examples
- [The Aptos documentation site](https://aptos.dev/sdks/ts-sdk/index) provides step-by-step instructions, code snippets, and best practices to use this library.
- For in-depth examples, check out the [examples](./examples) folder with ready-made `package.json` files to get you going quickly!
- For in-depth examples, check out the [examples](https://github.com/aptos-labs/aptos-ts-sdk/examples) folder with ready-made `package.json` files to get you going quickly!
### Testing
Expand All @@ -43,11 +43,11 @@ pnpm test
## Contributing
If you found a bug or would like to request a feature, please file an [issue](https://github.com/aptos-labs/aptos-ts-sdk/issues/new/choose).
If, based on the discussion on an issue you would like to offer a code change, please make a [pull request](./CONTRIBUTING.md).
If neither of these describes what you would like to contribute, checkout out the [contributing guide](./CONTRIBUTING.md).
If, based on the discussion on an issue you would like to offer a code change, please make a [pull request](https://github.com/aptos-labs/aptos-ts-sdk/CONTRIBUTING.md).
If neither of these describes what you would like to contribute, checkout out the [contributing guide](https://github.com/aptos-labs/aptos-ts-sdk/CONTRIBUTING.md).
[npm-image-version]: https://img.shields.io/npm/v/aptos.svg
[npm-image-downloads]: https://img.shields.io/npm/dm/aptos.svg
[npm-url]: https://npmjs.org/package/aptos
[npm-url]: https://npmjs.org/package/@aptos-labs/ts-sdk
[discord-image]: https://img.shields.io/discord/945856774056083548?label=Discord&logo=discord&style=flat~~~~
[discord-url]: https://discord.gg/aptosnetwork
5 changes: 5 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
_site
.sass-cache
.jekyll-cache
.jekyll-metadata
vendor
24 changes: 24 additions & 0 deletions docs/404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
permalink: /404.html
---

<style type="text/css" media="screen">
.container {
margin: 10px auto;
max-width: 600px;
text-align: center;
}
h1 {
margin: 30px 0;
font-size: 4em;
line-height: 1;
letter-spacing: -1px;
}
</style>

<div class="container">
<h1>404</h1>

<p><strong>Page not found :(</strong></p>
<p>The requested page could not be found.</p>
</div>
1 change: 1 addition & 0 deletions docs/@aptos-labs/ts-sdk-0.0.0/.nojekyll
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false.
141 changes: 141 additions & 0 deletions docs/@aptos-labs/ts-sdk-0.0.0/assets/highlight.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
:root {
--light-hl-0: #795E26;
--dark-hl-0: #DCDCAA;
--light-hl-1: #000000;
--dark-hl-1: #D4D4D4;
--light-hl-2: #A31515;
--dark-hl-2: #CE9178;
--light-hl-3: #800000;
--dark-hl-3: #808080;
--light-hl-4: #800000;
--dark-hl-4: #569CD6;
--light-hl-5: #000000FF;
--dark-hl-5: #D4D4D4;
--light-hl-6: #E50000;
--dark-hl-6: #9CDCFE;
--light-hl-7: #0000FF;
--dark-hl-7: #CE9178;
--light-hl-8: #CD3131;
--dark-hl-8: #F44747;
--light-hl-9: #0000FF;
--dark-hl-9: #569CD6;
--light-hl-10: #0070C1;
--dark-hl-10: #4FC1FF;
--light-hl-11: #AF00DB;
--dark-hl-11: #C586C0;
--light-hl-12: #001080;
--dark-hl-12: #9CDCFE;
--light-hl-13: #000000;
--dark-hl-13: #C8C8C8;
--light-hl-14: #098658;
--dark-hl-14: #B5CEA8;
--light-hl-15: #008000;
--dark-hl-15: #6A9955;
--light-hl-16: #267F99;
--dark-hl-16: #4EC9B0;
--light-code-background: #FFFFFF;
--dark-code-background: #1E1E1E;
}

@media (prefers-color-scheme: light) { :root {
--hl-0: var(--light-hl-0);
--hl-1: var(--light-hl-1);
--hl-2: var(--light-hl-2);
--hl-3: var(--light-hl-3);
--hl-4: var(--light-hl-4);
--hl-5: var(--light-hl-5);
--hl-6: var(--light-hl-6);
--hl-7: var(--light-hl-7);
--hl-8: var(--light-hl-8);
--hl-9: var(--light-hl-9);
--hl-10: var(--light-hl-10);
--hl-11: var(--light-hl-11);
--hl-12: var(--light-hl-12);
--hl-13: var(--light-hl-13);
--hl-14: var(--light-hl-14);
--hl-15: var(--light-hl-15);
--hl-16: var(--light-hl-16);
--code-background: var(--light-code-background);
} }

@media (prefers-color-scheme: dark) { :root {
--hl-0: var(--dark-hl-0);
--hl-1: var(--dark-hl-1);
--hl-2: var(--dark-hl-2);
--hl-3: var(--dark-hl-3);
--hl-4: var(--dark-hl-4);
--hl-5: var(--dark-hl-5);
--hl-6: var(--dark-hl-6);
--hl-7: var(--dark-hl-7);
--hl-8: var(--dark-hl-8);
--hl-9: var(--dark-hl-9);
--hl-10: var(--dark-hl-10);
--hl-11: var(--dark-hl-11);
--hl-12: var(--dark-hl-12);
--hl-13: var(--dark-hl-13);
--hl-14: var(--dark-hl-14);
--hl-15: var(--dark-hl-15);
--hl-16: var(--dark-hl-16);
--code-background: var(--dark-code-background);
} }

:root[data-theme='light'] {
--hl-0: var(--light-hl-0);
--hl-1: var(--light-hl-1);
--hl-2: var(--light-hl-2);
--hl-3: var(--light-hl-3);
--hl-4: var(--light-hl-4);
--hl-5: var(--light-hl-5);
--hl-6: var(--light-hl-6);
--hl-7: var(--light-hl-7);
--hl-8: var(--light-hl-8);
--hl-9: var(--light-hl-9);
--hl-10: var(--light-hl-10);
--hl-11: var(--light-hl-11);
--hl-12: var(--light-hl-12);
--hl-13: var(--light-hl-13);
--hl-14: var(--light-hl-14);
--hl-15: var(--light-hl-15);
--hl-16: var(--light-hl-16);
--code-background: var(--light-code-background);
}

:root[data-theme='dark'] {
--hl-0: var(--dark-hl-0);
--hl-1: var(--dark-hl-1);
--hl-2: var(--dark-hl-2);
--hl-3: var(--dark-hl-3);
--hl-4: var(--dark-hl-4);
--hl-5: var(--dark-hl-5);
--hl-6: var(--dark-hl-6);
--hl-7: var(--dark-hl-7);
--hl-8: var(--dark-hl-8);
--hl-9: var(--dark-hl-9);
--hl-10: var(--dark-hl-10);
--hl-11: var(--dark-hl-11);
--hl-12: var(--dark-hl-12);
--hl-13: var(--dark-hl-13);
--hl-14: var(--dark-hl-14);
--hl-15: var(--dark-hl-15);
--hl-16: var(--dark-hl-16);
--code-background: var(--dark-code-background);
}

.hl-0 { color: var(--hl-0); }
.hl-1 { color: var(--hl-1); }
.hl-2 { color: var(--hl-2); }
.hl-3 { color: var(--hl-3); }
.hl-4 { color: var(--hl-4); }
.hl-5 { color: var(--hl-5); }
.hl-6 { color: var(--hl-6); }
.hl-7 { color: var(--hl-7); }
.hl-8 { color: var(--hl-8); }
.hl-9 { color: var(--hl-9); }
.hl-10 { color: var(--hl-10); }
.hl-11 { color: var(--hl-11); }
.hl-12 { color: var(--hl-12); }
.hl-13 { color: var(--hl-13); }
.hl-14 { color: var(--hl-14); }
.hl-15 { color: var(--hl-15); }
.hl-16 { color: var(--hl-16); }
pre, code { background: var(--code-background); }
58 changes: 58 additions & 0 deletions docs/@aptos-labs/ts-sdk-0.0.0/assets/main.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions docs/@aptos-labs/ts-sdk-0.0.0/assets/search.js

Large diffs are not rendered by default.

Loading

0 comments on commit 3a1129b

Please sign in to comment.