graphiti 2.0.0.beta.2 → 2.0.0.beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +30 -86
- data/.github/workflows/docs.yml +60 -0
- data/.github/workflows/release.yml +8 -8
- data/.gitignore +7 -0
- data/.npmrc +9 -0
- data/.standard.yml +4 -1
- data/Appraisals +33 -32
- data/CHANGELOG.md +41 -0
- data/README.md +13 -2
- data/UPGRADING.md +2 -68
- data/docs/concepts/backends-and-models.md +122 -0
- data/docs/concepts/endpoints.md +183 -0
- data/docs/concepts/links.md +212 -0
- data/docs/concepts/overview.md +80 -0
- data/docs/concepts/persisting.md +376 -0
- data/docs/concepts/relationships.md +527 -0
- data/docs/concepts/resources.md +677 -0
- data/docs/getting-started/first-api.md +289 -0
- data/docs/getting-started/installation.md +185 -0
- data/docs/intro.md +307 -0
- data/docs/js/authentication.md +63 -0
- data/docs/js/ddau.md +20 -0
- data/docs/js/extra-params.md +41 -0
- data/docs/js/index.md +112 -0
- data/docs/js/installation.md +120 -0
- data/docs/js/middleware.md +72 -0
- data/docs/js/models.md +202 -0
- data/docs/js/reads.md +494 -0
- data/docs/js/state-syncing.md +100 -0
- data/docs/js/writes.md +373 -0
- data/docs/reference/vandal.md +63 -0
- data/docs/reference/why.md +13 -0
- data/docs/topics/authorization.md +155 -0
- data/docs/topics/caching.md +55 -0
- data/docs/topics/customizing-sideloads.md +156 -0
- data/docs/topics/debugging.md +216 -0
- data/docs/topics/error-handling.md +210 -0
- data/docs/topics/etags.md +46 -0
- data/docs/topics/hopping-relationships.md +149 -0
- data/docs/topics/json-attributes.md +77 -0
- data/docs/topics/openstruct-models.md +50 -0
- data/docs/topics/remote-resources.md +291 -0
- data/docs/topics/testing.md +894 -0
- data/docs/topics/without-activerecord.md +324 -0
- data/docs/tutorial/index.md +58 -0
- data/docs/tutorial/step_0.md +107 -0
- data/docs/tutorial/step_1.md +199 -0
- data/docs/tutorial/step_2.md +312 -0
- data/docs/tutorial/step_3.md +142 -0
- data/docs/tutorial/step_4.md +135 -0
- data/docs/tutorial/step_5.md +69 -0
- data/docs/tutorial/step_6.md +82 -0
- data/docs/tutorial/step_7.md +205 -0
- data/docs/tutorial/step_8.md +128 -0
- data/docs/tutorial/step_9.md +171 -0
- data/docs/upgrading.md +265 -0
- data/gemfiles/rails_7_1.gemfile +4 -3
- data/gemfiles/{rails_7_2_graphiti_rails.gemfile → rails_7_2.gemfile} +3 -3
- data/gemfiles/{rails_8_1_graphiti_rails.gemfile → rails_8_0.gemfile} +3 -3
- data/gemfiles/{rails_8_0_graphiti_rails.gemfile → rails_8_1.gemfile} +3 -3
- data/graphiti.gemspec +7 -5
- data/{deprecated_generators → lib/generators}/graphiti/api_test_generator.rb +7 -1
- data/{deprecated_generators → lib/generators}/graphiti/generator_mixin.rb +14 -1
- data/{deprecated_generators → lib/generators}/graphiti/install_generator.rb +19 -13
- data/{deprecated_generators → lib/generators}/graphiti/resource_generator.rb +43 -6
- data/{deprecated_generators → lib/generators}/graphiti/templates/index_request_spec.rb.erb +1 -1
- data/{deprecated_generators → lib/generators}/graphiti/templates/resource_reads_spec.rb.erb +6 -6
- data/{deprecated_generators → lib/generators}/graphiti/templates/show_request_spec.rb.erb +1 -1
- data/lib/graphiti/configuration.rb +2 -2
- data/lib/graphiti/error_serializers/conflict_request.rb +19 -0
- data/lib/graphiti/error_serializers/deprecated_constants.rb +48 -0
- data/lib/graphiti/error_serializers/invalid_request.rb +56 -0
- data/lib/graphiti/error_serializers/validation.rb +143 -0
- data/lib/graphiti/errors.rb +4 -23
- data/lib/graphiti/query.rb +1 -1
- data/lib/graphiti/rails/context.rb +33 -0
- data/lib/graphiti/rails/controller.rb +41 -0
- data/lib/graphiti/rails/debugging.rb +18 -0
- data/lib/graphiti/rails/exception_handlers.rb +77 -0
- data/lib/graphiti/rails/railtie.rb +139 -0
- data/lib/graphiti/rails/responders.rb +21 -0
- data/lib/graphiti/rails/test_helpers.rb +22 -0
- data/lib/graphiti/rails.rb +47 -29
- data/lib/graphiti/resource/configuration.rb +1 -0
- data/lib/graphiti/resource/interface.rb +2 -2
- data/lib/graphiti/resource/persistence.rb +14 -2
- data/lib/graphiti/resource/remote.rb +2 -2
- data/lib/graphiti/resource/sideloading.rb +1 -1
- data/lib/graphiti/resource.rb +13 -1
- data/lib/graphiti/responders.rb +7 -20
- data/lib/graphiti/schema.rb +5 -1
- data/lib/graphiti/schema_diff.rb +4 -0
- data/lib/graphiti/scope.rb +45 -37
- data/lib/graphiti/serializer.rb +6 -0
- data/lib/graphiti/sideload/belongs_to.rb +38 -5
- data/lib/graphiti/sideload/polymorphic_belongs_to.rb +27 -23
- data/lib/graphiti/sideload.rb +54 -35
- data/lib/graphiti/spec_helpers/errors.rb +73 -0
- data/lib/graphiti/spec_helpers/errors_proxy.rb +75 -0
- data/lib/graphiti/spec_helpers/helpers.rb +107 -0
- data/lib/graphiti/spec_helpers/node.rb +88 -0
- data/lib/graphiti/spec_helpers/rspec.rb +147 -0
- data/lib/graphiti/spec_helpers.rb +53 -0
- data/lib/graphiti/util/include_params.rb +2 -2
- data/lib/graphiti/util/persistence.rb +10 -11
- data/lib/graphiti/util/serializer_relationships.rb +41 -5
- data/lib/graphiti/version.rb +1 -1
- data/lib/graphiti-rails.rb +11 -0
- data/lib/graphiti.rb +34 -10
- data/lib/graphiti_errors.rb +11 -0
- data/lib/graphiti_spec_helpers/rspec.rb +3 -0
- data/lib/graphiti_spec_helpers.rb +11 -0
- data/lib/{graphiti/deprecated_tasks.rb → tasks/graphiti.rake} +6 -1
- data/package-lock.json +6199 -0
- data/package.json +5 -4
- data/website/.gitignore +20 -0
- data/website/README.md +43 -0
- data/website/docusaurus.config.js +141 -0
- data/website/package-lock.json +19474 -0
- data/website/package.json +46 -0
- data/website/sidebars.js +82 -0
- data/website/src/css/custom.css +58 -0
- data/website/src/pages/markdown-page.mdx +7 -0
- data/website/static/.nojekyll +0 -0
- data/website/static/1.13/2019/03/31/graphiti-1-0.html +205 -0
- data/website/static/1.13/2019/05/08/graphiti-1-1.html +212 -0
- data/website/static/1.13/2019/05/20/graphiti-1-2.html +214 -0
- data/website/static/1.13/2019/10/14/tutorial.html +198 -0
- data/website/static/1.13/CNAME +1 -0
- data/website/static/1.13/README.md +16 -0
- data/website/static/1.13/assets/css/syntax.css +60 -0
- data/website/static/1.13/assets/favicons/android-chrome-192x192.png +0 -0
- data/website/static/1.13/assets/favicons/android-chrome-256x256.png +0 -0
- data/website/static/1.13/assets/favicons/apple-touch-icon.png +0 -0
- data/website/static/1.13/assets/favicons/browserconfig.xml +9 -0
- data/website/static/1.13/assets/favicons/favicon-16x16.png +0 -0
- data/website/static/1.13/assets/favicons/favicon-32x32.png +0 -0
- data/website/static/1.13/assets/favicons/favicon.ico +0 -0
- data/website/static/1.13/assets/favicons/mstile-150x150.png +0 -0
- data/website/static/1.13/assets/favicons/safari-pinned-tab.svg +1 -0
- data/website/static/1.13/assets/favicons/site.webmanifest +19 -0
- data/website/static/1.13/assets/img/backend.gif +0 -0
- data/website/static/1.13/assets/img/conformity.png +0 -0
- data/website/static/1.13/assets/img/error_payload.png +0 -0
- data/website/static/1.13/assets/img/gh.png +0 -0
- data/website/static/1.13/assets/img/lifecycle.gif +0 -0
- data/website/static/1.13/assets/img/logo-500.png +0 -0
- data/website/static/1.13/assets/img/logo.png +0 -0
- data/website/static/1.13/assets/img/love-graffiti.jpg +0 -0
- data/website/static/1.13/assets/img/meta_total_count.png +0 -0
- data/website/static/1.13/assets/img/persist.jpg +0 -0
- data/website/static/1.13/assets/img/resource.gif +0 -0
- data/website/static/1.13/assets/img/rest-graffiti.jpg +0 -0
- data/website/static/1.13/assets/img/rest1.gif +0 -0
- data/website/static/1.13/assets/img/rest2.gif +0 -0
- data/website/static/1.13/assets/img/rest3.gif +0 -0
- data/website/static/1.13/assets/img/rethink-rest-graffiti.jpg +0 -0
- data/website/static/1.13/assets/img/why.png +0 -0
- data/website/static/1.13/assets/js/highlight.pack.js +2 -0
- data/website/static/1.13/assets/main.css +15518 -0
- data/website/static/1.13/assets/main.css.map +1 -0
- data/website/static/1.13/bin/bundle +109 -0
- data/website/static/1.13/bin/jekyll +27 -0
- data/website/static/1.13/bin/kramdown +27 -0
- data/website/static/1.13/bin/listen +27 -0
- data/website/static/1.13/bin/rake +27 -0
- data/website/static/1.13/bin/rougify +27 -0
- data/website/static/1.13/bin/safe_yaml +27 -0
- data/website/static/1.13/bin/sass +27 -0
- data/website/static/1.13/bin/sass-convert +27 -0
- data/website/static/1.13/bin/scss +27 -0
- data/website/static/1.13/blog.html +259 -0
- data/website/static/1.13/cheatsheet.html +316 -0
- data/website/static/1.13/cookbooks/authorization.md +0 -0
- data/website/static/1.13/cookbooks/caching.md +0 -0
- data/website/static/1.13/cookbooks/customizing-sideloads.html +325 -0
- data/website/static/1.13/cookbooks/etags.md +0 -0
- data/website/static/1.13/cookbooks/hopping-relationships.html +324 -0
- data/website/static/1.13/cookbooks/json_attributes.md +0 -0
- data/website/static/1.13/cookbooks/openstruct-models.md +0 -0
- data/website/static/1.13/cookbooks/remote-resources.md +0 -0
- data/website/static/1.13/cookbooks/without-activerecord.html +510 -0
- data/website/static/1.13/features.html +249 -0
- data/website/static/1.13/feed.xml +106 -0
- data/website/static/1.13/guides/concepts/backends-and-models.html +467 -0
- data/website/static/1.13/guides/concepts/debugging.html +440 -0
- data/website/static/1.13/guides/concepts/endpoints.html +432 -0
- data/website/static/1.13/guides/concepts/error-handling.html +396 -0
- data/website/static/1.13/guides/concepts/links.html +501 -0
- data/website/static/1.13/guides/concepts/remote-resources.html +536 -0
- data/website/static/1.13/guides/concepts/resources.html +2176 -0
- data/website/static/1.13/guides/concepts/testing.html +1469 -0
- data/website/static/1.13/guides/getting-started/installation.html +420 -0
- data/website/static/1.13/guides/graphiti-rails-migration.html +242 -0
- data/website/static/1.13/guides/index.html +269 -0
- data/website/static/1.13/guides/overview.html +325 -0
- data/website/static/1.13/guides/upgrading-2-0.html +193 -0
- data/website/static/1.13/guides/upgrading.html +314 -0
- data/website/static/1.13/guides/vandal.html +282 -0
- data/website/static/1.13/guides/why.html +1121 -0
- data/website/static/1.13/index.html +72 -0
- data/website/static/1.13/js/authentication.html +295 -0
- data/website/static/1.13/js/ddau.html +238 -0
- data/website/static/1.13/js/extra-params.html +270 -0
- data/website/static/1.13/js/index.html +321 -0
- data/website/static/1.13/js/installation.html +637 -0
- data/website/static/1.13/js/introduction.html +257 -0
- data/website/static/1.13/js/middleware.html +318 -0
- data/website/static/1.13/js/reads/fieldsets.html +271 -0
- data/website/static/1.13/js/reads/filtering.html +289 -0
- data/website/static/1.13/js/reads/includes.html +260 -0
- data/website/static/1.13/js/reads/index.html +497 -0
- data/website/static/1.13/js/reads/nested-queries.html +353 -0
- data/website/static/1.13/js/reads/pagination.html +260 -0
- data/website/static/1.13/js/reads/sorting.html +265 -0
- data/website/static/1.13/js/reads/statistics.html +289 -0
- data/website/static/1.13/js/state-syncing.html +340 -0
- data/website/static/1.13/js/writes/deferred.html +296 -0
- data/website/static/1.13/js/writes/dirty-tracking.html +399 -0
- data/website/static/1.13/js/writes/index.html +391 -0
- data/website/static/1.13/js/writes/nested.html +330 -0
- data/website/static/1.13/js/writes/validations.html +272 -0
- data/website/static/1.13/quickstart.html +660 -0
- data/website/static/1.13/template +161 -0
- data/website/static/1.13/tutorial/index.html +250 -0
- data/website/static/1.13/tutorial/step_0.html +292 -0
- data/website/static/1.13/tutorial/step_1.html +517 -0
- data/website/static/1.13/tutorial/step_2.html +481 -0
- data/website/static/1.13/tutorial/step_3.html +323 -0
- data/website/static/1.13/tutorial/step_4.html +318 -0
- data/website/static/1.13/tutorial/step_5.html +265 -0
- data/website/static/1.13/tutorial/step_6.html +276 -0
- data/website/static/1.13/tutorial/step_7.html +390 -0
- data/website/static/1.13/tutorial/step_8.html +316 -0
- data/website/static/1.13/tutorial/step_9.html +365 -0
- data/website/static/assets/img/error_payload.png +0 -0
- data/website/static/assets/img/legacy/legacy-0378a3bb39.png +0 -0
- data/website/static/assets/img/legacy/legacy-05bbd3e5fd.png +0 -0
- data/website/static/assets/img/legacy/legacy-07aa104495.png +0 -0
- data/website/static/assets/img/legacy/legacy-0c75a16b3a.gif +0 -0
- data/website/static/assets/img/legacy/legacy-3076df6209.png +0 -0
- data/website/static/assets/img/legacy/legacy-7f6889bc89.png +0 -0
- data/website/static/assets/img/legacy/legacy-a2cc4363c3.png +0 -0
- data/website/static/assets/img/legacy/legacy-f67cfa89ab.png +0 -0
- data/website/static/assets/img/meta_total_count.png +0 -0
- data/website/static/img/docusaurus-social-card.jpg +0 -0
- data/website/static/img/docusaurus.png +0 -0
- data/website/static/img/favicon.ico +0 -0
- data/website/static/img/logo.png +0 -0
- data/website/static/img/logo.svg +1 -0
- data/website/static/img/undraw_docusaurus_mountain.svg +171 -0
- data/website/static/img/undraw_docusaurus_react.svg +170 -0
- data/website/static/img/undraw_docusaurus_tree.svg +40 -0
- metadata +245 -46
- data/gemfiles/rails_6.gemfile +0 -18
- data/gemfiles/rails_6_graphiti_rails.gemfile +0 -19
- data/gemfiles/rails_7.gemfile +0 -18
- data/gemfiles/rails_7_1_graphiti_rails.gemfile +0 -19
- data/gemfiles/rails_7_graphiti_rails.gemfile +0 -19
- data/lib/graphiti/railtie.rb +0 -121
- /data/{deprecated_generators → lib/generators}/graphiti/resource_test_generator.rb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/application_resource.rb.erb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/controller.rb.erb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/create_request_spec.rb.erb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/destroy_request_spec.rb.erb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/resource.rb.erb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/resource_writes_spec.rb.erb +0 -0
- /data/{deprecated_generators → lib/generators}/graphiti/templates/update_request_spec.rb.erb +0 -0
data/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "graphiti",
|
|
3
|
-
"
|
|
3
|
+
"private": true,
|
|
4
|
+
"version": "0.0.0-development",
|
|
4
5
|
"repository": {
|
|
5
6
|
"type": "git",
|
|
6
7
|
"url": "git+https://github.com/graphiti-api/graphiti.git"
|
|
@@ -15,9 +16,9 @@
|
|
|
15
16
|
},
|
|
16
17
|
"devDependencies": {
|
|
17
18
|
"semantic-release-rubygem": "^1.2.0",
|
|
18
|
-
"semantic-release": "^
|
|
19
|
-
"@semantic-release/changelog": "^
|
|
20
|
-
"@semantic-release/git": "^
|
|
19
|
+
"semantic-release": "^25.0.8",
|
|
20
|
+
"@semantic-release/changelog": "^7.0.0",
|
|
21
|
+
"@semantic-release/git": "^11.0.1"
|
|
21
22
|
},
|
|
22
23
|
"release": {
|
|
23
24
|
"branches": [
|
data/website/.gitignore
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Dependencies
|
|
2
|
+
/node_modules
|
|
3
|
+
|
|
4
|
+
# Production
|
|
5
|
+
/build
|
|
6
|
+
|
|
7
|
+
# Generated files
|
|
8
|
+
.docusaurus
|
|
9
|
+
.cache-loader
|
|
10
|
+
|
|
11
|
+
# Misc
|
|
12
|
+
.DS_Store
|
|
13
|
+
.env.local
|
|
14
|
+
.env.development.local
|
|
15
|
+
.env.test.local
|
|
16
|
+
.env.production.local
|
|
17
|
+
|
|
18
|
+
npm-debug.log*
|
|
19
|
+
yarn-debug.log*
|
|
20
|
+
yarn-error.log*
|
data/website/README.md
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# Website
|
|
2
|
+
|
|
3
|
+
This website is built using [Docusaurus](https://docusaurus.io/), a modern static website generator.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
**Note**: feel free to use the package manager of your choice.
|
|
12
|
+
|
|
13
|
+
## Local Development
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
npm run start
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
|
|
20
|
+
|
|
21
|
+
## Build
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
npm run build
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
This command generates static content into the `build` directory and can be served using any static contents hosting service.
|
|
28
|
+
|
|
29
|
+
## Deployment
|
|
30
|
+
|
|
31
|
+
Using SSH:
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
USE_SSH=true npm run deploy
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
Not using SSH:
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
GIT_USER=<Your GitHub username> npm run deploy
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
If you are using GitHub Pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
// @ts-check
|
|
2
|
+
const {themes} = require('prism-react-renderer');
|
|
3
|
+
|
|
4
|
+
/** @type {import('@docusaurus/types').Config} */
|
|
5
|
+
const config = {
|
|
6
|
+
title: 'Graphiti',
|
|
7
|
+
tagline: 'Stylish Graph APIs',
|
|
8
|
+
favicon: 'img/favicon.ico',
|
|
9
|
+
|
|
10
|
+
url: 'https://www.graphiti.dev',
|
|
11
|
+
// Project pages serve this repo under /graphiti/ until the domain moves
|
|
12
|
+
// here from graphiti-api.github.io, so the deploy sets DOCS_BASE_URL.
|
|
13
|
+
baseUrl: process.env.DOCS_BASE_URL || '/',
|
|
14
|
+
organizationName: 'graphiti-api',
|
|
15
|
+
projectName: 'graphiti',
|
|
16
|
+
|
|
17
|
+
onBrokenLinks: 'warn',
|
|
18
|
+
markdown: {hooks: {onBrokenMarkdownLinks: 'warn'}},
|
|
19
|
+
|
|
20
|
+
presets: [
|
|
21
|
+
[
|
|
22
|
+
'classic',
|
|
23
|
+
/** @type {import('@docusaurus/preset-classic').Options} */
|
|
24
|
+
({
|
|
25
|
+
docs: {
|
|
26
|
+
// markdown lives at the repo root, next to the code it documents
|
|
27
|
+
path: '../docs',
|
|
28
|
+
routeBasePath: '/',
|
|
29
|
+
sidebarPath: require.resolve('./sidebars.js'),
|
|
30
|
+
editUrl: 'https://github.com/graphiti-api/graphiti/tree/main/website/',
|
|
31
|
+
// Unversioned docs serve at the root, and would otherwise be
|
|
32
|
+
// labelled "Next" in the dropdown. Once `npm run docusaurus
|
|
33
|
+
// docs:version 2.0` cuts a version, that becomes the root and the
|
|
34
|
+
// working copy moves to /next.
|
|
35
|
+
versions: {current: {label: '2.0 beta'}},
|
|
36
|
+
},
|
|
37
|
+
blog: false,
|
|
38
|
+
theme: {customCss: require.resolve('./src/css/custom.css')},
|
|
39
|
+
}),
|
|
40
|
+
],
|
|
41
|
+
],
|
|
42
|
+
|
|
43
|
+
plugins: [
|
|
44
|
+
[
|
|
45
|
+
'@docusaurus/plugin-client-redirects',
|
|
46
|
+
{
|
|
47
|
+
// The 1.x Jekyll site served /guides/* and /cookbooks/*, and early 2.0
|
|
48
|
+
// drafts served /quickstart and /cheatsheet. Keep those URLs alive.
|
|
49
|
+
// Nothing under /1.13/ is touched: that is the frozen 1.x site.
|
|
50
|
+
redirects: [
|
|
51
|
+
{from: ['/quickstart'], to: '/getting-started/first-api'},
|
|
52
|
+
{from: ['/cheatsheet', '/guides', '/guides/index'], to: '/'},
|
|
53
|
+
{from: ['/guides/overview'], to: '/concepts/overview'},
|
|
54
|
+
{from: ['/guides/why'], to: '/reference/why'},
|
|
55
|
+
{from: ['/guides/vandal'], to: '/reference/vandal'},
|
|
56
|
+
{from: ['/guides/upgrading', '/guides/upgrading-2-0', '/reference/upgrading-2-0', '/upgrading/controllers', '/upgrading/testing', '/upgrading/persistence-hooks', '/upgrading/exception-handling', '/upgrading/belongs-to-linkage', '/upgrading/without-rails'], to: '/upgrading'},
|
|
57
|
+
{from: ['/guides/getting-started/installation'], to: '/getting-started/installation'},
|
|
58
|
+
|
|
59
|
+
{from: ['/guides/concepts/resources'], to: '/concepts/resources'},
|
|
60
|
+
{from: ['/guides/concepts/endpoints'], to: '/concepts/endpoints'},
|
|
61
|
+
{from: ['/guides/concepts/links'], to: '/concepts/links'},
|
|
62
|
+
{from: ['/guides/concepts/backends-and-models'], to: '/concepts/backends-and-models'},
|
|
63
|
+
{from: ['/guides/concepts/testing'], to: '/topics/testing'},
|
|
64
|
+
{from: ['/guides/concepts/debugging'], to: '/topics/debugging'},
|
|
65
|
+
{from: ['/guides/concepts/error-handling'], to: '/topics/error-handling'},
|
|
66
|
+
{from: ['/guides/concepts/remote-resources', '/cookbooks/remote-resources'], to: '/topics/remote-resources'},
|
|
67
|
+
|
|
68
|
+
// Cookbook stubs that never had content now point at the real pages
|
|
69
|
+
{from: ['/cookbooks/authorization'], to: '/topics/authorization'},
|
|
70
|
+
{from: ['/cookbooks/caching'], to: '/topics/caching'},
|
|
71
|
+
{from: ['/cookbooks/etags'], to: '/topics/etags'},
|
|
72
|
+
{from: ['/cookbooks/json_attributes'], to: '/topics/json-attributes'},
|
|
73
|
+
{from: ['/cookbooks/openstruct-models'], to: '/topics/openstruct-models'},
|
|
74
|
+
{from: ['/cookbooks/without-activerecord'], to: '/topics/without-activerecord'},
|
|
75
|
+
{from: ['/cookbooks/customizing-sideloads'], to: '/topics/customizing-sideloads'},
|
|
76
|
+
{from: ['/cookbooks/hopping-relationships'], to: '/topics/hopping-relationships'},
|
|
77
|
+
|
|
78
|
+
{from: ['/js/introduction'], to: '/js'},
|
|
79
|
+
{
|
|
80
|
+
from: [
|
|
81
|
+
'/js/reads/index',
|
|
82
|
+
'/js/reads/filtering',
|
|
83
|
+
'/js/reads/sorting',
|
|
84
|
+
'/js/reads/pagination',
|
|
85
|
+
'/js/reads/fieldsets',
|
|
86
|
+
'/js/reads/includes',
|
|
87
|
+
'/js/reads/nested-queries',
|
|
88
|
+
'/js/reads/statistics',
|
|
89
|
+
],
|
|
90
|
+
to: '/js/reads',
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
from: [
|
|
94
|
+
'/js/writes/index',
|
|
95
|
+
'/js/writes/validations',
|
|
96
|
+
'/js/writes/dirty-tracking',
|
|
97
|
+
'/js/writes/nested',
|
|
98
|
+
'/js/writes/deferred',
|
|
99
|
+
],
|
|
100
|
+
to: '/js/writes',
|
|
101
|
+
},
|
|
102
|
+
],
|
|
103
|
+
},
|
|
104
|
+
],
|
|
105
|
+
],
|
|
106
|
+
|
|
107
|
+
themeConfig: {
|
|
108
|
+
colorMode: {
|
|
109
|
+
// Dark for a first-time visitor. Flip respectPrefersColorScheme to true
|
|
110
|
+
// to follow the OS setting instead, in which case defaultMode only
|
|
111
|
+
// applies when the visitor has no preference either way. Once someone
|
|
112
|
+
// uses the navbar toggle their choice is remembered and wins over both.
|
|
113
|
+
defaultMode: 'dark',
|
|
114
|
+
respectPrefersColorScheme: false,
|
|
115
|
+
},
|
|
116
|
+
navbar: {
|
|
117
|
+
title: 'Graphiti',
|
|
118
|
+
logo: {alt: 'Graphiti', src: 'img/logo.png'},
|
|
119
|
+
items: [
|
|
120
|
+
{
|
|
121
|
+
type: 'docsVersionDropdown',
|
|
122
|
+
position: 'right',
|
|
123
|
+
// 1.x stays as the original Jekyll site, frozen under /1.13.
|
|
124
|
+
//
|
|
125
|
+
// target '_self' is required. Without it the router treats this as
|
|
126
|
+
// an in-app route, finds no match, and renders the 404 page even
|
|
127
|
+
// though the file is served fine.
|
|
128
|
+
dropdownItemsAfter: [
|
|
129
|
+
{href: '/1.13/', label: '1.x', target: '_self'},
|
|
130
|
+
],
|
|
131
|
+
},
|
|
132
|
+
{href: 'https://github.com/graphiti-api/graphiti', label: 'GitHub', position: 'right'},
|
|
133
|
+
{href: 'https://discord.gg/wgqkMBsSRV', label: 'Discord', position: 'right'},
|
|
134
|
+
],
|
|
135
|
+
},
|
|
136
|
+
footer: {style: 'dark', copyright: `Graphiti is released under the MIT license.`},
|
|
137
|
+
prism: {theme: themes.github, darkTheme: themes.dracula, additionalLanguages: ['ruby', 'bash', 'json', 'http']},
|
|
138
|
+
},
|
|
139
|
+
};
|
|
140
|
+
|
|
141
|
+
module.exports = config;
|