Skip to content

Commit

Permalink
initial commit website
Browse files Browse the repository at this point in the history
  • Loading branch information
Christoffer Åström committed May 23, 2018
1 parent 64bf73e commit d1e471a
Show file tree
Hide file tree
Showing 25 changed files with 3,668 additions and 6 deletions.
29 changes: 25 additions & 4 deletions .circleci/config.yml
@@ -1,6 +1,7 @@
version: 2

jobs:
build:
install:
docker:
- image: circleci/node:8.9.4
working_directory: ~/after-work.js
Expand All @@ -14,16 +15,27 @@ jobs:
- restore_cache:
key: dependency-cache-{{ checksum "package-lock.json" }}
- run:
name: Install dependencies
command:
npm install --quiet
name: Install dependencies
command: npm i
- run:
name: greenkeeper - Upload
command: greenkeeper-lockfile-upload
- save_cache:
key: dependency-cache-{{ checksum "package-lock.json" }}
paths:
- node_modules
- persist_to_workspace:
root: ~/after-work.js
paths:
- .

build:
docker:
- image: circleci/node:8.9.4
working_directory: ~/after-work.js
steps:
- attach_workspace:
at: ~/after-work.js
- run:
name: Run ESLint
command:
Expand All @@ -34,3 +46,12 @@ jobs:
npm run test:coveralls
- store_artifacts:
path: ./coverage

workflows:
version: 2
build-all:
jobs:
- install
- build:
requires:
- install
5 changes: 4 additions & 1 deletion docs/cdp.md
@@ -1,4 +1,7 @@
## CDP
---
id: cdp
title: Cdp
---

[**C**hrome **D**ebugging **P**rotocol](https://github.com/cyrus-and/chrome-remote-interface)

Expand Down
20 changes: 20 additions & 0 deletions docs/installation.md
@@ -0,0 +1,20 @@
---
id: installation
title: Installation
---

## Getting started

Make sure you meet [requirements](./requirements.md)

Install the package with:

```shell
npm i -D after-work.js
```

Now you have a couple of sub commands available

```shell
npx aw -h
```
5 changes: 4 additions & 1 deletion docs/node.md
@@ -1,4 +1,7 @@
## Node
---
id: node
title: Node
---

Run your test in a [Node](https://nodejs.org) environment with great developer workflow. Just start the runner with

Expand Down
5 changes: 5 additions & 0 deletions docs/protractor.md
@@ -1,3 +1,8 @@
---
id: protractor
title: Protractor
---

## [Protractor](https://github.com/angular/protractor) config
If you are using protractor for running test the configuration has to be according to the protractor configuration. A [base configuration](../src/protractor/config.js) will be provided by `after-work.js` but this can be extended as shown below.

Expand Down
15 changes: 15 additions & 0 deletions docs/requirements.md
@@ -0,0 +1,15 @@
---
id: requirements
title: Requirements
---

### Default runner (required)

* Node.js >= 8.9.4

### Context dependent browser environment (optional)

* Running tests with Chrome Debugging Protocol: Chrome > 61
* Running tests with webdriver protocol: protractor 5.x + browser(s)
* Running tests with High-level Chrome Node API - experimental: Recent Chromium

7 changes: 7 additions & 0 deletions website/.gitignore
@@ -0,0 +1,7 @@
node_modules
.DS_Store
translated_docs
build

i18n/*
!i18n/en.json
9 changes: 9 additions & 0 deletions website/README.md
@@ -0,0 +1,9 @@
# after-work.js website

The website is generated using [docusaurus](https://docusaurus.io/).

The documentation itself is located in [../docs](../docs).

## Using Docusaurus

Run `npm start` to start a server which will host the website at `localhost:3000`.
60 changes: 60 additions & 0 deletions website/core/Footer.js
@@ -0,0 +1,60 @@
const React = require('react');

class Footer extends React.Component {
docUrl(doc, language) {
const baseUrl = this.props.config.baseUrl;
return baseUrl + 'docs/' + doc;
// return baseUrl + 'docs/' + (language ? language + '/' : '') + doc;
}

pageUrl(doc, language) {
const baseUrl = this.props.config.baseUrl;
return baseUrl + doc;
// return baseUrl + (language ? language + '/' : '') + doc;
}

render() {
const currentYear = new Date().getFullYear();
return (
<footer className="nav-footer" id="footer">
<section className="sitemap">
<div>
<h5>Docs</h5>
<a href={this.docUrl('installation.html', this.props.language)}>
Getting Started
</a>
<a href={this.pageUrl('examples.html', this.props.language)}>
Examples
</a>
</div>
<div>
<h5>Links</h5>
<a href="http://qlikbranch-slack-invite.herokuapp.com/">
<i className="fa fa-slack"></i> Slack
</a>
<a href="https://github.com/qlik-oss/after-work.js">
<i className="fa fa-github"></i> GitHub
</a>
</div>
</section>

<a
href="https://github.com/qlik-oss/"
target="_blank"
className="qlikOpenSource">
<img
src={this.props.config.baseUrl + 'img/QlikLogo-White.png'}
alt="Qlik Open Source"
width="170"
height="45"
/>
</a>
<section className="copyright">
Copyright &copy; {currentYear} QlikTech International AB.
</section>
</footer>
);
}
}

module.exports = Footer;
23 changes: 23 additions & 0 deletions website/i18n/en.json
@@ -0,0 +1,23 @@
{
"_comment": "This file is auto-generated by write-translations.js",
"localized-strings": {
"next": "Next",
"previous": "Previous",
"tagline": "Testing, made simple",
"cdp": "Cdp",
"installation": "Installation",
"node": "Node",
"protractor": "Protractor",
"requirements": "Requirements",
"strategy": "strategy",
"Docs": "Docs",
"": "",
"Getting started": "Getting started",
"Commands": "Commands"
},
"pages-strings": {
"Help Translate|recruit community translators for your project": "Help Translate",
"Edit this Doc|recruitment message asking to edit the doc source": "Edit",
"Translate this Doc|recruitment message asking to translate the docs": "Translate"
}
}

0 comments on commit d1e471a

Please sign in to comment.