This repository contains the website and documentation for
Empirica. It is hosted at
https://empirica.ly. The website source is on the source
branch, and the
generated/deployed website is on master (because that's what Github Pages wants
to host the website).
We are very thankful for contributions to our documentation, even if just fixing typos. We do require that you follow the standard Github process with fork + pull request. If you are not familiar with it, check out this short guide.
Docs have move to https://docs.empirica.ly/ using GitBook. Docs in this repo are no longer updated. If you wish to help
When you make changes locally, you will want to test them before pushing them with a pull request. In this section, we will install the necessary components to run a local version of the website.
You’ll need to have Node.js >= 8 on your local development machine. If you don't already have Node.js 8+ setup, we recommend you use the official installer: https://nodejs.org/en/download/.
- Make sure all the dependencies for the website are installed:
# The code building the website is all in the website dir
$ cd website
# Install dependencies
$ npm install
- Run your dev server:
# Start the site
$ npm run start
This should open a new browser window with the app, you're ready to edit.
The file structure should look something like this
empiricaly.github.io/
docs/
api.md
usage.md
...
website/
blog/
2018-12-11-something-something.md
2020-10-24-the-future.md
core/
node_modules/
pages/
static/
css/
img/
package.json
sidebar.json
siteConfig.js
Edit docs by navigating to docs/
and editing the corresponding document:
docs/doc-to-be-edited.md
---
id: page-needs-edit
title: This Doc Needs To Be Edited
---
Edit me...
For more information about docs, click here
Edit blog posts by navigating to website/blog
and editing the corresponding
post:
website/blog/post-to-be-edited.md
---
id: post-needs-edit
title: This Blog Post Needs To Be Edited
---
Edit me...
For more information about blog posts, click here
- Create the doc as a new markdown file in
/docs
, exampledocs/newly-created-doc.md
:
---
id: newly-created-doc
title: This Doc Needs To Be Edited
---
My new content here..
- Refer to that doc's ID in an existing sidebar in
website/sidebar.json
:
// Add newly-created-doc to the Getting Started category of docs
{
"docs": {
"Getting Started": [
"quick-start",
"newly-created-doc" // new doc here
],
...
},
...
}
For more information about adding new docs, click here
Create the blog post with the format YYYY-MM-DD-My-Blog-Post-Title.md
in
website/blog
:
website/blog/2018-05-21-New-Blog-Post.md
---
author: Frank Li
authorURL: https://twitter.com/foobarbaz
authorFBID: 503283835
title: New Blog Post
---
Lorem Ipsum...
For more information about blog posts, click here
This website was created with Docusaurus. Full documentation can be found on the website.