@platformatic/basic 2.0.0-alpha.3 → 2.0.0-alpha.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.
Files changed (69) hide show
  1. package/config.d.ts +159 -0
  2. package/eslint.config.js +3 -1
  3. package/index.js +15 -2
  4. package/lib/base.js +7 -5
  5. package/lib/errors.js +8 -0
  6. package/lib/next.js +105 -0
  7. package/lib/schema.js +23 -0
  8. package/lib/server.js +8 -9
  9. package/lib/utils.js +5 -34
  10. package/lib/vite.js +105 -0
  11. package/lib/worker/child-manager.js +78 -0
  12. package/lib/worker/child-process.js +84 -0
  13. package/lib/worker/next-loader.js +137 -0
  14. package/lib/worker/server-listener.js +29 -0
  15. package/package.json +22 -8
  16. package/schema.json +522 -0
  17. package/test/express.test.js +9 -9
  18. package/test/fastify.test.js +9 -9
  19. package/test/fixtures/next/composer-autodetect-prefix/next.config.mjs +5 -0
  20. package/test/fixtures/next/composer-autodetect-prefix/package.json +15 -0
  21. package/test/fixtures/next/composer-autodetect-prefix/platformatic.application.json +8 -0
  22. package/test/fixtures/next/composer-autodetect-prefix/platformatic.runtime.json +21 -0
  23. package/test/fixtures/next/composer-autodetect-prefix/src/app/layout.js +7 -0
  24. package/test/fixtures/next/composer-autodetect-prefix/src/app/page.js +5 -0
  25. package/test/fixtures/next/composer-with-prefix/next.config.js +1 -0
  26. package/test/fixtures/next/composer-with-prefix/package.json +15 -0
  27. package/test/fixtures/next/composer-with-prefix/platformatic.application.json +11 -0
  28. package/test/fixtures/next/composer-with-prefix/platformatic.runtime.json +21 -0
  29. package/test/fixtures/next/composer-with-prefix/src/app/layout.js +7 -0
  30. package/test/fixtures/next/composer-with-prefix/src/app/page.js +5 -0
  31. package/test/fixtures/next/composer-without-prefix/next.config.mjs +3 -0
  32. package/test/fixtures/next/composer-without-prefix/package.json +15 -0
  33. package/test/fixtures/next/composer-without-prefix/platformatic.application.json +8 -0
  34. package/test/fixtures/next/composer-without-prefix/platformatic.runtime.json +21 -0
  35. package/test/fixtures/next/composer-without-prefix/src/app/layout.js +7 -0
  36. package/test/fixtures/next/composer-without-prefix/src/app/page.js +5 -0
  37. package/test/fixtures/next/standalone/next.config.mjs +3 -0
  38. package/test/fixtures/next/standalone/package.json +15 -0
  39. package/test/fixtures/next/standalone/platformatic.runtime.json +18 -0
  40. package/test/fixtures/next/standalone/src/app/layout.js +7 -0
  41. package/test/fixtures/next/standalone/src/app/page.js +5 -0
  42. package/test/fixtures/platformatic-composer/platformatic.composer.json +20 -0
  43. package/test/fixtures/platformatic-composer/platformatic.no-prefix.composer.json +23 -0
  44. package/test/fixtures/platformatic-composer/plugin.js +9 -0
  45. package/test/fixtures/vite/composer-autodetect-prefix/custom.vite.config.js +3 -0
  46. package/test/fixtures/vite/composer-autodetect-prefix/index.html +13 -0
  47. package/test/fixtures/vite/composer-autodetect-prefix/main.js +3 -0
  48. package/test/fixtures/vite/composer-autodetect-prefix/package.json +14 -0
  49. package/test/fixtures/vite/composer-autodetect-prefix/platformatic.application.json +11 -0
  50. package/test/fixtures/vite/composer-autodetect-prefix/platformatic.runtime.json +21 -0
  51. package/test/fixtures/vite/composer-with-prefix/index.html +13 -0
  52. package/test/fixtures/vite/composer-with-prefix/main.js +3 -0
  53. package/test/fixtures/vite/composer-with-prefix/package.json +14 -0
  54. package/test/fixtures/vite/composer-with-prefix/platformatic.application.json +11 -0
  55. package/test/fixtures/vite/composer-with-prefix/platformatic.runtime.json +21 -0
  56. package/test/fixtures/vite/composer-without-prefix/index.html +13 -0
  57. package/test/fixtures/vite/composer-without-prefix/main.js +3 -0
  58. package/test/fixtures/vite/composer-without-prefix/package.json +14 -0
  59. package/test/fixtures/vite/composer-without-prefix/platformatic.application.json +8 -0
  60. package/test/fixtures/vite/composer-without-prefix/platformatic.runtime.json +21 -0
  61. package/test/fixtures/vite/standalone/custom.vite.config.js +3 -0
  62. package/test/fixtures/vite/standalone/index.html +13 -0
  63. package/test/fixtures/vite/standalone/main.js +3 -0
  64. package/test/fixtures/vite/standalone/package.json +14 -0
  65. package/test/fixtures/vite/standalone/platformatic.runtime.json +18 -0
  66. package/test/helper.js +85 -14
  67. package/test/next.test.js +85 -0
  68. package/test/node.test.js +13 -13
  69. package/test/vite.test.js +89 -0
package/schema.json ADDED
@@ -0,0 +1,522 @@
1
+ {
2
+ "$id": "https://schemas.platformatic.dev/@platformatic/basic/2.0.0-alpha.4.json",
3
+ "$schema": "http://json-schema.org/draft-07/schema#",
4
+ "title": "Platformatic Stackable",
5
+ "type": "object",
6
+ "properties": {
7
+ "$schema": {
8
+ "type": "string"
9
+ },
10
+ "server": {
11
+ "type": "object",
12
+ "properties": {
13
+ "hostname": {
14
+ "type": "string"
15
+ },
16
+ "port": {
17
+ "anyOf": [
18
+ {
19
+ "type": "integer"
20
+ },
21
+ {
22
+ "type": "string"
23
+ }
24
+ ]
25
+ },
26
+ "pluginTimeout": {
27
+ "type": "integer"
28
+ },
29
+ "healthCheck": {
30
+ "anyOf": [
31
+ {
32
+ "type": "boolean"
33
+ },
34
+ {
35
+ "type": "object",
36
+ "properties": {
37
+ "enabled": {
38
+ "type": "boolean"
39
+ },
40
+ "interval": {
41
+ "type": "integer"
42
+ }
43
+ },
44
+ "additionalProperties": true
45
+ }
46
+ ]
47
+ },
48
+ "ignoreTrailingSlash": {
49
+ "type": "boolean"
50
+ },
51
+ "ignoreDuplicateSlashes": {
52
+ "type": "boolean"
53
+ },
54
+ "connectionTimeout": {
55
+ "type": "integer"
56
+ },
57
+ "keepAliveTimeout": {
58
+ "type": "integer",
59
+ "default": 5000
60
+ },
61
+ "maxRequestsPerSocket": {
62
+ "type": "integer"
63
+ },
64
+ "forceCloseConnections": {
65
+ "anyOf": [
66
+ {
67
+ "type": "boolean"
68
+ },
69
+ {
70
+ "type": "string",
71
+ "pattern": "^idle$"
72
+ }
73
+ ]
74
+ },
75
+ "requestTimeout": {
76
+ "type": "integer"
77
+ },
78
+ "bodyLimit": {
79
+ "type": "integer"
80
+ },
81
+ "maxParamLength": {
82
+ "type": "integer"
83
+ },
84
+ "disableRequestLogging": {
85
+ "type": "boolean"
86
+ },
87
+ "exposeHeadRoutes": {
88
+ "type": "boolean"
89
+ },
90
+ "logger": {
91
+ "anyOf": [
92
+ {
93
+ "type": "boolean"
94
+ },
95
+ {
96
+ "type": "object",
97
+ "properties": {
98
+ "level": {
99
+ "type": "string"
100
+ },
101
+ "transport": {
102
+ "anyOf": [
103
+ {
104
+ "type": "object",
105
+ "properties": {
106
+ "target": {
107
+ "type": "string",
108
+ "resolveModule": true
109
+ },
110
+ "options": {
111
+ "type": "object"
112
+ }
113
+ },
114
+ "additionalProperties": false
115
+ },
116
+ {
117
+ "type": "object",
118
+ "properties": {
119
+ "targets": {
120
+ "type": "array",
121
+ "items": {
122
+ "type": "object",
123
+ "properties": {
124
+ "target": {
125
+ "type": "string",
126
+ "resolveModule": true
127
+ },
128
+ "options": {
129
+ "type": "object"
130
+ },
131
+ "level": {
132
+ "type": "string"
133
+ },
134
+ "additionalProperties": false
135
+ }
136
+ }
137
+ },
138
+ "options": {
139
+ "type": "object"
140
+ }
141
+ },
142
+ "additionalProperties": false
143
+ }
144
+ ]
145
+ },
146
+ "pipeline": {
147
+ "type": "object",
148
+ "properties": {
149
+ "target": {
150
+ "type": "string",
151
+ "resolveModule": true
152
+ },
153
+ "options": {
154
+ "type": "object"
155
+ }
156
+ },
157
+ "additionalProperties": false
158
+ }
159
+ },
160
+ "additionalProperties": true
161
+ }
162
+ ]
163
+ },
164
+ "serializerOpts": {
165
+ "type": "object",
166
+ "properties": {
167
+ "schema": {
168
+ "type": "object"
169
+ },
170
+ "ajv": {
171
+ "type": "object"
172
+ },
173
+ "rounding": {
174
+ "type": "string",
175
+ "enum": [
176
+ "floor",
177
+ "ceil",
178
+ "round",
179
+ "trunc"
180
+ ],
181
+ "default": "trunc"
182
+ },
183
+ "debugMode": {
184
+ "type": "boolean"
185
+ },
186
+ "mode": {
187
+ "type": "string",
188
+ "enum": [
189
+ "debug",
190
+ "standalone"
191
+ ]
192
+ },
193
+ "largeArraySize": {
194
+ "anyOf": [
195
+ {
196
+ "type": "integer"
197
+ },
198
+ {
199
+ "type": "string"
200
+ }
201
+ ],
202
+ "default": 20000
203
+ },
204
+ "largeArrayMechanism": {
205
+ "type": "string",
206
+ "enum": [
207
+ "default",
208
+ "json-stringify"
209
+ ],
210
+ "default": "default"
211
+ }
212
+ }
213
+ },
214
+ "caseSensitive": {
215
+ "type": "boolean"
216
+ },
217
+ "requestIdHeader": {
218
+ "anyOf": [
219
+ {
220
+ "type": "string"
221
+ },
222
+ {
223
+ "type": "boolean",
224
+ "const": false
225
+ }
226
+ ]
227
+ },
228
+ "requestIdLogLabel": {
229
+ "type": "string"
230
+ },
231
+ "jsonShorthand": {
232
+ "type": "boolean"
233
+ },
234
+ "trustProxy": {
235
+ "anyOf": [
236
+ {
237
+ "type": "boolean"
238
+ },
239
+ {
240
+ "type": "string"
241
+ },
242
+ {
243
+ "type": "array",
244
+ "items": {
245
+ "type": "string"
246
+ }
247
+ },
248
+ {
249
+ "type": "integer"
250
+ }
251
+ ]
252
+ },
253
+ "http2": {
254
+ "type": "boolean"
255
+ },
256
+ "https": {
257
+ "type": "object",
258
+ "properties": {
259
+ "allowHTTP1": {
260
+ "type": "boolean"
261
+ },
262
+ "key": {
263
+ "anyOf": [
264
+ {
265
+ "type": "string"
266
+ },
267
+ {
268
+ "type": "object",
269
+ "properties": {
270
+ "path": {
271
+ "type": "string",
272
+ "resolvePath": true
273
+ }
274
+ },
275
+ "additionalProperties": false
276
+ },
277
+ {
278
+ "type": "array",
279
+ "items": {
280
+ "anyOf": [
281
+ {
282
+ "type": "string"
283
+ },
284
+ {
285
+ "type": "object",
286
+ "properties": {
287
+ "path": {
288
+ "type": "string",
289
+ "resolvePath": true
290
+ }
291
+ },
292
+ "additionalProperties": false
293
+ }
294
+ ]
295
+ }
296
+ }
297
+ ]
298
+ },
299
+ "cert": {
300
+ "anyOf": [
301
+ {
302
+ "type": "string"
303
+ },
304
+ {
305
+ "type": "object",
306
+ "properties": {
307
+ "path": {
308
+ "type": "string",
309
+ "resolvePath": true
310
+ }
311
+ },
312
+ "additionalProperties": false
313
+ },
314
+ {
315
+ "type": "array",
316
+ "items": {
317
+ "anyOf": [
318
+ {
319
+ "type": "string"
320
+ },
321
+ {
322
+ "type": "object",
323
+ "properties": {
324
+ "path": {
325
+ "type": "string",
326
+ "resolvePath": true
327
+ }
328
+ },
329
+ "additionalProperties": false
330
+ }
331
+ ]
332
+ }
333
+ }
334
+ ]
335
+ },
336
+ "requestCert": {
337
+ "type": "boolean"
338
+ },
339
+ "rejectUnauthorized": {
340
+ "type": "boolean"
341
+ }
342
+ },
343
+ "additionalProperties": false,
344
+ "required": [
345
+ "key",
346
+ "cert"
347
+ ]
348
+ },
349
+ "cors": {
350
+ "type": "object",
351
+ "$comment": "See https://github.com/fastify/fastify-cors",
352
+ "properties": {
353
+ "origin": {
354
+ "anyOf": [
355
+ {
356
+ "type": "boolean"
357
+ },
358
+ {
359
+ "type": "string"
360
+ },
361
+ {
362
+ "type": "array",
363
+ "items": {
364
+ "anyOf": [
365
+ {
366
+ "type": "string"
367
+ },
368
+ {
369
+ "type": "object",
370
+ "properties": {
371
+ "regexp": {
372
+ "type": "string"
373
+ }
374
+ },
375
+ "required": [
376
+ "regexp"
377
+ ]
378
+ }
379
+ ]
380
+ }
381
+ },
382
+ {
383
+ "type": "object",
384
+ "properties": {
385
+ "regexp": {
386
+ "type": "string"
387
+ }
388
+ },
389
+ "required": [
390
+ "regexp"
391
+ ]
392
+ }
393
+ ]
394
+ },
395
+ "methods": {
396
+ "type": "array",
397
+ "items": {
398
+ "type": "string"
399
+ }
400
+ },
401
+ "allowedHeaders": {
402
+ "type": "string",
403
+ "description": "Comma separated string of allowed headers."
404
+ },
405
+ "exposedHeaders": {
406
+ "anyOf": [
407
+ {
408
+ "type": "array",
409
+ "items": {
410
+ "type": "string"
411
+ }
412
+ },
413
+ {
414
+ "type": "string",
415
+ "description": "Comma separated string of exposed headers."
416
+ }
417
+ ]
418
+ },
419
+ "credentials": {
420
+ "type": "boolean"
421
+ },
422
+ "maxAge": {
423
+ "type": "integer"
424
+ },
425
+ "preflightContinue": {
426
+ "type": "boolean",
427
+ "default": false
428
+ },
429
+ "optionsSuccessStatus": {
430
+ "type": "integer",
431
+ "default": 204
432
+ },
433
+ "preflight": {
434
+ "type": "boolean",
435
+ "default": true
436
+ },
437
+ "strictPreflight": {
438
+ "type": "boolean",
439
+ "default": true
440
+ },
441
+ "hideOptionsRoute": {
442
+ "type": "boolean",
443
+ "default": true
444
+ }
445
+ },
446
+ "additionalProperties": false
447
+ }
448
+ },
449
+ "additionalProperties": false
450
+ },
451
+ "watch": {
452
+ "anyOf": [
453
+ {
454
+ "type": "object",
455
+ "properties": {
456
+ "enabled": {
457
+ "default": true,
458
+ "anyOf": [
459
+ {
460
+ "type": "boolean"
461
+ },
462
+ {
463
+ "type": "string"
464
+ }
465
+ ]
466
+ },
467
+ "allow": {
468
+ "type": "array",
469
+ "items": {
470
+ "type": "string"
471
+ },
472
+ "minItems": 1,
473
+ "nullable": true,
474
+ "default": null
475
+ },
476
+ "ignore": {
477
+ "type": "array",
478
+ "items": {
479
+ "type": "string"
480
+ },
481
+ "nullable": true,
482
+ "default": null
483
+ }
484
+ },
485
+ "additionalProperties": false
486
+ },
487
+ {
488
+ "type": "boolean"
489
+ },
490
+ {
491
+ "type": "string"
492
+ }
493
+ ]
494
+ },
495
+ "application": {
496
+ "type": "object",
497
+ "properties": {
498
+ "base": {
499
+ "type": "string"
500
+ }
501
+ },
502
+ "additionalProperties": false
503
+ },
504
+ "vite": {
505
+ "type": "object",
506
+ "properties": {
507
+ "configFile": {
508
+ "oneOf": [
509
+ {
510
+ "type": "string"
511
+ },
512
+ {
513
+ "type": "boolean"
514
+ }
515
+ ]
516
+ }
517
+ },
518
+ "additionalProperties": false
519
+ }
520
+ },
521
+ "additionalProperties": false
522
+ }
@@ -1,33 +1,33 @@
1
1
  import { ifError } from 'node:assert'
2
2
  import { test } from 'node:test'
3
- import { createRuntime, verifyViaHTTP, verifyViaInject } from './helper.js'
3
+ import { createRuntime, verifyJSONViaHTTP, verifyJSONViaInject } from './helper.js'
4
4
 
5
5
  test('can detect and start an express application with no build function defined', async t => {
6
6
  const { runtime, url } = await createRuntime(t, 'express/no-build/platformatic.as-entrypoint.runtime.json')
7
7
 
8
- await verifyViaHTTP(url, '/direct', 200, { ok: true })
9
- await verifyViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
8
+ await verifyJSONViaHTTP(url, '/direct', 200, { ok: true })
9
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
10
10
  })
11
11
 
12
12
  test('can detect and start an express application with no build function and when not the entrypoint', async t => {
13
13
  const { runtime, url } = await createRuntime(t, 'express/no-build/platformatic.no-entrypoint.runtime.json')
14
14
 
15
- await verifyViaHTTP(url, '/mesh', 200, { ok: true })
16
- await verifyViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
15
+ await verifyJSONViaHTTP(url, '/mesh', 200, { ok: true })
16
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
17
17
  })
18
18
 
19
19
  test('can detect and start an express application with build function defined', async t => {
20
20
  const { runtime, url } = await createRuntime(t, 'express/with-build/platformatic.as-entrypoint.runtime.json')
21
21
 
22
- await verifyViaHTTP(url, '/direct', 200, { ok: true })
23
- await verifyViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
22
+ await verifyJSONViaHTTP(url, '/direct', 200, { ok: true })
23
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
24
24
  })
25
25
 
26
26
  test('can detect and start an express applicationwith build function defined and when not the entrypoint', async t => {
27
27
  const { runtime, url } = await createRuntime(t, 'express/no-build/platformatic.no-entrypoint.runtime.json')
28
28
 
29
- await verifyViaHTTP(url, '/mesh', 200, { ok: true })
30
- await verifyViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
29
+ await verifyJSONViaHTTP(url, '/mesh', 200, { ok: true })
30
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
31
31
 
32
32
  const details = await runtime.getServiceDetails('internal')
33
33
  ifError(details.url)
@@ -1,33 +1,33 @@
1
1
  import { ifError } from 'node:assert'
2
2
  import { test } from 'node:test'
3
- import { createRuntime, verifyViaHTTP, verifyViaInject } from './helper.js'
3
+ import { createRuntime, verifyJSONViaHTTP, verifyJSONViaInject } from './helper.js'
4
4
 
5
5
  test('can detect and start a fastify application with no build function defined', async t => {
6
6
  const { runtime, url } = await createRuntime(t, 'fastify/no-build/platformatic.as-entrypoint.runtime.json')
7
7
 
8
- await verifyViaHTTP(url, '/direct', 200, { ok: true })
9
- await verifyViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
8
+ await verifyJSONViaHTTP(url, '/direct', 200, { ok: true })
9
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
10
10
  })
11
11
 
12
12
  test('can detect and start a fastify application with no build function and when not the entrypoint', async t => {
13
13
  const { runtime, url } = await createRuntime(t, 'fastify/no-build/platformatic.no-entrypoint.runtime.json')
14
14
 
15
- await verifyViaHTTP(url, '/mesh', 200, { ok: true })
16
- await verifyViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
15
+ await verifyJSONViaHTTP(url, '/mesh', 200, { ok: true })
16
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
17
17
  })
18
18
 
19
19
  test('can detect and start a fastify application with build function defined', async t => {
20
20
  const { runtime, url } = await createRuntime(t, 'fastify/with-build/platformatic.as-entrypoint.runtime.json')
21
21
 
22
- await verifyViaHTTP(url, '/direct', 200, { ok: true })
23
- await verifyViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
22
+ await verifyJSONViaHTTP(url, '/direct', 200, { ok: true })
23
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/direct', 200, { ok: true })
24
24
  })
25
25
 
26
26
  test('can detect and start a fastify application with build function defined and when not the entrypoint', async t => {
27
27
  const { runtime, url } = await createRuntime(t, 'fastify/no-build/platformatic.no-entrypoint.runtime.json')
28
28
 
29
- await verifyViaHTTP(url, '/mesh', 200, { ok: true })
30
- await verifyViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
29
+ await verifyJSONViaHTTP(url, '/mesh', 200, { ok: true })
30
+ await verifyJSONViaInject(runtime, 'main', 'GET', '/mesh', 200, { ok: true })
31
31
 
32
32
  const details = await runtime.getServiceDetails('internal')
33
33
  ifError(details.url)
@@ -0,0 +1,5 @@
1
+ const nextConfig = {
2
+ basePath: '/nested/base/dir',
3
+ }
4
+
5
+ export default nextConfig
@@ -0,0 +1,15 @@
1
+ {
2
+ "name": "next",
3
+ "private": true,
4
+ "version": "0.1.0",
5
+ "scripts": {
6
+ "dev": "next dev",
7
+ "build": "next build",
8
+ "start": "next start"
9
+ },
10
+ "dependencies": {
11
+ "react": "^18.0.0",
12
+ "react-dom": "^18.0.0",
13
+ "next": "^14.2.5"
14
+ }
15
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "$schema": "https://schemas.platformatic.dev/@platformatic/basic/1.52.0.json",
3
+ "server": {
4
+ "logger": {
5
+ "level": "error"
6
+ }
7
+ }
8
+ }
@@ -0,0 +1,21 @@
1
+ {
2
+ "$schema": "https://schemas.platformatic.dev/@platformatic/runtime/1.52.0.json",
3
+ "entrypoint": "main",
4
+ "watch": false,
5
+ "managementApi": false,
6
+ "metrics": false,
7
+ "server": {
8
+ "logger": {
9
+ "level": "error"
10
+ }
11
+ },
12
+ "services": [
13
+ {
14
+ "id": "frontend",
15
+ "path": ".",
16
+ "config": "platformatic.application.json"
17
+ },
18
+ { "id": "service", "config": "platformatic.service.json", "path": "../../platformatic-service" },
19
+ { "id": "main", "config": "platformatic.no-prefix.composer.json", "path": "../../platformatic-composer" }
20
+ ]
21
+ }
@@ -0,0 +1,7 @@
1
+ export default function RootLayout ({ children }) {
2
+ return (
3
+ <html lang='en'>
4
+ <body>{children}</body>
5
+ </html>
6
+ )
7
+ }
@@ -0,0 +1,5 @@
1
+ import { version } from '../../../../../tmp/version.js'
2
+
3
+ export default function Home () {
4
+ return <div>Hello from {version}</div>
5
+ }
@@ -0,0 +1 @@
1
+ module.exports = {}