You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: readme.md
+7-7
Original file line number
Diff line number
Diff line change
@@ -27,15 +27,15 @@ This obviously is a bit of a technology playground resulting in some adventurous
27
27
28
28
### Server
29
29
30
-
All services are implemented with HapiJs and are kept simple as in that authentication should either be handled by JWTs or an service at some point.
30
+
All services are implemented with HapiJs and are kept simple as in that authentication should either be handled by JWTs or a service at some point.
31
31
The whole GraphQL functionality is implemented using the `graphql-server-hapi` from the lovely people at Apollo GraphQL.
32
32
33
33
### Testing
34
34
35
-
The testing library used is `ava` as it encourages parallel test runs forcing a non existent dependencies between suites. Moreover, it can be used for server side units/API testing as much as it can be used for UI snapshot testing.
35
+
The testing library used is `ava` as it encourages parallel test runs, enforcing no dependencies between suites. Moreover, it can be used for server side units/API testing as much as it can be used for UI snapshot testing.
36
36
37
37
- Units with logic such as fixtures are tested as units
38
-
- API and resource are testing as a component (route all down the stack until fixtures)
38
+
- API and resource are tested as a component (route all down the stack until fixtures)
39
39
40
40
The local `envs` module encapsulates the `process.env.NODE_ENV` set in the `package.json` to reduce string dependencies and allow for easy switching in e.g. the models.
41
41
@@ -49,11 +49,11 @@ The `debug`-package is used within services giving more insight whenever debug s
49
49
50
50
### Dependencies
51
51
52
-
`yarn` is used by default when installing packages locally and on `TravisCI`. All just however work with `npm`.
52
+
`yarn` is used by default when installing packages locally and on `TravisCI`. All however just works with `npm`.
53
53
54
54
## Services
55
55
56
-
Services all follow the same patterns and are implemented with Hapi as a framework. Each `route` within `routes` contains a fixture a module for each HTTP method and an `index`-file which exports an `attachRoute`-fn which is invoked with the server by the overall routes `index`. The routes `index` itself exports an `attachRoutes` which is imported in `server.js`.
56
+
All services follow the same patterns and are implemented with Hapi as a framework. Each `route` within `routes` contains a fixture, a module for each HTTP method and an `index`-file which exports an `attachRoute`-fn which is invoked with the server by the overall routes `index`. The routes `index` itself exports an `attachRoutes` which is imported in `server.js`.
57
57
58
58
In general terms:
59
59
@@ -67,7 +67,7 @@ Each route then has a model for its resource which runs in "fixture-mode" or "da
67
67
68
68
Outward facing GraphQL API aggregating data from all behind services.
69
69
70
-
In development runs on [:3000](http://localhost:3000). The GrapiQL route is only available under development [:3000/graphiql](http://localhost:3000/graphiql)
70
+
In development runs on [:3000](http://localhost:3000). The GraphiQL route is only available under development [:3000/graphiql](http://localhost:3000/graphiql)
71
71
72
72
The GraphQL schema is modularised into [`/types`](graphql/types) and [`/resolvers`](graphql/resolvers) to keep it not too bloated.
73
73
@@ -116,6 +116,6 @@ All services expose a `GET /health` and a `GET /metrics` resource. The first can
116
116
117
117
## Todo
118
118
119
-
-[ ] A frontend with Inferno or PReeact
119
+
-[ ] A frontend with Inferno or PReact
120
120
-[ ] Think about testing GraphQL API
121
121
-[ ] Implement an authentification based on OAuth2 or JWT and integrate with GraphQl
0 commit comments