Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
7c2e6fc
Migrate to Vuepress (#46)
dennisreimann Jul 7, 2021
d84e1a6
Upgrade dependencies
dennisreimann Jul 9, 2021
b5010d6
Decrease sidebar depth
dennisreimann Jul 9, 2021
404842f
Fix logo in Firefox
dennisreimann Jul 9, 2021
854baf4
Set selection styles
dennisreimann Jul 9, 2021
72a071f
Minor style fixes
dennisreimann Jul 9, 2021
572a4e0
Attempt to fix font issue
dennisreimann Jul 9, 2021
b86b9d9
Import Manrope from Google Fonts
dennisreimann Jul 9, 2021
35d3011
Don't show headings in sidebar
dennisreimann Jul 9, 2021
9884a11
Add blog
dennisreimann Jul 12, 2021
2b900b6
Update blog sidebar
dennisreimann Jul 19, 2021
a1b26fe
Add pitch points to homepage
dennisreimann Jul 19, 2021
53d4df5
Homepage style tweaks
dennisreimann Jul 19, 2021
a1c9244
Fix blog article sidebar
dennisreimann Jul 19, 2021
ea5ddb1
Add card image
dennisreimann Jul 19, 2021
6a37777
Improve 404 page
dennisreimann Jul 19, 2021
e590502
Component improvements
dennisreimann Jul 19, 2021
a72ebe2
Add footer
dennisreimann Jul 27, 2021
c91c886
Add features to homepage
dennisreimann Jul 27, 2021
fe5a124
Update feature list on homepage
dennisreimann Jul 27, 2021
f62cced
Fix after rebase
dennisreimann Aug 4, 2021
fc0af88
Fix theme switch icon size on iOS
dennisreimann Aug 4, 2021
5df43d5
Stylus fixes
dennisreimann Aug 4, 2021
8464a7e
Upgrade dependencies
dennisreimann Aug 3, 2021
37fe2f1
Update theme colors
dennisreimann Aug 3, 2021
110f475
Restructure sidebar nav for docs pages
Aug 3, 2021
5113b8e
Create different sidebar for tutorial page, break some docs up into n…
Aug 4, 2021
eede36f
Styling updates
dennisreimann Aug 4, 2021
d65340a
Fix tab behaviour
dennisreimann Aug 9, 2021
2a5fc28
Fix note
dennisreimann Aug 9, 2021
8a4d35f
Updates features section copy
Aug 10, 2021
e5c9f82
Remove overview page from footer
Aug 10, 2021
b3b90a7
Add copy for high performance & compact feature
Aug 11, 2021
42380e9
Include Electrum explicitly
Aug 11, 2021
34fb273
Remove doc deep links temporarily
Aug 11, 2021
ba6766f
Include IoT and PoS devices
Aug 12, 2021
0e2cf9b
Shorten copy
Aug 12, 2021
1811668
Decrease sidebar width
dennisreimann Aug 19, 2021
c114294
Update logo
dennisreimann Aug 19, 2021
48d8f4c
Update colors and logo
dennisreimann Aug 24, 2021
d136167
Update ignore file
dennisreimann Sep 2, 2021
2e749b7
Add footnote plugin
dennisreimann Sep 2, 2021
39f6780
Improve iframe integration
dennisreimann Sep 2, 2021
2f52d03
Remove BDK blog posts
dennisreimann Sep 2, 2021
0f97321
Extract theme
dennisreimann Sep 7, 2021
bb0d371
Fix body bg color
dennisreimann Sep 7, 2021
9ca6012
Update theme and variables
dennisreimann Sep 7, 2021
2ac2cb9
Upgrade dependencies
dennisreimann Sep 10, 2021
4b87697
Update theme
dennisreimann Sep 21, 2021
4f486c1
Update tagline
Sep 28, 2021
edc6643
Fixes broken links
Oct 4, 2021
22b5794
Blog coming soon
Oct 4, 2021
ea8de0b
Update footer link
Oct 4, 2021
e4f08b0
Update code and note colors
dennisreimann Sep 29, 2021
330da18
Fix links
dennisreimann Oct 6, 2021
a1eb357
Add SEO config
dennisreimann Oct 6, 2021
829f26f
Update favicon
dennisreimann Oct 6, 2021
b4cb605
Copy updates
Oct 7, 2021
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
46 changes: 46 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Build

on:
# Run the build for pushes and pull requests targeting main
push:
branches:
- main
pull_request:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16]

steps:
# Checkout doc repo and its dependencies
- name: Checkout
uses: actions/checkout@v2
# Setup Node
- name: Setup (Node.js ${{ matrix.node-version }})
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
# Install and build
- name: Install
run: npm ci
- name: Build
run: npm run build
# Deploy, limited to the main branch
- name: Deploy
if: success() && github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v3
with:
publish_dir: ./docs/.vuepress/dist
github_token: ${{ secrets.GITHUB_TOKEN }}
cname: lightningdevkit.org
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
# Run linkcheck, propagate linkcheck failure through grep pipe
- name: Linkcheck
run: set -o pipefail; npm run linkcheck 2>/dev/null | grep "Getting links from\|BROKEN"
continue-on-error: true
8 changes: 1 addition & 7 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,7 @@
/node_modules

# Production
/build

# Generated files
.docusaurus
.cache-loader
/docs/.vuepress/dist

# Misc
.DS_Store
Expand All @@ -16,5 +12,3 @@
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
82 changes: 65 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,81 @@
# Website
# Lightning Dev Kit Documentation

This website is built using [Docusaurus 2](https://v2.docusaurus.io/), a modern static website generator.
[![Build Status](https://github.com/lightningdevkit/lightningdevkit.org/workflows/Build/badge.svg)](https://github.com/lightningdevkit/lightningdevkit.org/actions?query=workflow%3A%22Build%22)

## Installation
### Build the Documentation Locally

```console
yarn install
In order to build the website locally, you'll need [Node.js](https://nodejs.org/) >= 14.16 (or basically the latest LTS version).

The setup is straight forward:

```bash
# Install dependencies
npm install

# Serve locally (by default on port 8080)
npm start
```

## Local Development
### Text Highlights

There are [three types of text highlights](https://vuepress.vuejs.org/guide/markdown.html#custom-containers) that can be used to display different colored boxes.

```console
yarn start
A green box displaying a friendly tip:

```md
:::tip
foo
:::
```

This command starts a local development server and open up a browser window. Most changes are reflected live without having to restart the server.
A yellow box with a cautious warning:

```md
:::warning
foo
:::
```

## Build
A red box with a clear danger, you can also add a title `foo` to any container:

```console
yarn build
```md
:::danger foo
bar
:::
```

This command generates static content into the `build` directory and can be served using any static contents hosting service.
### SEO improvements

We are using the [Vuepress SEO plugin](https://www.npmjs.com/package/vuepress-plugin-seo) to add relevant meta tags to the site and individual pages.

## Deployment
To improve the meta attributes of a specific page, you can add them as YAML frontmatter like this: (see the WooCommerce page for an example)

```console
GIT_USER=<Your GitHub username> USE_SSH=true yarn deploy
```text
---
description: How to integrate LDK
tags:
- WooCommerce
- WordPress
- Plugin
- eCommerce
---
# LDK integration

This document explains how to **integrate LDK into your stack**.
```

If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
### Embedding YouTube videos

To add a YouTube video with a preview, you can so so by linking to it like this:

```md
[![IMAGE ALT TEXT HERE](https://img.youtube.com/vi/YOUTUBE_VIDEO_ID_HERE/mqdefault.jpg)](https://www.youtube.com/watch?v=YOUTUBE_VIDEO_ID_HERE)
```

Note that the link item need to be a preview image (either from YouTube or a custom one) to result in an embedded video.

### Check for broken links

The GitHub Actions pipeline checks for broken links after deploying the production site.
You can also run the link check locally using `npm run linkcheck:local`.
The dev server needs to be running alongside for this to work.
3 changes: 0 additions & 3 deletions babel.config.js

This file was deleted.

154 changes: 154 additions & 0 deletions docs/.vuepress/config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
const { resolve } = require('path')
const themeConfig = require('squarecrypto-vuepress-devkit-theme/config')

const title = 'Lightning Dev Kit Documentation'
const baseUrl = 'https://lightningdevkit.org'
const githubUrl = 'https://github.com/lightningdevkit'
const slackUrl = 'https://join.slack.com/t/lightningdevkit/shared_invite/zt-tte36cb7-r5f41MDn3ObFtDu~N9dCrQ'
const themeColor = '#ffffff'

const docsSidebar = [
{
title: 'Documentation',
collapsable: false,
children: [
'/getting-started',
{
title: 'Basic Features',
collapsable: true,
children: [
['/basic-features/key_management', 'Key management'],
['/basic-features/blockchain_data', 'Blockchain data'],
['/basic-features/connecting_peers', 'Connecting peers'],
['/basic-features/managing_channels', 'Managing channels'],
['/basic-features/sending_payments', 'Sending payments'],
['/basic-features/receiving_payments', 'Receiving Payments']
]
},
'/examples',
'/batteries',
'/architecture',
'/use_cases',
]
},
{
title: 'API Reference',
collapsable: false,
children: [
['https://docs.rs/lightning/0.0.99/lightning/', 'Rust'],
['https://github.com/arik-so/SwiftLightning/tree/master/Documentation', 'Swift']
],
}
]

const tutorialSidebar = [
{
title: 'Tutorials',
collapsable: false,
children: [
'/tutorials/build_a_node_in_java',
'/tutorials/build_a_node_in_rust'
],
}
]

const blogSidebar = [
{
title: 'Blog',
collapsable: false,
children: [
['/blog/', 'Articles'],
['/blog/tags/', 'Tags'],
['/blog/author/', 'Authors']
]
}
]

module.exports = {
title,
description: 'LDK is a flexible lightning implementation with supporting batteries (or modules).',
theme: resolve(__dirname, '../../node_modules/squarecrypto-vuepress-devkit-theme'),
...themeConfig({
baseUrl,
title,
themeColor,
tags: ['Bitcoin', 'Lightning', 'LDK', 'Lightning Dev Kit', 'Documentation']
}),
themeConfig: {
domain: baseUrl,
logo: '/img/logo.svg',
displayAllHeaders: false,
repo: 'lightningdevkit/lightningdevkit.org',
docsDir: 'docs',
editLinks: true,
sidebarDepth: 0,
nav: [
{
text: 'Docs',
link: '/getting-started/'
},
{
text: 'Tutorials',
link: '/tutorials/build_a_node_in_java'
},
{
text: 'Blog',
link: '/blog/'
},
{
text: 'Slack',
link: slackUrl,
rel: 'noopener noreferrer'
},
{
text: 'GitHub',
link: githubUrl,
rel: 'noopener noreferrer'
}
],
sidebar: {
'/_blog/': blogSidebar,
'/blog/': blogSidebar,
'/tutorials/': tutorialSidebar,
'/': docsSidebar,
},
footer: {
links: [
{
title: 'Docs',
children: [
{
text: 'Getting Started',
link: '/getting-started/'
}
]
},
{
title: 'Community',
children: [
{
text: 'Slack',
link: slackUrl,
rel: 'noopener noreferrer'
},
{
text: 'GitHub',
link: githubUrl,
rel: 'noopener noreferrer'
}
]
},
{
title: 'More',
children: [
{
text: 'Blog',
link: '/blog/'
}
]
}
],
copyright: 'Copyright © 2021 LDK Developers'
}
}
}
9 changes: 9 additions & 0 deletions docs/.vuepress/public/browserconfig.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/img/favicon/mstile-150x150.png"/>
<TileColor>#ffffff</TileColor>
</tile>
</msapplication>
</browserconfig>
Binary file added docs/.vuepress/public/card.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 21 additions & 0 deletions docs/.vuepress/public/css/variables.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
:root {
--docs-primary-light: #0F31F7;
--docs-primary-dark: #76F3CD;
--docs-dark: #000628;

--docs-note-text: var(--docs-white) !important;
--docs-code-bg: #E6EAFE;
--docs-pre-bg: #020A36;
}

:root[data-theme="dark"] {
--docs-code-bg: #06463C;
--docs-pre-bg: #002547;
}

@media (prefers-color-scheme: dark) {
:root:not([data-theme]) {
--docs-code-bg: #06463C;
--docs-pre-bg: #002547;
}
}
Binary file added docs/.vuepress/public/favicon.ico
Binary file not shown.
Binary file not shown.
1 change: 1 addition & 0 deletions docs/.vuepress/public/img/border.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/.vuepress/public/img/favicon/mstile-70x70.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 18 additions & 0 deletions docs/.vuepress/public/img/illustrations.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions docs/.vuepress/public/img/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading