Skip to content

Commit

Permalink
drop da base 🍾
Browse files Browse the repository at this point in the history
  • Loading branch information
kremalicious committed Nov 7, 2018
1 parent 689334f commit d401178
Show file tree
Hide file tree
Showing 23 changed files with 940 additions and 3 deletions.
9 changes: 9 additions & 0 deletions .editorconfig
@@ -0,0 +1,9 @@
root = true

[*]
charset = utf-8
indent_size = 4
end_of_line = lf
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
14 changes: 14 additions & 0 deletions .eslintrc
@@ -0,0 +1,14 @@
{
"parser": "babel-eslint",
"extends": [
"oceanprotocol",
"oceanprotocol/react",
"plugin:prettier/recommended",
"prettier/react",
"prettier/standard"
],
"plugins": ["prettier"],
"rules": {
"prettier/prettier": "error"
}
}
7 changes: 7 additions & 0 deletions .gitignore
@@ -0,0 +1,7 @@
node_modules
package-lock.json
yarn.lock
yarn-error.log
.cache
/public
.DS_Store
5 changes: 5 additions & 0 deletions .prettierrc
@@ -0,0 +1,5 @@
{
"semi": false,
"singleQuote": true,
"trailingComma": "none"
}
15 changes: 15 additions & 0 deletions .travis.yml
@@ -0,0 +1,15 @@
language: node_js
node_js: node

# will run `npm install` automatically here

script:
- npm test
- npm run build

notifications:
email: false

cache:
directories:
- node_modules
31 changes: 28 additions & 3 deletions README.md
Expand Up @@ -4,6 +4,11 @@

> One site to rule all docs.
[![Build Status](https://travis-ci.com/oceanprotocol/docs.svg?branch=master)](https://travis-ci.com/oceanprotocol/docs)
[![js oceanprotocol](https://img.shields.io/badge/js-oceanprotocol-7b1173.svg)](https://github.com/oceanprotocol/eslint-config-oceanprotocol)
[![code style: prettier](https://img.shields.io/badge/code_style-prettier-7b1173.svg?style=flat-square)](https://github.com/prettier/prettier)
[![Greenkeeper badge](https://badges.greenkeeper.io/oceanprotocol/docs.svg)](https://greenkeeper.io/)

- [Content](#content)
- [Editing docs](#editing-docs)
- [Adding docs](#adding-docs)
Expand All @@ -15,21 +20,41 @@

...documentation concept...

The documentation is split in multiple parts whose content lives in this repo:

- Core concepts: high-level explanation of concepts, assumptions, and components
- Setup: getting started for various stakeholders and use cases
- Tutorials: detailed tutorials

Additionally, these docs live in their respective repos and are pulled into this site on build time:

- API reference
- Component docs

### Editing docs

### Adding docs

## Development

The site is a React app built with [Gatsby](https://www.gatsbyjs.org), pulling its content from various sources.

To start development, clone this repo, install all dependencies, and start the development server:

```bash
git clone git@github.com:oceanprotocol/docs.git
cd docs/

npm i
npm start
```

This will start a hot-reloading local server exposed under [localhost:8000](http://localhost:8000).

## Authors

- Troy McConaghy ([@ttmc](https://github.com/ttmc)) - [Ocean Protocol](https://oceanprotocol.com)
- Matthias Kretschmann ([@kremalicious](https://github.com/kremalicious)) - [Ocean Protocol](https://oceanprotocol.com)
- Troy McConaghy ([@ttmc](https://github.com/ttmc)) - [Ocean Protocol](https://oceanprotocol.com)
- Matthias Kretschmann ([@kremalicious](https://github.com/kremalicious)) - [Ocean Protocol](https://oceanprotocol.com)

## License

Expand All @@ -47,4 +72,4 @@ distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
```
```
3 changes: 3 additions & 0 deletions content/coreconcepts/components.md
@@ -0,0 +1,3 @@
---
title: The components of Ocean Protocol
---
3 changes: 3 additions & 0 deletions content/setup/marketplace.md
@@ -0,0 +1,3 @@
---
title: Set up a data marketplace
---
5 changes: 5 additions & 0 deletions content/tutorials/jupyter.md
@@ -0,0 +1,5 @@
---
title: Use Jupyter notebooks to interact with the Ocean network
---

How to use Mantaray?
7 changes: 7 additions & 0 deletions gatsby-browser.js
@@ -0,0 +1,7 @@
/**
* Implement Gatsby's Browser APIs in this file.
*
* See: https://www.gatsbyjs.org/docs/browser-apis/
*/

// You can delete this file if you're not using it
25 changes: 25 additions & 0 deletions gatsby-config.js
@@ -0,0 +1,25 @@
module.exports = {
siteMetadata: {
title: 'Ocean Protocol Docs'
},
plugins: [
{
resolve: 'gatsby-source-filesystem',
options: {
name: 'images',
path: `${__dirname}/src/images`
}
},
{
resolve: 'gatsby-source-filesystem',
options: {
name: 'content',
path: `${__dirname}/content`
}
},
'gatsby-plugin-react-helmet',
'gatsby-transformer-sharp',
'gatsby-plugin-sharp'
// 'gatsby-plugin-offline',
]
}
7 changes: 7 additions & 0 deletions gatsby-node.js
@@ -0,0 +1,7 @@
/**
* Implement Gatsby's Node APIs in this file.
*
* See: https://www.gatsbyjs.org/docs/node-apis/
*/

// You can delete this file if you're not using it
7 changes: 7 additions & 0 deletions gatsby-ssr.js
@@ -0,0 +1,7 @@
/**
* Implement Gatsby's SSR (Server Side Rendering) APIs in this file.
*
* See: https://www.gatsbyjs.org/docs/ssr-apis/
*/

// You can delete this file if you're not using it
44 changes: 44 additions & 0 deletions package.json
@@ -0,0 +1,44 @@
{
"name": "@oceanprotocol/docs",
"description": "One site to rule all docs",
"version": "0.0.1",
"author": "Ocean Protocol <devops@oceanprotocol.com>",
"dependencies": {
"gatsby": "^2.0.19",
"gatsby-image": "^2.0.15",
"gatsby-plugin-manifest": "^2.0.5",
"gatsby-plugin-offline": "^2.0.11",
"gatsby-plugin-react-helmet": "^3.0.0",
"gatsby-plugin-sharp": "^2.0.7",
"gatsby-source-filesystem": "^2.0.4",
"gatsby-transformer-sharp": "^2.1.4",
"react": "^16.5.1",
"react-dom": "^16.5.1",
"react-helmet": "^5.2.0"
},
"license": "Apache-2.0",
"scripts": {
"build": "gatsby build",
"start": "gatsby develop",
"ssr": "npm run build && serve -s public/",
"format": "prettier --write 'src/**/*.{js,jsx}'",
"test": "eslint --ext .js,.jsx ."
},
"devDependencies": {
"eslint": "^5.8.0",
"eslint-config-oceanprotocol": "^1.3.0",
"eslint-config-prettier": "^3.1.0",
"eslint-plugin-prettier": "^3.0.0",
"prettier": "^1.14.2"
},
"repository": {
"type": "git",
"url": "https://github.com/oceanprotocol/docs"
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
]
}
17 changes: 17 additions & 0 deletions src/components/header.js
@@ -0,0 +1,17 @@
import React from 'react'
import PropTypes from 'prop-types'
import { Link } from 'gatsby'

const Header = ({ siteTitle }) => (
<header>
<h1 style={{ margin: 0 }}>
<Link to="/">{siteTitle}</Link>
</h1>
</header>
)

Header.propTypes = {
siteTitle: PropTypes.string
}

export default Header
36 changes: 36 additions & 0 deletions src/components/image.js
@@ -0,0 +1,36 @@
import React from 'react'
import { StaticQuery, graphql } from 'gatsby'
import Img from 'gatsby-image'

/*
* This component is built using `gatsby-image` to automatically serve optimized
* images with lazy loading and reduced file sizes. The image is loaded using a
* `StaticQuery`, which allows us to load the image from directly within this
* component, rather than having to pass the image data down from pages.
*
* For more information, see the docs:
* - `gatsby-image`: https://gatsby.app/gatsby-image
* - `StaticQuery`: https://gatsby.app/staticquery
*/

const Image = () => (
<StaticQuery
query={graphql`
query {
placeholderImage: file(
relativePath: { eq: "gatsby-astronaut.png" }
) {
childImageSharp {
fluid(maxWidth: 300) {
...GatsbyImageSharpFluid
}
}
}
}
`}
render={data => (
<Img fluid={data.placeholderImage.childImageSharp.fluid} />
)}
/>
)
export default Image

0 comments on commit d401178

Please sign in to comment.