Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Begin migration to @reasonml-community/graphql-ppx, starting with client.execute* methods. #221

Merged
merged 1 commit into from
Oct 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion bsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,11 @@
}
],
"suffix": ".bs.js",
"bs-dependencies": ["reason-react", "wonka", "bs-fetch"],
"bs-dependencies": [
"reason-react",
"wonka",
"bs-fetch"
],
"bs-dev-dependencies": ["@glennsl/bs-jest"],
"refmt": 3,
"warnings": {
Expand Down
5 changes: 3 additions & 2 deletions examples/1-execute-query-mutation/bsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@
"wonka",
"reason-react",
"bs-css-emotion",
"bs-css"
"bs-css",
"@reasonml-community/graphql-ppx"
],
"refmt": 3,
"warnings": {
"error": "+5"
},
"ppx-flags": ["@baransu/graphql_ppx_re/ppx"]
"ppx-flags": ["@reasonml-community/graphql-ppx/ppx"]
}
2 changes: 1 addition & 1 deletion examples/1-execute-query-mutation/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
"start:demo": "webpack-dev-server"
},
"dependencies": {
"@reasonml-community/graphql-ppx": "^1.0.1",
"bs-css-emotion": "^1.2.0",
"reason-react": "^0.7.0",
"reason-urql": "link:../../"
},
"devDependencies": {
"@baransu/graphql_ppx_re": "^0.7.1",
"bs-platform": "7.3.2",
"webpack": "^4.43.0",
"webpack-cli": "^3.3.11",
Expand Down
81 changes: 81 additions & 0 deletions examples/1-execute-query-mutation/public/index.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
.previewer {
display: grid;
grid-template-columns: 1fr;
row-gap: 1rem;
max-width: 1280px;
margin-left: auto;
margin-right: auto;
}

@media (min-width: 640px) {
.previewer {
grid-template-columns: repeat(2, minmax(0, 1fr));
grid-template-rows: repeat(2, 1fr);
column-gap: 2rem;
height: 100%;
}
}

.quadrant {
display: flex;
flex-direction: column;
overflow: hidden;
}

.quadrant > * {
margin-top: 0;
margin-bottom: 0;
}

.quadrant > * + * {
margin-top: 1rem;
}

.quadrant__section {
margin: 1rem;
}

.quadrant__title {
font-size: 2rem;
font-family: "DM Mono", monospace;
}

.quadrant__button {
align-self: self-start;
background-color: white;
font-size: 1.4rem;
border-radius: 2.5rem;
padding: 0.75rem;
cursor: pointer;
border-width: 2px;
border-style: solid;
}

.quadrant__button--teal {
border-color: #48a9dc;
color: #48a9dc;
}

.quadrant__button--orange {
border-color: #db4d3f;
color: #db4d3f;
}

.quadrant__code {
color: #ffffff;
padding: 1rem;
font-size: 1.4rem;
white-space: pre;
font-family: "DM Mono", monospace;
border-radius: 0.5rem;
max-height: 20rem;
overflow: auto;
}

.quadrant__code--teal {
background: #48a9dc;
}

.quadrant__code--orange {
background: #db4d3f;
}
12 changes: 11 additions & 1 deletion examples/1-execute-query-mutation/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,26 @@
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1" />
<title>reason-urql</title>
<style type="text/css">
html {
font-size: 10px;
}

body {
margin: 0;
}

* {
box-sizing: border-box;
}
</style>
<link
href="https://fonts.googleapis.com/css?family=Space+Mono"
href="https://fonts.googleapis.com/css?family=DM+Mono&display=swap"
rel="stylesheet"
/>
<link href="./index.css" rel="stylesheet" />
</head>
<body>
<div id="root"></div>
Expand Down
Loading