houdini-svelte 2.2.0-next.5 → 3.0.0-next.6

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.
@@ -2368,7 +2368,7 @@ var require_path_visitor4 = __commonJS({
2368
2368
  }
2369
2369
  return target;
2370
2370
  }
2371
- PathVisitor.visit = function visit55(node, methods) {
2371
+ PathVisitor.visit = function visit54(node, methods) {
2372
2372
  return PathVisitor.fromMethodsObject(methods).visit(node);
2373
2373
  };
2374
2374
  var PVp = PathVisitor.prototype;
@@ -2559,7 +2559,7 @@ var require_path_visitor4 = __commonJS({
2559
2559
  this.needToCallTraverse = false;
2560
2560
  return visitChildren(path7, PathVisitor.fromMethodsObject(newVisitor || this.visitor));
2561
2561
  };
2562
- sharedContextProtoMethods.visit = function visit55(path7, newVisitor) {
2562
+ sharedContextProtoMethods.visit = function visit54(path7, newVisitor) {
2563
2563
  if (!(this instanceof this.Context)) {
2564
2564
  throw new Error("");
2565
2565
  }
@@ -4001,7 +4001,7 @@ var require_main5 = __commonJS({
4001
4001
  var someField = _a.someField;
4002
4002
  var Type = _a.Type;
4003
4003
  var use = _a.use;
4004
- var visit55 = _a.visit;
4004
+ var visit54 = _a.visit;
4005
4005
  exports2.astNodesAreEquivalent = astNodesAreEquivalent;
4006
4006
  exports2.builders = builders;
4007
4007
  exports2.builtInTypes = builtInTypes;
@@ -4018,7 +4018,7 @@ var require_main5 = __commonJS({
4018
4018
  exports2.someField = someField;
4019
4019
  exports2.Type = Type;
4020
4020
  exports2.use = use;
4021
- exports2.visit = visit55;
4021
+ exports2.visit = visit54;
4022
4022
  Object.assign(namedTypes_1.namedTypes, n);
4023
4023
  }
4024
4024
  });
@@ -6097,7 +6097,7 @@ var require_esprima7 = __commonJS({
6097
6097
  var jsx_parser_1 = __webpack_require__(3);
6098
6098
  var parser_1 = __webpack_require__(8);
6099
6099
  var tokenizer_1 = __webpack_require__(15);
6100
- function parse25(code, options, delegate) {
6100
+ function parse23(code, options, delegate) {
6101
6101
  var commentHandler = null;
6102
6102
  var proxyDelegate = function(node, metadata) {
6103
6103
  if (delegate) {
@@ -6142,17 +6142,17 @@ var require_esprima7 = __commonJS({
6142
6142
  }
6143
6143
  return ast;
6144
6144
  }
6145
- exports3.parse = parse25;
6145
+ exports3.parse = parse23;
6146
6146
  function parseModule(code, options, delegate) {
6147
6147
  var parsingOptions = options || {};
6148
6148
  parsingOptions.sourceType = "module";
6149
- return parse25(code, parsingOptions, delegate);
6149
+ return parse23(code, parsingOptions, delegate);
6150
6150
  }
6151
6151
  exports3.parseModule = parseModule;
6152
6152
  function parseScript(code, options, delegate) {
6153
6153
  var parsingOptions = options || {};
6154
6154
  parsingOptions.sourceType = "script";
6155
- return parse25(code, parsingOptions, delegate);
6155
+ return parse23(code, parsingOptions, delegate);
6156
6156
  }
6157
6157
  exports3.parseScript = parseScript;
6158
6158
  function tokenize(code, options, delegate) {
@@ -12292,7 +12292,7 @@ var require_esprima8 = __commonJS({
12292
12292
  Object.defineProperty(exports2, "__esModule", { value: true });
12293
12293
  exports2.parse = void 0;
12294
12294
  var util_1 = require_util6();
12295
- function parse25(source, options) {
12295
+ function parse23(source, options) {
12296
12296
  var comments = [];
12297
12297
  var ast = require_esprima7().parse(source, {
12298
12298
  loc: true,
@@ -12310,7 +12310,7 @@ var require_esprima8 = __commonJS({
12310
12310
  }
12311
12311
  return ast;
12312
12312
  }
12313
- exports2.parse = parse25;
12313
+ exports2.parse = parse23;
12314
12314
  }
12315
12315
  });
12316
12316
 
@@ -13448,7 +13448,7 @@ var require_parser4 = __commonJS({
13448
13448
  var lines_1 = require_lines4();
13449
13449
  var comments_1 = require_comments4();
13450
13450
  var util = tslib_1.__importStar(require_util6());
13451
- function parse25(source, options) {
13451
+ function parse23(source, options) {
13452
13452
  options = (0, options_1.normalize)(options);
13453
13453
  var lines = (0, lines_1.fromString)(source, options);
13454
13454
  var sourceWithoutTabs = lines.toString({
@@ -13520,7 +13520,7 @@ var require_parser4 = __commonJS({
13520
13520
  (0, comments_1.attach)(comments, program.body.length ? file.program : file, lines);
13521
13521
  return new TreeCopier(lines, tokens).copy(file);
13522
13522
  }
13523
- exports2.parse = parse25;
13523
+ exports2.parse = parse23;
13524
13524
  var TreeCopier = function TreeCopier2(lines, tokens) {
13525
13525
  assert_1.default.ok(this instanceof TreeCopier2);
13526
13526
  this.lines = lines;
@@ -19606,7 +19606,7 @@ var require_jsonfile = __commonJS2({
19606
19606
  }
19607
19607
  var universalify = require_universalify();
19608
19608
  var { stringify, stripBom } = require_utils2();
19609
- async function _readFile2(file, options = {}) {
19609
+ async function _readFile(file, options = {}) {
19610
19610
  if (typeof options === "string") {
19611
19611
  options = { encoding: options };
19612
19612
  }
@@ -19627,7 +19627,7 @@ var require_jsonfile = __commonJS2({
19627
19627
  }
19628
19628
  return obj;
19629
19629
  }
19630
- var readFile22 = universalify.fromPromise(_readFile2);
19630
+ var readFile22 = universalify.fromPromise(_readFile);
19631
19631
  function readFileSync22(file, options = {}) {
19632
19632
  if (typeof options === "string") {
19633
19633
  options = { encoding: options };
@@ -20381,49 +20381,49 @@ var require_Dirent = __commonJS2({
20381
20381
  var S_IFLNK = constants_1.constants.S_IFLNK;
20382
20382
  var S_IFIFO = constants_1.constants.S_IFIFO;
20383
20383
  var S_IFSOCK = constants_1.constants.S_IFSOCK;
20384
- var Dirent2 = (
20384
+ var Dirent = (
20385
20385
  /** @class */
20386
20386
  function() {
20387
- function Dirent22() {
20387
+ function Dirent2() {
20388
20388
  this.name = "";
20389
20389
  this.mode = 0;
20390
20390
  }
20391
- Dirent22.build = function(link, encoding) {
20392
- var dirent = new Dirent22();
20391
+ Dirent2.build = function(link, encoding) {
20392
+ var dirent = new Dirent2();
20393
20393
  var mode = link.getNode().mode;
20394
20394
  dirent.name = (0, encoding_1.strToEncoding)(link.getName(), encoding);
20395
20395
  dirent.mode = mode;
20396
20396
  return dirent;
20397
20397
  };
20398
- Dirent22.prototype._checkModeProperty = function(property) {
20398
+ Dirent2.prototype._checkModeProperty = function(property) {
20399
20399
  return (this.mode & S_IFMT) === property;
20400
20400
  };
20401
- Dirent22.prototype.isDirectory = function() {
20401
+ Dirent2.prototype.isDirectory = function() {
20402
20402
  return this._checkModeProperty(S_IFDIR);
20403
20403
  };
20404
- Dirent22.prototype.isFile = function() {
20404
+ Dirent2.prototype.isFile = function() {
20405
20405
  return this._checkModeProperty(S_IFREG);
20406
20406
  };
20407
- Dirent22.prototype.isBlockDevice = function() {
20407
+ Dirent2.prototype.isBlockDevice = function() {
20408
20408
  return this._checkModeProperty(S_IFBLK);
20409
20409
  };
20410
- Dirent22.prototype.isCharacterDevice = function() {
20410
+ Dirent2.prototype.isCharacterDevice = function() {
20411
20411
  return this._checkModeProperty(S_IFCHR);
20412
20412
  };
20413
- Dirent22.prototype.isSymbolicLink = function() {
20413
+ Dirent2.prototype.isSymbolicLink = function() {
20414
20414
  return this._checkModeProperty(S_IFLNK);
20415
20415
  };
20416
- Dirent22.prototype.isFIFO = function() {
20416
+ Dirent2.prototype.isFIFO = function() {
20417
20417
  return this._checkModeProperty(S_IFIFO);
20418
20418
  };
20419
- Dirent22.prototype.isSocket = function() {
20419
+ Dirent2.prototype.isSocket = function() {
20420
20420
  return this._checkModeProperty(S_IFSOCK);
20421
20421
  };
20422
- return Dirent22;
20422
+ return Dirent2;
20423
20423
  }()
20424
20424
  );
20425
- exports2.Dirent = Dirent2;
20426
- exports2.default = Dirent2;
20425
+ exports2.Dirent = Dirent;
20426
+ exports2.default = Dirent;
20427
20427
  }
20428
20428
  });
20429
20429
  var require_setImmediate = __commonJS2({
@@ -85302,15 +85302,6 @@ function serialized_manifest_path(config, base = base_dir(config)) {
85302
85302
  return join2(base, "manifest.json");
85303
85303
  }
85304
85304
  var t2 = __toESM2(require_lib5(), 1);
85305
- function definitionFromAncestors(ancestors) {
85306
- let parents = [...ancestors];
85307
- parents.shift();
85308
- let definition = parents.shift();
85309
- while (Array.isArray(definition) && definition) {
85310
- definition = parents.shift();
85311
- }
85312
- return { parents, definition };
85313
- }
85314
85305
  function formatErrors(e22, afterError) {
85315
85306
  const errors = Array.isArray(e22) ? e22 : [e22];
85316
85307
  for (const error of errors) {
@@ -91174,7 +91165,7 @@ var require_jsonfile3 = __commonJS3({
91174
91165
  }
91175
91166
  var universalify = require_universalify2();
91176
91167
  var { stringify, stripBom } = require_utils22();
91177
- async function _readFile2(file, options = {}) {
91168
+ async function _readFile(file, options = {}) {
91178
91169
  if (typeof options === "string") {
91179
91170
  options = { encoding: options };
91180
91171
  }
@@ -91195,7 +91186,7 @@ var require_jsonfile3 = __commonJS3({
91195
91186
  }
91196
91187
  return obj;
91197
91188
  }
91198
- var readFile22 = universalify.fromPromise(_readFile2);
91189
+ var readFile22 = universalify.fromPromise(_readFile);
91199
91190
  function readFileSync22(file, options = {}) {
91200
91191
  if (typeof options === "string") {
91201
91192
  options = { encoding: options };
@@ -91949,49 +91940,49 @@ var require_Dirent2 = __commonJS3({
91949
91940
  var S_IFLNK = constants_1.constants.S_IFLNK;
91950
91941
  var S_IFIFO = constants_1.constants.S_IFIFO;
91951
91942
  var S_IFSOCK = constants_1.constants.S_IFSOCK;
91952
- var Dirent2 = (
91943
+ var Dirent = (
91953
91944
  /** @class */
91954
91945
  function() {
91955
- function Dirent22() {
91946
+ function Dirent2() {
91956
91947
  this.name = "";
91957
91948
  this.mode = 0;
91958
91949
  }
91959
- Dirent22.build = function(link, encoding) {
91960
- var dirent = new Dirent22();
91950
+ Dirent2.build = function(link, encoding) {
91951
+ var dirent = new Dirent2();
91961
91952
  var mode = link.getNode().mode;
91962
91953
  dirent.name = (0, encoding_1.strToEncoding)(link.getName(), encoding);
91963
91954
  dirent.mode = mode;
91964
91955
  return dirent;
91965
91956
  };
91966
- Dirent22.prototype._checkModeProperty = function(property) {
91957
+ Dirent2.prototype._checkModeProperty = function(property) {
91967
91958
  return (this.mode & S_IFMT) === property;
91968
91959
  };
91969
- Dirent22.prototype.isDirectory = function() {
91960
+ Dirent2.prototype.isDirectory = function() {
91970
91961
  return this._checkModeProperty(S_IFDIR);
91971
91962
  };
91972
- Dirent22.prototype.isFile = function() {
91963
+ Dirent2.prototype.isFile = function() {
91973
91964
  return this._checkModeProperty(S_IFREG);
91974
91965
  };
91975
- Dirent22.prototype.isBlockDevice = function() {
91966
+ Dirent2.prototype.isBlockDevice = function() {
91976
91967
  return this._checkModeProperty(S_IFBLK);
91977
91968
  };
91978
- Dirent22.prototype.isCharacterDevice = function() {
91969
+ Dirent2.prototype.isCharacterDevice = function() {
91979
91970
  return this._checkModeProperty(S_IFCHR);
91980
91971
  };
91981
- Dirent22.prototype.isSymbolicLink = function() {
91972
+ Dirent2.prototype.isSymbolicLink = function() {
91982
91973
  return this._checkModeProperty(S_IFLNK);
91983
91974
  };
91984
- Dirent22.prototype.isFIFO = function() {
91975
+ Dirent2.prototype.isFIFO = function() {
91985
91976
  return this._checkModeProperty(S_IFIFO);
91986
91977
  };
91987
- Dirent22.prototype.isSocket = function() {
91978
+ Dirent2.prototype.isSocket = function() {
91988
91979
  return this._checkModeProperty(S_IFSOCK);
91989
91980
  };
91990
- return Dirent22;
91981
+ return Dirent2;
91991
91982
  }()
91992
91983
  );
91993
- exports2.Dirent = Dirent2;
91994
- exports2.default = Dirent2;
91984
+ exports2.Dirent = Dirent;
91985
+ exports2.default = Dirent;
91995
91986
  }
91996
91987
  });
91997
91988
  var require_setImmediate2 = __commonJS3({
@@ -150834,7 +150825,7 @@ function walkAncestors(schema2, filepath, ancestors) {
150834
150825
  }
150835
150826
  return getRootType(field.type);
150836
150827
  }
150837
- function definitionFromAncestors2(ancestors) {
150828
+ function definitionFromAncestors(ancestors) {
150838
150829
  let parents = [...ancestors];
150839
150830
  parents.shift();
150840
150831
  let definition = parents.shift();
@@ -160335,7 +160326,7 @@ async function typeCheck(config, docs) {
160335
160326
  if (![config.listDirective, config.paginateDirective].includes(directive.name.value)) {
160336
160327
  return;
160337
160328
  }
160338
- const { parents, definition } = definitionFromAncestors2(ancestors);
160329
+ const { parents, definition } = definitionFromAncestors(ancestors);
160339
160330
  let needsParent = false;
160340
160331
  if (definition.kind !== "OperationDefinition" && definition.kind !== "FragmentDefinition" || definition.kind === "OperationDefinition" && definition.operation !== "query") {
160341
160332
  errors.push(
@@ -161001,7 +160992,7 @@ function nodeDirectives(config, directives) {
161001
160992
  if (!directives.includes(node.name.value)) {
161002
160993
  return;
161003
160994
  }
161004
- let { definition } = definitionFromAncestors2(ancestors);
160995
+ let { definition } = definitionFromAncestors(ancestors);
161005
160996
  let definitionType = "";
161006
160997
  if (definition.kind === "OperationDefinition") {
161007
160998
  if (definition.operation !== "query") {
@@ -162155,49 +162146,49 @@ var require_Dirent3 = __commonJS4({
162155
162146
  var S_IFLNK = constants_1.constants.S_IFLNK;
162156
162147
  var S_IFIFO = constants_1.constants.S_IFIFO;
162157
162148
  var S_IFSOCK = constants_1.constants.S_IFSOCK;
162158
- var Dirent2 = (
162149
+ var Dirent = (
162159
162150
  /** @class */
162160
162151
  function() {
162161
- function Dirent22() {
162152
+ function Dirent2() {
162162
162153
  this.name = "";
162163
162154
  this.mode = 0;
162164
162155
  }
162165
- Dirent22.build = function(link, encoding) {
162166
- var dirent = new Dirent22();
162156
+ Dirent2.build = function(link, encoding) {
162157
+ var dirent = new Dirent2();
162167
162158
  var mode = link.getNode().mode;
162168
162159
  dirent.name = (0, encoding_1.strToEncoding)(link.getName(), encoding);
162169
162160
  dirent.mode = mode;
162170
162161
  return dirent;
162171
162162
  };
162172
- Dirent22.prototype._checkModeProperty = function(property) {
162163
+ Dirent2.prototype._checkModeProperty = function(property) {
162173
162164
  return (this.mode & S_IFMT) === property;
162174
162165
  };
162175
- Dirent22.prototype.isDirectory = function() {
162166
+ Dirent2.prototype.isDirectory = function() {
162176
162167
  return this._checkModeProperty(S_IFDIR);
162177
162168
  };
162178
- Dirent22.prototype.isFile = function() {
162169
+ Dirent2.prototype.isFile = function() {
162179
162170
  return this._checkModeProperty(S_IFREG);
162180
162171
  };
162181
- Dirent22.prototype.isBlockDevice = function() {
162172
+ Dirent2.prototype.isBlockDevice = function() {
162182
162173
  return this._checkModeProperty(S_IFBLK);
162183
162174
  };
162184
- Dirent22.prototype.isCharacterDevice = function() {
162175
+ Dirent2.prototype.isCharacterDevice = function() {
162185
162176
  return this._checkModeProperty(S_IFCHR);
162186
162177
  };
162187
- Dirent22.prototype.isSymbolicLink = function() {
162178
+ Dirent2.prototype.isSymbolicLink = function() {
162188
162179
  return this._checkModeProperty(S_IFLNK);
162189
162180
  };
162190
- Dirent22.prototype.isFIFO = function() {
162181
+ Dirent2.prototype.isFIFO = function() {
162191
162182
  return this._checkModeProperty(S_IFIFO);
162192
162183
  };
162193
- Dirent22.prototype.isSocket = function() {
162184
+ Dirent2.prototype.isSocket = function() {
162194
162185
  return this._checkModeProperty(S_IFSOCK);
162195
162186
  };
162196
- return Dirent22;
162187
+ return Dirent2;
162197
162188
  }()
162198
162189
  );
162199
- exports2.Dirent = Dirent2;
162200
- exports2.default = Dirent2;
162190
+ exports2.Dirent = Dirent;
162191
+ exports2.default = Dirent;
162201
162192
  }
162202
162193
  });
162203
162194
  var require_setImmediate3 = __commonJS4({
@@ -168027,7 +168018,7 @@ var require_jsonfile4 = __commonJS4({
168027
168018
  }
168028
168019
  var universalify = require_universalify3();
168029
168020
  var { stringify, stripBom } = require_utils23();
168030
- async function _readFile2(file, options = {}) {
168021
+ async function _readFile(file, options = {}) {
168031
168022
  if (typeof options === "string") {
168032
168023
  options = { encoding: options };
168033
168024
  }
@@ -168048,7 +168039,7 @@ var require_jsonfile4 = __commonJS4({
168048
168039
  }
168049
168040
  return obj;
168050
168041
  }
168051
- var readFile22 = universalify.fromPromise(_readFile2);
168042
+ var readFile22 = universalify.fromPromise(_readFile);
168052
168043
  function readFileSync22(file, options = {}) {
168053
168044
  if (typeof options === "string") {
168054
168045
  options = { encoding: options };
@@ -228198,8 +228189,6 @@ function plugin_config(config) {
228198
228189
  return {
228199
228190
  client: "./src/client",
228200
228191
  defaultRouteBlocking: false,
228201
- pageQueryFilename: "+page.gql",
228202
- layoutQueryFilename: "+layout.gql",
228203
228192
  static: false,
228204
228193
  forceRunesMode: false,
228205
228194
  ...cfg,
@@ -228217,9 +228206,6 @@ function plugin_config(config) {
228217
228206
  };
228218
228207
  }
228219
228208
 
228220
- // src/plugin/kit.ts
228221
- var graphql41 = __toESM(require("graphql"), 1);
228222
-
228223
228209
  // ../houdini/build/vite-esm/index.js
228224
228210
  var import_module4 = require("module");
228225
228211
  var import_node_fs2 = require("node:fs");
@@ -231214,7 +231200,7 @@ var require_jsonfile5 = __commonJS5({
231214
231200
  }
231215
231201
  var universalify = require_universalify4();
231216
231202
  var { stringify, stripBom } = require_utils24();
231217
- async function _readFile2(file, options = {}) {
231203
+ async function _readFile(file, options = {}) {
231218
231204
  if (typeof options === "string") {
231219
231205
  options = { encoding: options };
231220
231206
  }
@@ -231235,7 +231221,7 @@ var require_jsonfile5 = __commonJS5({
231235
231221
  }
231236
231222
  return obj;
231237
231223
  }
231238
- var readFile22 = universalify.fromPromise(_readFile2);
231224
+ var readFile22 = universalify.fromPromise(_readFile);
231239
231225
  function readFileSync22(file, options = {}) {
231240
231226
  if (typeof options === "string") {
231241
231227
  options = { encoding: options };
@@ -231989,49 +231975,49 @@ var require_Dirent4 = __commonJS5({
231989
231975
  var S_IFLNK = constants_1.constants.S_IFLNK;
231990
231976
  var S_IFIFO = constants_1.constants.S_IFIFO;
231991
231977
  var S_IFSOCK = constants_1.constants.S_IFSOCK;
231992
- var Dirent2 = (
231978
+ var Dirent = (
231993
231979
  /** @class */
231994
231980
  function() {
231995
- function Dirent22() {
231981
+ function Dirent2() {
231996
231982
  this.name = "";
231997
231983
  this.mode = 0;
231998
231984
  }
231999
- Dirent22.build = function(link, encoding) {
232000
- var dirent = new Dirent22();
231985
+ Dirent2.build = function(link, encoding) {
231986
+ var dirent = new Dirent2();
232001
231987
  var mode = link.getNode().mode;
232002
231988
  dirent.name = (0, encoding_1.strToEncoding)(link.getName(), encoding);
232003
231989
  dirent.mode = mode;
232004
231990
  return dirent;
232005
231991
  };
232006
- Dirent22.prototype._checkModeProperty = function(property) {
231992
+ Dirent2.prototype._checkModeProperty = function(property) {
232007
231993
  return (this.mode & S_IFMT) === property;
232008
231994
  };
232009
- Dirent22.prototype.isDirectory = function() {
231995
+ Dirent2.prototype.isDirectory = function() {
232010
231996
  return this._checkModeProperty(S_IFDIR);
232011
231997
  };
232012
- Dirent22.prototype.isFile = function() {
231998
+ Dirent2.prototype.isFile = function() {
232013
231999
  return this._checkModeProperty(S_IFREG);
232014
232000
  };
232015
- Dirent22.prototype.isBlockDevice = function() {
232001
+ Dirent2.prototype.isBlockDevice = function() {
232016
232002
  return this._checkModeProperty(S_IFBLK);
232017
232003
  };
232018
- Dirent22.prototype.isCharacterDevice = function() {
232004
+ Dirent2.prototype.isCharacterDevice = function() {
232019
232005
  return this._checkModeProperty(S_IFCHR);
232020
232006
  };
232021
- Dirent22.prototype.isSymbolicLink = function() {
232007
+ Dirent2.prototype.isSymbolicLink = function() {
232022
232008
  return this._checkModeProperty(S_IFLNK);
232023
232009
  };
232024
- Dirent22.prototype.isFIFO = function() {
232010
+ Dirent2.prototype.isFIFO = function() {
232025
232011
  return this._checkModeProperty(S_IFIFO);
232026
232012
  };
232027
- Dirent22.prototype.isSocket = function() {
232013
+ Dirent2.prototype.isSocket = function() {
232028
232014
  return this._checkModeProperty(S_IFSOCK);
232029
232015
  };
232030
- return Dirent22;
232016
+ return Dirent2;
232031
232017
  }()
232032
232018
  );
232033
- exports2.Dirent = Dirent2;
232034
- exports2.default = Dirent2;
232019
+ exports2.Dirent = Dirent;
232020
+ exports2.default = Dirent;
232035
232021
  }
232036
232022
  });
232037
232023
  var require_setImmediate4 = __commonJS5({
@@ -300249,7 +300235,9 @@ filepath: ${filepath}`
300249
300235
  load.push(element.quasi.quasis[0].value.raw);
300250
300236
  } else if (element.type === "CallExpression") {
300251
300237
  if (element.callee.type !== "Identifier" || element.callee.name !== "graphql" || element.arguments.length !== 1) {
300252
- throw new Error(`only graphql function can be passed to ${houdini_load_fn}`);
300238
+ throw new Error(
300239
+ `only graphql function can be passed to ${houdini_load_fn}. Filepath: ${filepath}`
300240
+ );
300253
300241
  }
300254
300242
  let documentString;
300255
300243
  const argument = element.arguments[0];
@@ -300357,18 +300345,6 @@ function is_layout3(framework2, filename) {
300357
300345
  function is_component(config, framework2, filename) {
300358
300346
  return framework2 === "svelte" || filename.endsWith(".svelte") && !is_route_script(framework2, filename) && !is_route(config, framework2, filename);
300359
300347
  }
300360
- function page_query_path(config, filename) {
300361
- return path_exports.join(
300362
- path_exports.dirname(resolve_relative(config, filename)),
300363
- plugin_config(config).pageQueryFilename
300364
- );
300365
- }
300366
- function layout_query_path(config, filename) {
300367
- return path_exports.join(
300368
- path_exports.dirname(resolve_relative(config, filename)),
300369
- plugin_config(config).layoutQueryFilename
300370
- );
300371
- }
300372
300348
  function resolve_relative(config, filename) {
300373
300349
  const match5 = filename.match("^((../)+)src/routes");
300374
300350
  if (match5) {
@@ -300478,32 +300454,6 @@ async function walk_routes(config, framework2, visitor, dirpath = config.routesD
300478
300454
  componentQueries.push({ query: definition, componentPath: childPath });
300479
300455
  }
300480
300456
  });
300481
- } else if (child === plugin_config(config).layoutQueryFilename) {
300482
- validRoute = true;
300483
- const contents = await fs_exports.readFile(childPath);
300484
- if (!contents) {
300485
- continue;
300486
- }
300487
- try {
300488
- const query = config.extractQueryDefinition(graphql41.parse(contents));
300489
- await visitor.routeLayoutQuery?.(query, childPath);
300490
- layoutQueries.push(query);
300491
- } catch (e3) {
300492
- throw routeQueryError(childPath);
300493
- }
300494
- } else if (child === plugin_config(config).pageQueryFilename) {
300495
- validRoute = true;
300496
- const contents = await fs_exports.readFile(childPath);
300497
- if (!contents) {
300498
- continue;
300499
- }
300500
- try {
300501
- const query = config.extractQueryDefinition(graphql41.parse(contents));
300502
- await visitor.routePageQuery?.(query, childPath);
300503
- pageQueries.push(query);
300504
- } catch (e3) {
300505
- throw routeQueryError(childPath);
300506
- }
300507
300457
  } else {
300508
300458
  continue;
300509
300459
  }
@@ -300535,10 +300485,6 @@ async function walk_routes(config, framework2, visitor, dirpath = config.routesD
300535
300485
  );
300536
300486
  }
300537
300487
  }
300538
- var routeQueryError = (filepath) => ({
300539
- filepath,
300540
- message: "route query error"
300541
- });
300542
300488
  function route_page_path(config, filename) {
300543
300489
  return resolve_relative(config, filename).replace(".js", ".svelte").replace(".ts", ".svelte");
300544
300490
  }
@@ -301230,180 +301176,12 @@ async function codegen_default(input) {
301230
301176
  ]);
301231
301177
  }
301232
301178
 
301233
- // src/plugin/fsPatch.ts
301234
- var import_node_fs3 = __toESM(require("node:fs"), 1);
301235
- var import_promises9 = __toESM(require("node:fs/promises"), 1);
301236
-
301237
301179
  // src/plugin/state.ts
301238
301180
  var _config;
301239
301181
  function setConfig(config) {
301240
301182
  _config = config;
301241
301183
  }
301242
301184
 
301243
- // src/plugin/fsPatch.ts
301244
- var fsPatch_default = (getFramework) => ({
301245
- async resolveId(filepath, _, { config, isEntry }) {
301246
- if (!isEntry) {
301247
- const match5 = filepath.match("^((../)+)src/routes");
301248
- if (match5) {
301249
- return path_exports.join(config.projectRoot, filepath.substring(match5[1].length));
301250
- }
301251
- return filepath.startsWith("/src") ? { id: path_exports.join(config.projectRoot, filepath) } : null;
301252
- }
301253
- filepath = path_exports.posixify(filepath.toString());
301254
- if (is_route_script(getFramework(), filepath) || is_root_layout(config, filepath) || is_root_layout_server(config, filepath)) {
301255
- return {
301256
- id: resolve_relative(config, filepath)
301257
- };
301258
- }
301259
- },
301260
- load: async (filepath, { config }) => {
301261
- filepath = path_exports.posixify(filepath.toString());
301262
- if (is_route_script(getFramework(), filepath) || is_root_layout_server(config, filepath)) {
301263
- filepath = resolve_relative(config, filepath);
301264
- return {
301265
- code: await fs_exports.readFile(filepath) || await fs_exports.readFile(path_exports.join(config.projectRoot, filepath)) || ""
301266
- };
301267
- }
301268
- if (is_root_layout(config, filepath)) {
301269
- filepath = resolve_relative(config, filepath);
301270
- return {
301271
- code: await fs_exports.readFile(filepath) || await fs_exports.readFile(path_exports.join(config.projectRoot, filepath)) || empty_layout
301272
- };
301273
- }
301274
- }
301275
- });
301276
- var _readDirSync = import_node_fs3.default.readdirSync;
301277
- var _statSync = import_node_fs3.default.statSync;
301278
- var _readFileSync = import_node_fs3.default.readFileSync;
301279
- var _unlinkSync = import_node_fs3.default.unlinkSync;
301280
- function getStringFilepath(fp) {
301281
- if (fp instanceof URL) {
301282
- return fp.pathname;
301283
- }
301284
- return fp.toString();
301285
- }
301286
- import_node_fs3.default.readFileSync = function(fp, options) {
301287
- const filepath = getStringFilepath(fp);
301288
- if (filepath.endsWith("+page.js") || filepath.endsWith("+layout.js") || filepath.replace(".ts", ".js").endsWith("+layout.server.js")) {
301289
- try {
301290
- return _readFileSync(fp, options);
301291
- } catch {
301292
- return typeof options === "string" || options?.encoding ? "" : Buffer.from("");
301293
- }
301294
- }
301295
- if (filepath.endsWith(path_exports.join("src", "routes", "+layout.svelte"))) {
301296
- try {
301297
- return _readFileSync(fp, options);
301298
- } catch {
301299
- return typeof options === "string" || options?.encoding ? empty_layout : Buffer.from(empty_layout);
301300
- }
301301
- }
301302
- return _readFileSync(fp, options);
301303
- };
301304
- import_node_fs3.default.statSync = function(fp, options) {
301305
- let filepath = getStringFilepath(fp);
301306
- if (!filepath.includes("routes") || !path_exports.basename(filepath).startsWith("+")) {
301307
- return _statSync(fp, options);
301308
- }
301309
- try {
301310
- const result = _statSync(fp, options);
301311
- return result;
301312
- } catch (error) {
301313
- filepath = path_exports.posixify(filepath);
301314
- const mock5 = virtual_file(path_exports.basename(filepath), { withFileTypes: true });
301315
- if (filepath.endsWith(path_exports.join("routes", "+layout.svelte")) || filepath.endsWith(path_exports.join("routes", "+layout.svelte")) || filepath.endsWith(path_exports.join("routes", "+layout.server.js")) || filepath.endsWith(path_exports.join("routes", "+layout.server.js"))) {
301316
- return mock5;
301317
- } else if (filepath.endsWith("+layout.js")) {
301318
- return mock5;
301319
- } else if (filepath.endsWith("+page.js")) {
301320
- return mock5;
301321
- }
301322
- throw error;
301323
- }
301324
- };
301325
- import_node_fs3.default.unlinkSync = function(filepath) {
301326
- try {
301327
- _unlinkSync(filepath);
301328
- } catch {
301329
- }
301330
- };
301331
- import_node_fs3.default.readdirSync = function(fp, options) {
301332
- const filepath = getStringFilepath(fp);
301333
- if (!filepath.includes("routes")) return _readDirSync(fp, options);
301334
- const result = _readDirSync(fp, options);
301335
- const file_names = result.map((file) => {
301336
- if (file instanceof import_node_fs3.Dirent) {
301337
- return file.name;
301338
- } else if (typeof file === "string") {
301339
- return file;
301340
- } else {
301341
- return "";
301342
- }
301343
- });
301344
- function contains(...names) {
301345
- return names.some((name) => file_names.includes(name));
301346
- }
301347
- if (contains("+page.svelte", "+page.gql") && !contains("+page.js", "+page.ts")) {
301348
- result.push(virtual_file("+page.js", options));
301349
- }
301350
- const posix_filepath = path_exports.posixify(filepath);
301351
- if ((is_root_route(posix_filepath) || contains("+layout.svelte", "+layout.gql")) && !contains("+layout.ts", "+layout.js")) {
301352
- result.push(virtual_file("+layout.js", options));
301353
- }
301354
- if (is_root_route(posix_filepath) && !contains("+layout.svelte")) {
301355
- result.push(virtual_file("+layout.svelte", options));
301356
- }
301357
- if (is_root_route(posix_filepath) && !contains("+layout.server.js", "+layout.server.ts") && !plugin_config(_config).static) {
301358
- result.push(virtual_file("+layout.server.js", options));
301359
- }
301360
- return result;
301361
- };
301362
- Object.defineProperty(globalThis, "fs", {
301363
- configurable: true,
301364
- enumerable: true,
301365
- value: import_node_fs3.default
301366
- });
301367
- var _readFile = import_promises9.default.readFile;
301368
- import_promises9.default.readFile = async (path7, options) => {
301369
- if (path7.toString().endsWith("+layout.svelte")) {
301370
- try {
301371
- return await _readFile(path7, options);
301372
- } catch {
301373
- return typeof options === "string" || options?.encoding ? empty_layout : Buffer.from(empty_layout);
301374
- }
301375
- }
301376
- return _readFile(path7, options);
301377
- };
301378
- Object.defineProperty(globalThis, "fs/promises", {
301379
- configurable: true,
301380
- enumerable: true,
301381
- value: import_promises9.default
301382
- });
301383
- function virtual_file(name, options) {
301384
- return !options?.withFileTypes ? name : {
301385
- name,
301386
- isFile: () => true,
301387
- isDirectory: () => false,
301388
- isBlockDevice: () => false,
301389
- isFIFO: () => false,
301390
- isCharacterDevice: () => false,
301391
- isSocket: () => false,
301392
- isSymbolicLink: () => false
301393
- };
301394
- }
301395
- function is_root_route(filepath) {
301396
- filepath = filepath.toString();
301397
- if (filepath.toString().endsWith("/")) {
301398
- filepath = filepath.slice(0, -1);
301399
- }
301400
- return filepath.endsWith(path_exports.join("src", "routes")) && // ignore the src/routes that exists in the type roots
301401
- !filepath.includes(".svelte-kit") && // ! Hey! This second value always needs to correspond to the default value for the runtimeDir
301402
- // if you're changing this here, please also update it in `/packages/houdini/src/lib/config.ts`
301403
- !filepath.includes(_config.runtimeDir ?? "$houdini");
301404
- }
301405
- var empty_layout = "<slot />";
301406
-
301407
301185
  // src/plugin/transforms/index.ts
301408
301186
  var recast25 = __toESM(require_main6(), 1);
301409
301187
 
@@ -301714,7 +301492,6 @@ async function kit_init(page) {
301714
301492
  }
301715
301493
 
301716
301494
  // src/plugin/transforms/kit/load.ts
301717
- var graphql45 = __toESM(require("graphql"), 1);
301718
301495
  var recast19 = __toESM(require_main6(), 1);
301719
301496
  var AST20 = recast19.types.builders;
301720
301497
  async function kit_load_generator(page) {
@@ -301729,9 +301506,7 @@ async function kit_load_generator(page) {
301729
301506
  page,
301730
301507
  artifact: { name }
301731
301508
  }).id;
301732
- const [page_query, layout_query, inline_queries, page_info] = await Promise.all([
301733
- find_special_query("Page", page),
301734
- find_special_query("Layout", page),
301509
+ const [inline_queries, page_info] = await Promise.all([
301735
301510
  find_inline_queries(
301736
301511
  page,
301737
301512
  // if we are currently on the route file, there's nothing to parse
@@ -301750,12 +301525,6 @@ async function kit_load_generator(page) {
301750
301525
  if (script) {
301751
301526
  const queries_that_needs_a_load = [...houdini_load_queries, ...inline_queries];
301752
301527
  const isLayout = is_layout3(page.framework, page.filepath);
301753
- if (isLayout && layout_query) {
301754
- queries_that_needs_a_load.push(layout_query);
301755
- }
301756
- if (!isLayout && page_query) {
301757
- queries_that_needs_a_load.push(page_query);
301758
- }
301759
301528
  add_load({
301760
301529
  page,
301761
301530
  queries: queries_that_needs_a_load,
@@ -302002,22 +301771,6 @@ function add_load({
302002
301771
  );
302003
301772
  }
302004
301773
  }
302005
- async function find_special_query(type, page) {
302006
- const query_path = type === "Page" ? page_query_path(page.config, page.filepath) : layout_query_path(page.config, page.filepath);
302007
- const contents = await fs_exports.readFile(query_path);
302008
- if (!contents) {
302009
- return null;
302010
- }
302011
- const parsed = graphql45.parse(contents);
302012
- const definition = parsed.definitions.find(
302013
- (defn) => defn.kind === "OperationDefinition" && defn.operation === "query"
302014
- );
302015
- if (!definition) {
302016
- formatErrors({ message: "gql file must contain a query.", filepath: query_path });
302017
- return null;
302018
- }
302019
- return definition;
302020
- }
302021
301774
  function load_hook_statements(name, request_context, input_id, result_id) {
302022
301775
  return AST20.expressionStatement(
302023
301776
  AST20.awaitExpression(
@@ -302378,7 +302131,6 @@ function replace_tag_content(source, start, end, insert) {
302378
302131
  var replace_between = (origin, startIndex, endIndex, insertion) => origin.substring(0, startIndex) + insertion + origin.substring(endIndex);
302379
302132
 
302380
302133
  // src/plugin/validate.ts
302381
- var graphql46 = __toESM(require("graphql"), 1);
302382
302134
  async function validate4({
302383
302135
  config,
302384
302136
  documents
@@ -302405,28 +302157,6 @@ async function validate4({
302405
302157
  })
302406
302158
  );
302407
302159
  }
302408
- graphql46.visit(doc.document, {
302409
- Directive(node, _, __, ___, ancestors) {
302410
- const blockingDirectives = [
302411
- config.blockingDirective,
302412
- config.blockingDisableDirective
302413
- ];
302414
- if (!blockingDirectives.includes(node.name.value)) {
302415
- return;
302416
- }
302417
- const { definition } = definitionFromAncestors(ancestors);
302418
- const listDirective = definition.directives?.map((c) => c.name.value) ?? [];
302419
- if (listDirective.includes(config.blockingDirective) && listDirective.includes(config.blockingDisableDirective)) {
302420
- errors.push(
302421
- new HoudiniError({
302422
- filepath: doc.filename,
302423
- message: `You can't apply both @${config.blockingDirective} and @${config.blockingDisableDirective} at the same time`
302424
- })
302425
- );
302426
- }
302427
- return;
302428
- }
302429
- });
302430
302160
  }
302431
302161
  if (errors.length > 0) {
302432
302162
  throw errors;
@@ -302485,24 +302215,6 @@ export const redirect = svelteKitRedirect
302485
302215
  artifactData,
302486
302216
  // custom logic to pull a graphql document out of a svelte file
302487
302217
  extractDocuments: extract_default,
302488
- schema({ config }) {
302489
- return `
302490
- """
302491
- @${config.loadDirective} is used to enable automatic fetch on inline queries.
302492
- """
302493
- directive @${config.loadDirective} on QUERY
302494
-
302495
- """
302496
- @${config.blockingDirective} is used to always await the fetch.
302497
- """
302498
- directive @${config.blockingDirective} on QUERY
302499
-
302500
- """
302501
- @${config.blockingDisableDirective} is used to not always await the fetch (in CSR for example). Note that "throwOnError" will not throw in this case.
302502
- """
302503
- directive @${config.blockingDisableDirective} on QUERY
302504
- `;
302505
- },
302506
302218
  // we have some custom document validation logic
302507
302219
  validate: validate4,
302508
302220
  // we need to write the svelte specific runtime
@@ -302540,10 +302252,6 @@ directive @${config.blockingDisableDirective} on QUERY
302540
302252
  include({ config, filepath }) {
302541
302253
  return config.includeFile(resolve_relative(config, filepath), { ignore_plugins: true });
302542
302254
  },
302543
- // add custom vite config
302544
- vite: {
302545
- ...fsPatch_default(() => framework)
302546
- },
302547
302255
  /**
302548
302256
  * Setup
302549
302257
  */
@@ -302645,8 +302353,6 @@ async function route_test({
302645
302353
  await Promise.all([
302646
302354
  fs_exports.writeFile(page_path, component),
302647
302355
  fs_exports.writeFile(route_data_path(config, page_path), script),
302648
- fs_exports.writeFile(page_query_path(config, page_path), page_query),
302649
- fs_exports.writeFile(layout_query_path(config, page_path), layout_query),
302650
302356
  fs_exports.writeFile(layout_path, layout),
302651
302357
  fs_exports.writeFile(layout_script_path, layout_script)
302652
302358
  ]);