Skip to content

Commit 2ebe7c4

Browse files
committed
Fix Uncaught ReferenceError: fetcher is not defined error
1 parent 89ab920 commit 2ebe7c4

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ See [GitHub releases](https://github.com/mll-lab/laravel-graphiql/releases).
99

1010
## Unreleased
1111

12+
## v4.0.1
13+
14+
### Fixed
15+
16+
- Fix `Uncaught ReferenceError: fetcher is not defined` error
17+
1218
## v4.0.0
1319

1420
### Changed

views/index.blade.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@
4242
<script src="{{ GraphiQLAsset::graphiQLJS() }}"></script>
4343
<script src="{{ GraphiQLAsset::pluginExplorerJS() }}"></script>
4444
<script>
45+
const fetcher = GraphiQL.createFetcher({
46+
url: '{{ $url }}',
47+
subscriptionUrl: '{{ $subscriptionUrl }}',
48+
});
4549
const explorer = GraphiQLPluginExplorer.explorerPlugin();
4650
4751
function GraphiQLWithExplorer() {

0 commit comments

Comments
 (0)