polen 0.11.0-next.10 → 0.11.0-next.11

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 (105) hide show
  1. package/build/api/api.d.ts +2 -1
  2. package/build/api/api.d.ts.map +1 -1
  3. package/build/api/api.js +5 -1
  4. package/build/api/api.js.map +1 -1
  5. package/build/api/iso/$$.d.ts +2 -0
  6. package/build/api/iso/$$.d.ts.map +1 -0
  7. package/build/api/iso/$$.js +2 -0
  8. package/build/api/iso/$$.js.map +1 -0
  9. package/build/api/iso/$.d.ts +2 -0
  10. package/build/api/iso/$.d.ts.map +1 -0
  11. package/build/api/iso/$.js +2 -0
  12. package/build/api/iso/$.js.map +1 -0
  13. package/build/api/iso/schema/$$.d.ts +4 -0
  14. package/build/api/iso/schema/$$.d.ts.map +1 -0
  15. package/build/api/iso/schema/$$.js +3 -0
  16. package/build/api/iso/schema/$$.js.map +1 -0
  17. package/build/api/iso/schema/$.d.ts +2 -0
  18. package/build/api/iso/schema/$.d.ts.map +1 -0
  19. package/build/api/iso/schema/$.js +2 -0
  20. package/build/api/iso/schema/$.js.map +1 -0
  21. package/build/api/iso/schema/constants.d.ts +25 -0
  22. package/build/api/iso/schema/constants.d.ts.map +1 -0
  23. package/build/api/iso/schema/constants.js +42 -0
  24. package/build/api/iso/schema/constants.js.map +1 -0
  25. package/build/api/iso/schema/routing.d.ts +22 -0
  26. package/build/api/iso/schema/routing.d.ts.map +1 -0
  27. package/build/api/iso/schema/routing.js +39 -0
  28. package/build/api/iso/schema/routing.js.map +1 -0
  29. package/build/api/iso.d.ts +2 -0
  30. package/build/api/iso.d.ts.map +1 -0
  31. package/build/api/iso.js +2 -0
  32. package/build/api/iso.js.map +1 -0
  33. package/build/api/schema/schema.d.ts +3 -25
  34. package/build/api/schema/schema.d.ts.map +1 -1
  35. package/build/api/schema/schema.js +5 -42
  36. package/build/api/schema/schema.js.map +1 -1
  37. package/build/api/vite/plugins/core.d.ts.map +1 -1
  38. package/build/api/vite/plugins/core.js +3 -6
  39. package/build/api/vite/plugins/core.js.map +1 -1
  40. package/build/template/components/GraphQLInteractive/lib/parser.d.ts.map +1 -1
  41. package/build/template/components/GraphQLInteractive/lib/parser.js +32 -10
  42. package/build/template/components/GraphQLInteractive/lib/parser.js.map +1 -1
  43. package/build/template/components/HamburgerMenu.d.ts +1 -0
  44. package/build/template/components/HamburgerMenu.d.ts.map +1 -1
  45. package/build/template/components/HamburgerMenu.js +2 -2
  46. package/build/template/components/HamburgerMenu.js.map +1 -1
  47. package/build/template/components/ReferenceLink.d.ts.map +1 -1
  48. package/build/template/components/ReferenceLink.js +2 -4
  49. package/build/template/components/ReferenceLink.js.map +1 -1
  50. package/build/template/components/VersionSelector.d.ts +3 -2
  51. package/build/template/components/VersionSelector.d.ts.map +1 -1
  52. package/build/template/components/VersionSelector.js +7 -15
  53. package/build/template/components/VersionSelector.js.map +1 -1
  54. package/build/template/components/sidebar/Sidebar.d.ts +3 -2
  55. package/build/template/components/sidebar/Sidebar.d.ts.map +1 -1
  56. package/build/template/components/sidebar/Sidebar.js +7 -6
  57. package/build/template/components/sidebar/Sidebar.js.map +1 -1
  58. package/build/template/components/sidebar/SidebarContext.d.ts +6 -0
  59. package/build/template/components/sidebar/SidebarContext.d.ts.map +1 -0
  60. package/build/template/components/sidebar/SidebarContext.js +3 -0
  61. package/build/template/components/sidebar/SidebarContext.js.map +1 -0
  62. package/build/template/components/sidebar/SidebarItem.d.ts.map +1 -1
  63. package/build/template/components/sidebar/SidebarItem.js +11 -4
  64. package/build/template/components/sidebar/SidebarItem.js.map +1 -1
  65. package/build/template/hooks/useVersionPath.d.ts.map +1 -1
  66. package/build/template/hooks/useVersionPath.js +3 -1
  67. package/build/template/hooks/useVersionPath.js.map +1 -1
  68. package/build/template/layouts/SidebarLayout.d.ts +3 -2
  69. package/build/template/layouts/SidebarLayout.d.ts.map +1 -1
  70. package/build/template/layouts/SidebarLayout.js +2 -2
  71. package/build/template/layouts/SidebarLayout.js.map +1 -1
  72. package/build/template/routes/reference.d.ts.map +1 -1
  73. package/build/template/routes/reference.js +6 -9
  74. package/build/template/routes/reference.js.map +1 -1
  75. package/build/template/server/ssg/get-route-paths.d.ts.map +1 -1
  76. package/build/template/server/ssg/get-route-paths.js +47 -14
  77. package/build/template/server/ssg/get-route-paths.js.map +1 -1
  78. package/package.json +4 -1
  79. package/src/api/api.ts +7 -1
  80. package/src/api/iso/$$.ts +1 -0
  81. package/src/api/iso/$.ts +1 -0
  82. package/src/api/iso/schema/$$.ts +5 -0
  83. package/src/api/iso/schema/$.ts +1 -0
  84. package/src/api/iso/schema/constants.ts +49 -0
  85. package/src/api/iso/schema/routing.ts +53 -0
  86. package/src/api/iso.ts +1 -0
  87. package/src/api/schema/schema.ts +6 -53
  88. package/src/api/vite/plugins/core.ts +3 -6
  89. package/src/template/components/GraphQLInteractive/lib/parser.ts +32 -16
  90. package/src/template/components/HamburgerMenu.tsx +3 -1
  91. package/src/template/components/ReferenceLink.tsx +7 -4
  92. package/src/template/components/VersionSelector.tsx +10 -18
  93. package/src/template/components/sidebar/Sidebar.tsx +20 -16
  94. package/src/template/components/sidebar/SidebarContext.tsx +7 -0
  95. package/src/template/components/sidebar/SidebarItem.tsx +11 -4
  96. package/src/template/hooks/useVersionPath.ts +3 -1
  97. package/src/template/layouts/SidebarLayout.tsx +5 -3
  98. package/src/template/routes/reference.tsx +7 -10
  99. package/src/template/server/ssg/get-route-paths.test.ts +13 -0
  100. package/src/template/server/ssg/get-route-paths.ts +47 -14
  101. package/build/template/lib/schema-utils/constants.d.ts +0 -5
  102. package/build/template/lib/schema-utils/constants.d.ts.map +0 -1
  103. package/build/template/lib/schema-utils/constants.js +0 -5
  104. package/build/template/lib/schema-utils/constants.js.map +0 -1
  105. package/src/template/lib/schema-utils/constants.ts +0 -4
@@ -1,28 +1,32 @@
1
1
  import type { Content } from '#api/content/$'
2
2
  import { Box } from '@radix-ui/themes'
3
3
  import type { BoxOwnProps, LayoutProps, MarginProps } from '@radix-ui/themes/props'
4
+ import { SidebarContext } from './SidebarContext.js'
4
5
  import { Items } from './SidebarItem.js'
5
6
 
6
- interface SidebarProps extends LayoutProps, MarginProps, BoxOwnProps {
7
+ interface Props extends LayoutProps, MarginProps, BoxOwnProps {
7
8
  data: Content.Item[]
9
+ basePath?: string
8
10
  style?: React.CSSProperties
9
11
  }
10
12
 
11
- export const Sidebar = ({ data, ...props }: SidebarProps) => {
13
+ export const Sidebar = ({ data, basePath, ...props }: Props) => {
12
14
  return (
13
- <Box
14
- data-testid='sidebar'
15
- role='Sidebar'
16
- {...props}
17
- >
18
- <style>
19
- {`
20
- div[role="Sidebar"] a:not([data-active]):hover {
21
- background-color: var(--iris-2) !important;
22
- }
23
- `}
24
- </style>
25
- <Items items={data} />
26
- </Box>
15
+ <SidebarContext.Provider value={{ basePath }}>
16
+ <Box
17
+ data-testid='sidebar'
18
+ role='Sidebar'
19
+ {...props}
20
+ >
21
+ <style>
22
+ {`
23
+ div[role="Sidebar"] a:not([data-active]):hover {
24
+ background-color: var(--iris-2) !important;
25
+ }
26
+ `}
27
+ </style>
28
+ <Items items={data} />
29
+ </Box>
30
+ </SidebarContext.Provider>
27
31
  )
28
32
  }
@@ -0,0 +1,7 @@
1
+ import { createContext } from 'react'
2
+
3
+ interface SidebarContextValue {
4
+ basePath?: string
5
+ }
6
+
7
+ export const SidebarContext = createContext<SidebarContextValue>({})
@@ -1,9 +1,12 @@
1
1
  import type { Content } from '#api/content/$'
2
+ import { Api } from '#api/iso'
2
3
  import type { React } from '#dep/react/index'
3
4
  import { Texts } from '#template/components/Texts/index'
4
5
  import { Box, Flex } from '@radix-ui/themes'
6
+ import { useContext } from 'react'
5
7
  import { useLocation } from 'react-router'
6
8
  import { getPathActiveReport, Link } from '../Link.js'
9
+ import { SidebarContext } from './SidebarContext.js'
7
10
 
8
11
  export const Items: React.FC<{ items: Content.Item[] }> = ({ items }) => {
9
12
  return (
@@ -50,15 +53,17 @@ const SBLink: React.FC<{
50
53
  link: Content.ItemLink | Content.ItemSection
51
54
  }> = ({ link }) => {
52
55
  const location = useLocation()
56
+ const { basePath } = useContext(SidebarContext)
53
57
  const currentPathExp = location.pathname
54
- const active = getPathActiveReport(link.pathExp, currentPathExp)
58
+ const href = Api.Schema.Routing.joinSegmentsAndPaths(basePath, link.pathExp)
59
+ const active = getPathActiveReport(href, currentPathExp)
55
60
 
56
61
  return (
57
62
  <Link
58
63
  role='Sidebar Link'
59
64
  color={active.is ? `iris` : `gray`}
60
65
  data-testid={`sidebar-link-${link.pathExp}`}
61
- to={`/${link.pathExp}`}
66
+ to={href}
62
67
  style={{
63
68
  display: `block`,
64
69
  textDecoration: `none`,
@@ -135,12 +140,14 @@ const LinkedSection: React.FC<{
135
140
 
136
141
  const SectionLink: React.FC<{ link: Content.ItemLink }> = ({ link }) => {
137
142
  const location = useLocation()
138
- const active = getPathActiveReport(link.pathExp, location.pathname)
143
+ const { basePath } = useContext(SidebarContext)
144
+ const href = Api.Schema.Routing.joinSegmentsAndPaths(basePath, link.pathExp)
145
+ const active = getPathActiveReport(href, location.pathname)
139
146
 
140
147
  return (
141
148
  <Link
142
149
  role='Sidebar Link'
143
- to={`/` + link.pathExp}
150
+ to={href}
144
151
  color={active.is ? `iris` : `gray`}
145
152
  style={{
146
153
  textDecoration: `none`,
@@ -1,3 +1,4 @@
1
+ import { Api } from '#api/iso'
1
2
  import { useParams } from 'react-router'
2
3
 
3
4
  /**
@@ -6,5 +7,6 @@ import { useParams } from 'react-router'
6
7
  */
7
8
  export const useVersionPath = (): string => {
8
9
  const params = useParams()
9
- return params[`version`] ? `version/${params[`version`]}/` : ``
10
+ const version = params[`version`] || Api.Schema.VERSION_LATEST
11
+ return Api.Schema.Routing.createReferenceVersionPath(version)
10
12
  }
@@ -6,12 +6,13 @@ import { useLocation } from 'react-router'
6
6
  import { HamburgerMenu } from '../components/HamburgerMenu.js'
7
7
  import { Sidebar } from '../components/sidebar/Sidebar.js'
8
8
 
9
- interface SidebarLayoutProps {
9
+ interface Props {
10
10
  children: React.ReactNode
11
11
  sidebar: Content.Item[]
12
+ basePath?: string
12
13
  }
13
14
 
14
- export const SidebarLayout: React.FC<SidebarLayoutProps> = ({ children, sidebar }) => {
15
+ export const SidebarLayout: React.FC<Props> = ({ children, sidebar, basePath }) => {
15
16
  const location = useLocation()
16
17
  const [mobileMenuOpen, setMobileMenuOpen] = useState(false)
17
18
 
@@ -45,6 +46,7 @@ export const SidebarLayout: React.FC<SidebarLayoutProps> = ({ children, sidebar
45
46
  setMobileMenuOpen(false)
46
47
  }}
47
48
  sidebarData={sidebar}
49
+ basePath={basePath}
48
50
  />
49
51
  </Box>
50
52
  )}
@@ -56,7 +58,7 @@ export const SidebarLayout: React.FC<SidebarLayoutProps> = ({ children, sidebar
56
58
  gridColumn='1 / 3'
57
59
  gridRow='1 / auto'
58
60
  >
59
- <Sidebar data={sidebar} />
61
+ <Sidebar data={sidebar} basePath={basePath} />
60
62
  </Box>
61
63
  )}
62
64
 
@@ -1,4 +1,5 @@
1
1
  import type { Content } from '#api/content/$'
2
+ import { Api } from '#api/iso'
2
3
  import { GrafaidOld } from '#lib/grafaid-old/index'
3
4
  import { Grafaid } from '#lib/grafaid/index'
4
5
  import { route, routeIndex } from '#lib/react-router-aid/react-router-aid'
@@ -10,14 +11,13 @@ import { MissingSchema } from '../components/MissingSchema.js'
10
11
  import { NamedType } from '../components/NamedType.js'
11
12
  import { VersionSelector } from '../components/VersionSelector.js'
12
13
  import { SidebarLayout } from '../layouts/index.js'
13
- import { VERSION_LATEST } from '../lib/schema-utils/constants.js'
14
14
  import { schemaSource } from '../sources/schema-source.js'
15
15
 
16
16
  export const loader = createLoader(async ({ params }) => {
17
17
  // Handle both versioned and unversioned routes:
18
18
  // - Versioned: /reference/version/:version/:type → params.version exists
19
19
  // - Unversioned: /reference/:type → params.version is undefined, defaults to latest
20
- const currentVersion = params.version ?? VERSION_LATEST
20
+ const currentVersion = params.version ?? Api.Schema.VERSION_LATEST
21
21
 
22
22
  const schema = await schemaSource.get(currentVersion)
23
23
  const availableVersions = schemaSource.versions
@@ -42,12 +42,6 @@ const RouteReferenceComponent = () => {
42
42
  const sidebarItems: Content.Item[] = []
43
43
  const kindEntries = Object.entries(kindMap.list).filter(([_, types]) => types.length > 0)
44
44
 
45
- // Build path prefix based on current version from loader data
46
- // This ensures sidebar links always match the current version being viewed
47
- const versionPath = data.currentVersion === VERSION_LATEST
48
- ? ``
49
- : `version/${data.currentVersion}/`
50
-
51
45
  for (const [title, types] of kindEntries) {
52
46
  sidebarItems.push({
53
47
  type: `ItemSection` as const,
@@ -57,13 +51,16 @@ const RouteReferenceComponent = () => {
57
51
  links: types.map(type => ({
58
52
  type: `ItemLink` as const,
59
53
  title: type.name,
60
- pathExp: `reference/${versionPath}${type.name}`,
54
+ pathExp: type.name, // Just the type name, basePath will be prepended
61
55
  })),
62
56
  })
63
57
  }
64
58
 
59
+ // Calculate basePath based on current version
60
+ const basePath = Api.Schema.Routing.createReferenceBasePath(data.currentVersion)
61
+
65
62
  return (
66
- <SidebarLayout sidebar={sidebarItems}>
63
+ <SidebarLayout sidebar={sidebarItems} basePath={basePath}>
67
64
  <Box mb={`4`}>
68
65
  <VersionSelector
69
66
  availableVersions={data.availableVersions}
@@ -50,6 +50,19 @@ vi.mock('#api/index', () => ({
50
50
  Schema: {
51
51
  getMetadata: vi.fn(),
52
52
  VERSION_LATEST: 'latest',
53
+ Routing: {
54
+ createReferencePath: vi.fn((parts) => {
55
+ const version = parts.version || 'latest'
56
+ const basePath = version === 'latest' ? '/reference' : `/reference/version/${version}`
57
+ if (parts.type) {
58
+ return parts.field ? `${basePath}/${parts.type}/${parts.field}` : `${basePath}/${parts.type}`
59
+ }
60
+ return basePath
61
+ }),
62
+ createReferenceBasePath: vi.fn((version) => {
63
+ return version === 'latest' ? '/reference' : `/reference/version/${version}`
64
+ }),
65
+ },
53
66
  },
54
67
  },
55
68
  }))
@@ -22,7 +22,7 @@ export const getRoutesPaths = async (): Promise<string[]> => {
22
22
  const routeExpressions = ReactRouterAid.getRouteExpressions(routes)
23
23
 
24
24
  // Helper function to load schema from filesystem and add type paths
25
- const addTypePathsForVersion = async (version: string, pathPrefix: string, includeFields = false) => {
25
+ const addTypePathsForVersion = async (version: string, includeFields = false) => {
26
26
  try {
27
27
  const schemaFilePath = NodePath.join(PROJECT_DATA.paths.project.absolute.build.assets.schemas, `${version}.json`)
28
28
  const schemaContent = await NodeFs.readFile(schemaFilePath, 'utf-8')
@@ -30,38 +30,70 @@ export const getRoutesPaths = async (): Promise<string[]> => {
30
30
 
31
31
  visit(schemaAst, {
32
32
  ObjectTypeDefinition(node) {
33
- const typePath = `${pathPrefix}/${node.name.value}`
33
+ const typePath = Api.Schema.Routing.createReferencePath({
34
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
35
+ type: node.name.value,
36
+ })
34
37
  paths.add(typePath)
35
38
 
36
39
  // Add field paths if requested
37
40
  if (includeFields && node.fields) {
38
41
  for (const field of node.fields) {
39
- paths.add(`${typePath}/${field.name.value}`)
42
+ const fieldPath = Api.Schema.Routing.createReferencePath({
43
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
44
+ type: node.name.value,
45
+ field: field.name.value,
46
+ })
47
+ paths.add(fieldPath)
40
48
  }
41
49
  }
42
50
  },
43
51
  InterfaceTypeDefinition(node) {
44
- const typePath = `${pathPrefix}/${node.name.value}`
52
+ const typePath = Api.Schema.Routing.createReferencePath({
53
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
54
+ type: node.name.value,
55
+ })
45
56
  paths.add(typePath)
46
57
 
47
58
  // Add field paths if requested
48
59
  if (includeFields && node.fields) {
49
60
  for (const field of node.fields) {
50
- paths.add(`${typePath}/${field.name.value}`)
61
+ const fieldPath = Api.Schema.Routing.createReferencePath({
62
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
63
+ type: node.name.value,
64
+ field: field.name.value,
65
+ })
66
+ paths.add(fieldPath)
51
67
  }
52
68
  }
53
69
  },
54
70
  EnumTypeDefinition(node) {
55
- paths.add(`${pathPrefix}/${node.name.value}`)
71
+ const typePath = Api.Schema.Routing.createReferencePath({
72
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
73
+ type: node.name.value,
74
+ })
75
+ paths.add(typePath)
56
76
  },
57
77
  InputObjectTypeDefinition(node) {
58
- paths.add(`${pathPrefix}/${node.name.value}`)
78
+ const typePath = Api.Schema.Routing.createReferencePath({
79
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
80
+ type: node.name.value,
81
+ })
82
+ paths.add(typePath)
59
83
  },
60
84
  UnionTypeDefinition(node) {
61
- paths.add(`${pathPrefix}/${node.name.value}`)
85
+ const typePath = Api.Schema.Routing.createReferencePath({
86
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
87
+ type: node.name.value,
88
+ })
89
+ paths.add(typePath)
62
90
  },
63
91
  ScalarTypeDefinition(node) {
64
- paths.add(`${pathPrefix}/${node.name.value}`)
92
+ const typePath = Api.Schema.Routing.createReferencePath({
93
+ version: version === Api.Schema.VERSION_LATEST ? undefined : version,
94
+ type: node.name.value,
95
+ })
96
+ paths.add(typePath)
65
97
  },
66
98
  })
67
99
  } catch (error) {
@@ -78,32 +110,33 @@ export const getRoutesPaths = async (): Promise<string[]> => {
78
110
  if (exp === knownParameterizedRouteExpressions.reference_type) {
79
111
  if (hasSchema) {
80
112
  // Add paths for latest version (no version in URL)
81
- await addTypePathsForVersion(Api.Schema.VERSION_LATEST, `/reference`)
113
+ await addTypePathsForVersion(Api.Schema.VERSION_LATEST)
82
114
  }
83
115
  } else if (exp === knownParameterizedRouteExpressions.reference_version) {
84
116
  if (hasSchema) {
85
117
  // Add paths for version pages themselves (without type)
86
118
  for (const version of availableVersions) {
87
- paths.add(`/reference/version/${version}`)
119
+ const versionPath = Api.Schema.Routing.createReferenceBasePath(version)
120
+ paths.add(versionPath)
88
121
  }
89
122
  }
90
123
  } else if (exp === knownParameterizedRouteExpressions.reference_type_field) {
91
124
  if (hasSchema) {
92
125
  // Add paths for latest version fields
93
- await addTypePathsForVersion(Api.Schema.VERSION_LATEST, `/reference`, true)
126
+ await addTypePathsForVersion(Api.Schema.VERSION_LATEST, true)
94
127
  }
95
128
  } else if (exp === knownParameterizedRouteExpressions.reference_versioned_type) {
96
129
  if (hasSchema) {
97
130
  // Add paths for all versions using new route structure
98
131
  for (const version of availableVersions) {
99
- await addTypePathsForVersion(version, `/reference/version/${version}`)
132
+ await addTypePathsForVersion(version)
100
133
  }
101
134
  }
102
135
  } else if (exp === knownParameterizedRouteExpressions.reference_versioned_type_field) {
103
136
  if (hasSchema) {
104
137
  // Add paths for all versions with fields
105
138
  for (const version of availableVersions) {
106
- await addTypePathsForVersion(version, `/reference/version/${version}`, true)
139
+ await addTypePathsForVersion(version, true)
107
140
  }
108
141
  }
109
142
  } else if (ReactRouterAid.isParameterizedPath(exp)) {
@@ -1,5 +0,0 @@
1
- /**
2
- * Re-exports of schema constants for template usage
3
- */
4
- export { dateToVersionString, VERSION_LATEST } from '#api/schema/schema';
5
- //# sourceMappingURL=constants.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/template/lib/schema-utils/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA"}
@@ -1,5 +0,0 @@
1
- /**
2
- * Re-exports of schema constants for template usage
3
- */
4
- export { dateToVersionString, VERSION_LATEST } from '#api/schema/schema';
5
- //# sourceMappingURL=constants.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../src/template/lib/schema-utils/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA"}
@@ -1,4 +0,0 @@
1
- /**
2
- * Re-exports of schema constants for template usage
3
- */
4
- export { dateToVersionString, VERSION_LATEST } from '#api/schema/schema'