Skip to content

Commit cbb0cc0

Browse files
Remove reducer code and redux packages.
1 parent 8d81e24 commit cbb0cc0

File tree

11 files changed

+11749
-211
lines changed

11 files changed

+11749
-211
lines changed

package-lock.json

Lines changed: 11736 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
{
2-
"name": "example-pawjs-tailwind",
2+
"name": "example-pawjs-semantic-ui",
33
"version": "1.0.0",
4-
"description": "Example on using Tailwind CSS with PawJS",
4+
"description": "Example on using Semantic-ui CSS with PawJS",
55
"scripts": {
66
"start": "pawjs --env=development start",
77
"build": "pawjs --env=production --config=prod.pawconfig.json build"
88
},
99
"repository": {
1010
"type": "git",
11-
"url": "git+https://github.com/Atyantik/example-pawjs-tailwind.git"
11+
"url": "git+https://github.com/Atyantik/example-pawjs-semantic-ui.git"
1212
},
1313
"author": {
1414
"name": "Atyantik Technologies",
@@ -28,11 +28,15 @@
2828
}
2929
],
3030
"devDependencies": {
31-
"@pawjs/pawjs": "^2.1.10"
31+
"@pawjs/pawjs": "^2.2.3"
3232
},
3333
"license": "MIT",
3434
"bugs": {
3535
"url": "https://github.com/Atyantik/example-pawjs-tailwind/issues"
3636
},
37-
"homepage": "https://github.com/Atyantik/example-pawjs-tailwind#readme"
37+
"homepage": "https://github.com/Atyantik/example-pawjs-tailwind#readme",
38+
"dependencies": {
39+
"semantic-ui-css": "^2.4.1",
40+
"semantic-ui-react": "^0.82.5"
41+
}
3842
}

src/app/components/ReducerPage/actions.js

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

src/app/components/ReducerPage/reducer-page.js

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

src/app/components/ReducerPage/reducer.js

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

src/app/components/home.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,10 @@ const Home = () => (
4545
/>
4646
<Button className="ui animated fade button primary huge" to="/reducer">
4747
<div className="visible content">
48-
Checkout Redux
48+
Call to action
4949
</div>
5050
<div className="hidden content">
51-
Go to the Link
51+
Click here
5252
<Icon name="right arrow" />
5353
</div>
5454
</Button>
@@ -58,7 +58,6 @@ const Home = () => (
5858
<Grid container stackable verticalAlign="middle">
5959
<Grid.Row>
6060
<Grid.Column width={8}>
61-
<Link to="/"><h2>Reducer Demo</h2></Link>
6261
<Header as="h3" style={{ fontSize: "2em" }}>
6362
We Help Companies and Companions
6463
</Header>

src/app/reducers.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/client.js

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,3 @@
11
import "semantic-ui-css/semantic.css";
2-
import ReduxClient from "@pawjs/redux/client";
3-
import * as AppReducers from "./app/reducers";
42

5-
const AppInitialState = {
6-
counter: {
7-
count: 5,
8-
},
9-
};
10-
export default class Client {
11-
constructor({ addPlugin }) {
12-
const reduxClient = new ReduxClient({ addPlugin });
13-
reduxClient.setReducers(AppReducers);
14-
// If you want to add some redux middleware
15-
// reduxClient.addMiddleware(AnyMiddleware);
16-
17-
// If you want to add some redux enahncers
18-
// reduxClient.addEnhancer(SomeEnhancer);
19-
addPlugin(reduxClient);
20-
21-
// ...
22-
}
23-
24-
apply(clientHandler) {
25-
clientHandler
26-
.hooks
27-
.reduxInitialState
28-
.tapPromise("ReduxInitialState", async ({ getInitialState, setInitialState }) => {
29-
const initialState = Object.assign({}, getInitialState(), AppInitialState);
30-
// You can also wait for something async to happen
31-
// await fetch("/api/counter/details") and add it to the initial state if needed
32-
setInitialState(initialState);
33-
});
34-
}
35-
}
3+
export default class Client {}

src/pages/reducer.js

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

src/routes.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
import HomeRoute from "./pages/home";
2-
import ReducerRoute from "./pages/reducer";
32
export default class Routes {
43
apply(routeHandler) {
54
const routes = [
65
...HomeRoute,
7-
...ReducerRoute,
86
];
97

108
routeHandler.hooks.initRoutes.tapPromise("AppRoutes", async () => {

0 commit comments

Comments
 (0)