https://github.com/vemonet/nanopub-website
๐ A home website for the Nanopublication framework. Deprecated, check out https://github.com/Nanopublication/nanopub-website
https://github.com/vemonet/nanopub-website
docusaurus nanopublications website
Last synced: 9 months ago
JSON representation
๐ A home website for the Nanopublication framework. Deprecated, check out https://github.com/Nanopublication/nanopub-website
- Host: GitHub
- URL: https://github.com/vemonet/nanopub-website
- Owner: vemonet
- License: mit
- Created: 2022-11-28T13:04:44.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-03-03T15:57:06.000Z (over 2 years ago)
- Last Synced: 2025-10-14T16:06:03.993Z (9 months ago)
- Topics: docusaurus, nanopublications, website
- Language: TypeScript
- Homepage: https://nanopub.net
- Size: 1.56 MB
- Stars: 1
- Watchers: 1
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Nanopublication website
[](https://github.com/Nanopublication/nanopub-website/actions/workflows/deploy.yml)
Code for the website presenting the Nanopublication ecosystem, hosted at [nanopub.net](https://nanopub.net).
The website is automatically updated by a [GitHub Action](/actions) at each push to this repository `main` branch.
## โ๏ธ Contribute
Contributions are welcome!
### ๐ Edit documentation pages
Editing a documentation file is as easy as going to the markdown file for the page on GitHub: https://github.com/Nanopublication/nanopub-website/blob/main/docs/tools.md
* Edit a page by login with an account that has edit permissions.
* Otherwise fork the repository and modify the files you want. Pull requests are welcome!
If you are making substential changes we recommend you to clone the repository, and work locally (cf. below *Deployment* section to)
> We recommend using [Typora](https://typora.io/) to edit [markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet) files easily on your computer.
### ๐ Files locations
To edit the website content and configuration:
- Most website pages are markdown files in `src/pages/` and `docs/`
- New pages links can be easily added to the sidebar in `sidebars.json`
- The main parameters of the website can be found in `docusaurus.config.js`
- Static content, such as images, css, js or files to download, can be added in `static/`
- The main theme color can be changed in `src/css/customTheme.css`, we recommend to use [this tool to generate the color palette](https://docusaurus.io/docs/styling-layout#styling-your-site-with-infima).
## ๐งโ๐ป Deployment
To deploy the website locally and see your changes, go to your computer terminal, and clone the repository:
```bash
git clone https://github.com/Nanopublication/nanopub-website
cd nanopub-website
```
### ๐งถ Deploy with yarn
Install nodejs >=18, and yarn if not already done
* [Instructions to install `npm` and `NodeJS`](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm)
* [Instructions to install `yarn`](https://yarnpkg.com/getting-started/install)
To deploy the website locally with `yarn` and see your changes:
1. Install the dependencies:
```shell
yarn
```
2. Deploy the website on http://localhost:3000, it will reload automatically when you make changes to the code and markdown files:
```shell
yarn dev
```
### ๐ณ Deploy with docker
Alternatively you can deploy the website locally with docker and docker-compose (make sure they are installed):
```bash
docker-compose up
```
### ๐ Deploy in production
The website is available at https://nanopub.net, it is automatically updated and published to GitHub Pages by a [GitHub Action](https://github.com/Nanopublication/nanopub-website/blob/main/actions) at each push to the `main` branch of this repository.
## ๐ผ๏ธ The nanopub logo
The logo is defined as a vectorized SVG with 2 layers: logo and text.
If you don't know which editor to use to edit the logo SVG, we recommend to use the open source [Inkscape](https://inkscape.org) software
### Convert the SVG to PNG
You can easily export the SVG logo to PNG from the terminal with inkscape:
```bash
inkscape nanopublication_logo_inkscape.svg -o nanopub_logo.png -h 512
```
To export to PNG without the text:
```bash
inkscape nanopublication_logo_inkscape.svg -o nanopub_logo_notext.png --export-id=Logo_Layer --export-id-only -h 512
```
> If you have installed Inkscape with Flatpak, then replace `inkscape` with `flatpak run org.inkscape.Inkscape` in the commands above.
## โ๏ธ Markdown tips
### Add an announcement top bar
You can easily add a general announcement bar on the website if you want to pass some information to your users, like dates of maintenance
Open the file `docusaurus.config.js` and update the `announcementBar` variable.
You can comment the `announcementBar` code block when you want to remove the announcement bar.
### Info boxes
Colored box to highlight informations:
```markdown
:::note
Grey box
:::
:::tip You can specify an optional title
Green box
:::
:::info
Blue box
:::
:::caution
Orange bpx
:::
:::danger
Red box
:::
```
## ๐ Acknowledgments
Documentation website built with [Docusaurus](https://docusaurus.io/).