Skip to content

Commit 04d40fc

Browse files
authored
Merge pull request #13 from devrnt/docs/playground
Docs/playground
2 parents 262064b + f2224df commit 04d40fc

32 files changed

+775
-176
lines changed

.github/workflows/deploy.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Deploy to Github Pages
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
deploy:
10+
runs-on: ubuntu-18.04
11+
steps:
12+
- uses: actions/checkout@v2
13+
14+
- name: Setup Node
15+
uses: actions/setup-node@v1
16+
with:
17+
node-version: '14.x'
18+
19+
- name: Get yarn cache
20+
id: yarn-cache
21+
run: echo "::set-output name=dir::$(yarn cache dir)"
22+
23+
- name: Cache dependencies
24+
uses: actions/cache@v1
25+
with:
26+
path: ${{ steps.yarn-cache.outputs.dir }}
27+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
28+
restore-keys: |
29+
${{ runner.os }}-yarn-
30+
31+
- run: yarn install --frozen-lockfile
32+
- run: yarn build
33+
- run: yarn build:playground
34+
35+
- name: Deploy
36+
uses: peaceiris/actions-gh-pages@v3
37+
with:
38+
github_token: ${{ secrets.GITHUB_TOKEN }}
39+
publish_dir: ./playground/dist

.vscode/settings.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"typescript.tsdk": "node_modules\\typescript\\lib"
3+
}

example/components/footer.tsx

Lines changed: 0 additions & 34 deletions
This file was deleted.

example/components/step.tsx

Lines changed: 0 additions & 34 deletions
This file was deleted.

example/index.html

Lines changed: 0 additions & 14 deletions
This file was deleted.

example/index.tsx

Lines changed: 0 additions & 49 deletions
This file was deleted.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
"scripts": {
1414
"start": "tsdx watch",
1515
"build": "tsdx build",
16+
"build:playground": "yarn --cwd ./playground install && yarn --cwd ./playground build",
1617
"test": "tsdx test --passWithNoTests",
1718
"test:watch": "tsdx test --watch",
1819
"test:coverage": "tsdx test --coverage",
File renamed without changes.

playground/app.tsx

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
import * as React from 'react';
2+
3+
import { WizardModule } from './modules';
4+
import { Page, Style } from './modules/common';
5+
6+
const App = () => {
7+
return (
8+
<>
9+
<Style />
10+
<Page
11+
title="react-use-wizard"
12+
description="Playground to showcase the functionalities of react-use-wizard"
13+
>
14+
<WizardModule />
15+
</Page>
16+
</>
17+
);
18+
};
19+
20+
export default App;
Lines changed: 3 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)