tungsten 0.4.11 → 0.4.13
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.
- package/dist/.build-complete +1 -1
- package/dist/.tsbuildinfo +1 -0
- package/dist/AnyComponent.d.ts.map +1 -1
- package/dist/AnyComponent.js +1 -1
- package/dist/Components.d.ts.map +1 -1
- package/dist/Components.js +25 -23
- package/dist/ContentNode.js +2 -2
- package/dist/DomPointer.js +1 -1
- package/dist/DomRegion.js +3 -3
- package/dist/Framework.d.ts +2 -1
- package/dist/Framework.d.ts.map +1 -1
- package/dist/Framework.js +44 -35
- package/dist/FrameworkConfig.d.ts +16 -0
- package/dist/FrameworkConfig.d.ts.map +1 -1
- package/dist/FunctionComponentStandIn.js +8 -8
- package/dist/Instance/Instance.js +12 -12
- package/dist/RenderedContentNode.d.ts.map +1 -1
- package/dist/RenderedContentNode.js +4 -3
- package/dist/RenderingNode.js +2 -2
- package/dist/Sass.d.ts.map +1 -1
- package/dist/Sass.js +1 -0
- package/dist/Script.js +1 -1
- package/dist/Servers/DevServer.d.ts.map +1 -1
- package/dist/Servers/DevServer.js +33 -32
- package/dist/Servers/ProdServer.js +15 -15
- package/dist/Servers/StaticSiteServer.js +4 -4
- package/dist/Servers/TungstenServer.js +5 -5
- package/dist/Servers/devErrorPageAutoRetry.js +1 -1
- package/dist/Servers/initStores.js +3 -3
- package/dist/Servers/loadEnvsDev.d.ts +1 -1
- package/dist/Servers/loadEnvsDev.d.ts.map +1 -1
- package/dist/Servers/loadEnvsDev.js +10 -8
- package/dist/Servers/routing.d.ts.map +1 -1
- package/dist/Servers/routing.js +4 -4
- package/dist/Store/Store.js +1 -1
- package/dist/Store/TypeSafeStore.js +1 -1
- package/dist/Store/createStores.js +2 -2
- package/dist/Store/makeStore.js +3 -3
- package/dist/Store/registerStore.js +3 -3
- package/dist/TElement.js +1 -1
- package/dist/TungstenApp.js +9 -5
- package/dist/TungstenStyleObject.js +1 -1
- package/dist/__deproxy.js +2 -2
- package/dist/_client/client.js +3 -3
- package/dist/alive.js +1 -1
- package/dist/api/getApiRoutes.js +3 -3
- package/dist/api/getExport.d.ts.map +1 -1
- package/dist/api/getExport.js +5 -4
- package/dist/api/getExportDev.js +1 -1
- package/dist/appOutput.js +1 -1
- package/dist/auth/index.js +2 -2
- package/dist/babelPlugins/BabelAddDevCacheBust.d.ts.map +1 -1
- package/dist/babelPlugins/BabelAddDevCacheBust.js +4 -2
- package/dist/babelPlugins/BabelTransformBindDirect.js +4 -2
- package/dist/babelPlugins/BabelTransformBindVar.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformBindVar.js +3 -3
- package/dist/babelPlugins/BabelTransformCjsToEsm.js +1 -1
- package/dist/babelPlugins/BabelTransformComponentState.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformComponentState.js +2 -2
- package/dist/babelPlugins/BabelTransformComponentStyles.d.ts +2 -0
- package/dist/babelPlugins/BabelTransformComponentStyles.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformComponentStyles.js +32 -15
- package/dist/babelPlugins/BabelTransformCssImports.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformCssImports.js +3 -3
- package/dist/babelPlugins/BabelTransformDependencyImportsOld.js +1 -1
- package/dist/babelPlugins/BabelTransformDeproxyState.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformDeproxyState.js +1 -1
- package/dist/babelPlugins/BabelTransformJsxExtensionsToJs.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformJsxExtensionsToJs.js +6 -2
- package/dist/babelPlugins/BabelTransformPackageImports.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformPackageImports.js +75 -53
- package/dist/babelPlugins/BabelTransformReactive.js +1 -1
- package/dist/babelPlugins/BabelTransformReactiveSvelteStyle.js +1 -1
- package/dist/babelPlugins/BabelTransformRemoveBlocks.d.ts.map +1 -1
- package/dist/babelPlugins/BabelTransformSxyFrameworkImports.js +1 -1
- package/dist/babelPlugins/BabelTransformUniqueComponents.js +1 -1
- package/dist/babelPlugins/fixImportsInSassErrorMessage.js +1 -1
- package/dist/babelPlugins/test.js +1 -1
- package/dist/babelPlugins/transformPackageImports/BabelTransformDependencyImportsCjs.d.ts.map +1 -1
- package/dist/babelPlugins/transformPackageImports/BabelTransformDependencyImportsCjs.js +5 -4
- package/dist/babelPlugins/transformPackageImports/BabelTransformDependencyImportsEsm.d.ts.map +1 -1
- package/dist/babelPlugins/transformPackageImports/BabelTransformDependencyImportsEsm.js +3 -2
- package/dist/babelPlugins/transformPackageImports/getWebLocationOfPackageFile.js +2 -2
- package/dist/bin/args.js +2 -2
- package/dist/bin/commands/build.js +6 -6
- package/dist/bin/commands/buildHelp.js +1 -1
- package/dist/bin/commands/clean.js +4 -4
- package/dist/bin/commands/compile.d.ts.map +1 -1
- package/dist/bin/commands/compile.js +24 -17
- package/dist/bin/commands/compileSimplePackage.js +3 -2
- package/dist/bin/commands/dev.d.ts.map +1 -1
- package/dist/bin/commands/dev.js +16 -9
- package/dist/bin/commands/devmon.js +4 -4
- package/dist/bin/commands/help.js +2 -2
- package/dist/bin/commands/start.js +2 -2
- package/dist/bin/commands/static.js +3 -3
- package/dist/bin/index.d.ts.map +1 -1
- package/dist/bin/index.js +24 -16
- package/dist/bin/moduleLoadAnalysis.js +2 -2
- package/dist/bin/vendorHook.d.ts +3 -0
- package/dist/bin/vendorHook.d.ts.map +1 -0
- package/dist/bin/vendorHook.js +34 -0
- package/dist/browserStorage.js +6 -4
- package/dist/build/babel.user.common.config.d.ts +9 -2
- package/dist/build/babel.user.common.config.d.ts.map +1 -1
- package/dist/build/babel.user.common.config.js +21 -16
- package/dist/build/bundle.d.ts +1 -1
- package/dist/build/bundle.d.ts.map +1 -1
- package/dist/build/bundle.js +15 -7
- package/dist/build/bundleBabelOptions.d.ts +6 -0
- package/dist/build/bundleBabelOptions.d.ts.map +1 -0
- package/dist/build/bundleBabelOptions.js +23 -0
- package/dist/build/combineComponentCss.js +2 -2
- package/dist/build/compileJavascript.d.ts +4 -0
- package/dist/build/compileJavascript.d.ts.map +1 -1
- package/dist/build/compileJavascript.js +174 -103
- package/dist/build/compileStyles.js +8 -8
- package/dist/build/compileUserApp.d.ts +1 -1
- package/dist/build/compileUserApp.d.ts.map +1 -1
- package/dist/build/compileUserApp.js +15 -12
- package/dist/build/componentStylesCache.d.ts +10 -0
- package/dist/build/componentStylesCache.d.ts.map +1 -0
- package/dist/build/componentStylesCache.js +54 -0
- package/dist/build/copyAssets.js +4 -4
- package/dist/build/copyPackageModulesToPackagesFolder.js +4 -4
- package/dist/build/copyPublicFiles.js +4 -4
- package/dist/build/createClientFiles.js +3 -3
- package/dist/build/createInstanceConfigFile.js +2 -2
- package/dist/build/createPackageVirtualFileSystems.js +1 -1
- package/dist/build/devBundle.js +5 -5
- package/dist/build/devBundle.rollup.config.d.ts.map +1 -1
- package/dist/build/devBundle.rollup.config.js +0 -1
- package/dist/build/frameworkDestLocation.d.ts +1 -0
- package/dist/build/frameworkDestLocation.d.ts.map +1 -1
- package/dist/build/frameworkDestLocation.js +8 -4
- package/dist/build/frameworkStylesheets.js +2 -2
- package/dist/build/getAllSxyClientModules.d.ts.map +1 -1
- package/dist/build/getAllSxyClientModules.js +4 -28
- package/dist/build/getPackageDirForFile.js +1 -1
- package/dist/build/getSxyClientPackageAliases.d.ts.map +1 -1
- package/dist/build/getSxyClientPackageAliases.js +4 -2
- package/dist/build/getTempDirForAppCompilation.js +1 -1
- package/dist/build/makeBabelRawConfig.d.ts +3 -0
- package/dist/build/makeBabelRawConfig.d.ts.map +1 -0
- package/dist/build/makeBabelRawConfig.js +12 -0
- package/dist/build/makeBabelUserDevConfig.d.ts +1 -1
- package/dist/build/makeBabelUserDevConfig.d.ts.map +1 -1
- package/dist/build/makeBabelUserDevConfig.js +11 -8
- package/dist/build/makeBabelUserProdConfig.d.ts +1 -1
- package/dist/build/makeBabelUserProdConfig.d.ts.map +1 -1
- package/dist/build/makeBabelUserProdConfig.js +10 -5
- package/dist/build/rollup.user.prod.config.d.ts.map +1 -1
- package/dist/build/rollup.user.prod.config.js +13 -11
- package/dist/build/rollupExtractComponentStylesheets.js +3 -3
- package/dist/build/sassImportParser.js +4 -4
- package/dist/build/tallyBabel.d.ts +3 -0
- package/dist/build/tallyBabel.d.ts.map +1 -0
- package/dist/build/tallyBabel.js +11 -0
- package/dist/calculateImportedStaticFileLocations.js +2 -2
- package/dist/calledFrom.js +2 -2
- package/dist/clone.js +4 -4
- package/dist/compat/context.d.ts.map +1 -1
- package/dist/compat/forwardRef.js +1 -1
- package/dist/compat/index.js +1 -1
- package/dist/compat/types.d.ts.map +1 -1
- package/dist/componentProxyHandlers.d.ts.map +1 -1
- package/dist/componentProxyHandlers.js +8 -12
- package/dist/components/Link.js +2 -2
- package/dist/components/PopMessages.js +3 -3
- package/dist/components/RawHtml.js +2 -2
- package/dist/components/Stylesheet.d.ts +1 -2
- package/dist/components/Stylesheet.d.ts.map +1 -1
- package/dist/components/Stylesheet.js +4 -4
- package/dist/components/bindable/BindableCheckbox.d.ts.map +1 -1
- package/dist/components/bindable/BindableCheckbox.js +1 -1
- package/dist/components/bindable/BindableInput.d.ts.map +1 -1
- package/dist/components/bindable/BindableInput.js +1 -1
- package/dist/components/bindable/BindableInputNonString.js +1 -1
- package/dist/components/bindable/BindableInputString.js +1 -1
- package/dist/components/bindable/BindableInputTyped.js +1 -1
- package/dist/components/bindable/BindableInputTypedLegacy.d.ts.map +1 -1
- package/dist/components/bindable/BindableInputTypedLegacy.js +1 -1
- package/dist/components/bindable/BindableRadio.d.ts.map +1 -1
- package/dist/components/bindable/BindableRadio.js +1 -1
- package/dist/components/bindable/BindableSelect.js +1 -1
- package/dist/components/bindable/BindableTextarea.d.ts.map +1 -1
- package/dist/components/bindable/BindableTextarea.js +1 -1
- package/dist/components/library/RichTextEditor/RichTextEditor.js +10 -10
- package/dist/components/library/RichTextEditor/contentTree.js +5 -5
- package/dist/components/library/RichTextEditor/sanitizeAuthoredHtml.js +2 -2
- package/dist/components/library/__StatefulMessage/StatefulMessage.js +2 -2
- package/dist/components/library/index.js +2 -2
- package/dist/concat.d.ts.map +1 -1
- package/dist/concat.js +2 -2
- package/dist/copy.d.ts.map +1 -1
- package/dist/createElement.js +1 -1
- package/dist/createRoutes.d.ts +1 -1
- package/dist/createRoutes.d.ts.map +1 -1
- package/dist/defaultConfig.d.ts +0 -1
- package/dist/defaultConfig.d.ts.map +1 -1
- package/dist/defaultConfig.js +2 -2
- package/dist/deleteDirs.js +1 -1
- package/dist/env/Env.js +2 -2
- package/dist/env/addToEnv.js +1 -1
- package/dist/env/funcs.js +4 -4
- package/dist/env/getEnvSchemas.d.ts +2 -2
- package/dist/env/getEnvSchemas.d.ts.map +1 -1
- package/dist/env/getEnvSchemas.js +16 -10
- package/dist/env/privateEnv.js +2 -2
- package/dist/env/privateEnvOrThrow.js +1 -1
- package/dist/env/publicEnv.js +1 -1
- package/dist/env/publicEnvOrThrow.js +1 -1
- package/dist/env/windowGlobalEnvStatement.d.ts.map +1 -1
- package/dist/filePathFromUrl.js +1 -1
- package/dist/findProjectDir.d.ts.map +1 -1
- package/dist/findProjectDir.js +19 -5
- package/dist/findUserConfig.js +7 -7
- package/dist/fixExtension.d.ts.map +1 -1
- package/dist/fixExtension.js +5 -3
- package/dist/foreach.js +1 -0
- package/dist/frameworkConfigSchema.d.ts +16 -0
- package/dist/frameworkConfigSchema.d.ts.map +1 -1
- package/dist/frameworkConfigSchema.js +14 -2
- package/dist/getComponent.d.ts.map +1 -1
- package/dist/getComponent.js +5 -5
- package/dist/getComponentDev.d.ts.map +1 -1
- package/dist/getComponentDev.js +1 -1
- package/dist/getFrameworkDir.js +1 -1
- package/dist/getRoutes.d.ts.map +1 -1
- package/dist/getRoutes.js +18 -27
- package/dist/getRoutesDevs.d.ts.map +1 -1
- package/dist/getRoutesDevs.js +1 -1
- package/dist/getStackTrace.js +1 -1
- package/dist/getUserConfig.js +7 -7
- package/dist/glob.d.ts +5 -0
- package/dist/glob.d.ts.map +1 -0
- package/dist/glob.js +103 -0
- package/dist/hasValidKey.js +1 -1
- package/dist/helpers/getFetchCompatibleHeaders.js +2 -2
- package/dist/helpers/index.js +2 -2
- package/dist/hmr/applyHmrModule.js +10 -10
- package/dist/hmr/componentIdentity.js +3 -3
- package/dist/hmr/instanceRegistry.js +2 -2
- package/dist/hooks/clearCurrentComponent.js +1 -1
- package/dist/hooks/getCurrentComponent.js +3 -3
- package/dist/hooks/index.js +5 -5
- package/dist/hooks/setCurrentComponent.js +1 -1
- package/dist/hooks/useCallback.js +2 -2
- package/dist/hooks/useEffect.js +2 -2
- package/dist/hooks/useInstance.js +1 -1
- package/dist/hooks/useMemo.js +2 -2
- package/dist/hooks/useReducer.d.ts.map +1 -1
- package/dist/hooks/useState.d.ts.map +1 -1
- package/dist/hooks/useState.js +3 -9
- package/dist/hydrate/hydrate.d.ts +1 -1
- package/dist/hydrate/hydrate.d.ts.map +1 -1
- package/dist/hydrate/hydrate.js +56 -54
- package/dist/hydrate/reconcileHydratedAttributes.js +5 -5
- package/dist/index.js +2 -2
- package/dist/indexInner.d.ts +1 -1
- package/dist/indexInner.d.ts.map +1 -1
- package/dist/indexInner.js +45 -45
- package/dist/innerHtmlFromProps.js +1 -1
- package/dist/isBrowser.js +1 -1
- package/dist/isDev.js +1 -1
- package/dist/isProd.js +1 -1
- package/dist/isServer.js +1 -1
- package/dist/jsx-runtime.js +1 -1
- package/dist/jsxRuntime.d.ts.map +1 -1
- package/dist/jsxRuntime.js +12 -7
- package/dist/jsxRuntimeSignals.d.ts.map +1 -1
- package/dist/jsxRuntimeSignals.js +15 -8
- package/dist/makeFinalConfig.d.ts.map +1 -1
- package/dist/makeFinalConfig.js +3 -3
- package/dist/makeInstanceConfigFromFrameworkConfig.js +1 -1
- package/dist/makeServerRpc.js +3 -3
- package/dist/markOptionSelected.js +2 -2
- package/dist/mergeConfigs.d.ts.map +1 -1
- package/dist/mergeConfigs.js +11 -2
- package/dist/mutatingFunctions.js +3 -3
- package/dist/nbsp.js +1 -1
- package/dist/output.js +1 -1
- package/dist/pop.js +2 -2
- package/dist/postcssPlugins/TransformCssNames.js +8 -8
- package/dist/postcssPlugins/parseSelectors.js +1 -1
- package/dist/postcssPlugins/parseSelectorsRich.js +1 -1
- package/dist/postcssPlugins/scopeAnimationValue.js +2 -2
- package/dist/propsAreEqual.js +3 -3
- package/dist/rawHtml/filterContentNode.js +4 -4
- package/dist/rawHtml/parseHtml.js +5 -5
- package/dist/rawHtml/sanitizeHtml.js +3 -3
- package/dist/rawHtml/tokenizeHtml.js +2 -2
- package/dist/render/addImportMap.js +2 -2
- package/dist/render/classComponentNodeToRenderingTree.js +4 -4
- package/dist/render/componentNodeToRenderingTree.d.ts.map +1 -1
- package/dist/render/componentNodeToRenderingTree.js +13 -24
- package/dist/render/contentNodeToHtml.js +11 -11
- package/dist/render/contentToHtml.d.ts.map +1 -1
- package/dist/render/contentToHtml.js +5 -5
- package/dist/render/contentToHtmlDev.js +1 -1
- package/dist/render/contentTreeToRenderingTree.js +7 -7
- package/dist/render/functionComponentNodeToRenderingTree.js +4 -4
- package/dist/render/getFunctionBodyAsString.d.ts.map +1 -1
- package/dist/render/getFunctionBodyAsString.js +3 -6
- package/dist/render/instantiateClassComponent.js +2 -2
- package/dist/render/instantiateComponent.js +3 -3
- package/dist/render/instantiateFunctionComponent.js +2 -2
- package/dist/render/printComponentNameInSource.js +1 -1
- package/dist/render/processHead.js +5 -5
- package/dist/render/processHtmlNode.js +1 -1
- package/dist/render/processProps.js +4 -4
- package/dist/render/processRenderingNodeHtml.js +6 -6
- package/dist/render/renderingTreeToHtml.d.ts.map +1 -1
- package/dist/render/renderingTreeToHtml.js +16 -16
- package/dist/render/rootToHtml.d.ts.map +1 -1
- package/dist/render/rootToHtml.js +2 -2
- package/dist/render/rootToHtmlDev.js +1 -1
- package/dist/requests/fetch/delete.js +2 -2
- package/dist/requests/fetch/get.js +3 -3
- package/dist/requests/fetch/patch.js +2 -2
- package/dist/requests/fetch/post.js +2 -2
- package/dist/requests/fetch/put.js +2 -2
- package/dist/requests/index.js +5 -5
- package/dist/routing/MatchedRoute.js +2 -2
- package/dist/routing/Route.js +1 -1
- package/dist/routing/RouteDataFunction.type.d.ts.map +1 -1
- package/dist/routing/RoutesWithSafeParams.js +1 -1
- package/dist/routing/WebRedirect.d.ts.map +1 -1
- package/dist/routing/compareRequestToRegex.js +2 -2
- package/dist/routing/getPathPriority.js +2 -2
- package/dist/routing/matchPath.js +3 -3
- package/dist/routing/patternToRegex.js +1 -1
- package/dist/server.js +3 -3
- package/dist/serverModuleLocation.d.ts +3 -0
- package/dist/serverModuleLocation.d.ts.map +1 -0
- package/dist/serverModuleLocation.js +12 -0
- package/dist/serverRpc.d.ts.map +1 -1
- package/dist/settings.d.ts +4 -0
- package/dist/settings.d.ts.map +1 -1
- package/dist/settings.js +9 -0
- package/dist/slash.d.ts +2 -0
- package/dist/slash.d.ts.map +1 -0
- package/dist/slash.js +5 -0
- package/dist/spawnShellCommand.js +1 -1
- package/dist/standardSchema.js +1 -1
- package/dist/staticGen/getAppRoutes.js +3 -3
- package/dist/staticGen/staticGen.d.ts.map +1 -1
- package/dist/staticGen/staticGen.js +16 -14
- package/dist/staticGen/staticGenFunctions.js +1 -1
- package/dist/style/jssToCss.d.ts.map +1 -1
- package/dist/style/jssToCss.js +13 -11
- package/dist/style/styleContent.js +1 -1
- package/dist/style/styleContentSxy.js +8 -8
- package/dist/style/unusedStyles.d.ts.map +1 -1
- package/dist/style/unusedStyles.js +1 -1
- package/dist/sync/index.js +1 -1
- package/dist/syncServer/preload.js +1 -1
- package/dist/testing/host.js +12 -12
- package/dist/testing/hydrateTestApp.d.ts.map +1 -1
- package/dist/testing/hydrateTestApp.js +18 -18
- package/dist/testing/index.d.ts.map +1 -1
- package/dist/testing/index.js +11 -11
- package/dist/testing/installTestStyleProcessors.js +2 -2
- package/dist/testing/loadEnv.d.ts +4 -1
- package/dist/testing/loadEnv.d.ts.map +1 -1
- package/dist/testing/loadEnv.js +5 -5
- package/dist/testing/temp/componentPackageMock.js +5 -5
- package/dist/testing/temp/contentHtmlElements.js +2 -2
- package/dist/throwError.js +2 -2
- package/dist/timeProfiler.d.ts +5 -1
- package/dist/timeProfiler.d.ts.map +1 -1
- package/dist/timeProfiler.js +76 -24
- package/dist/todo.js +2 -1
- package/dist/update/integrateUpdateVdom.d.ts.map +1 -1
- package/dist/update/integrateUpdateVdom.js +44 -41
- package/dist/update/integrateUpdateVdomPrebuild.js +5 -5
- package/dist/validChildren.js +2 -2
- package/dist/warnOnFrameworkChange.js +2 -2
- package/dist/watch.js +2 -2
- package/dist/zones/react.js +3 -3
- package/package.json +27 -39
- package/types/modules.d.ts +2 -1
- package/vendor/babel-core.js +26 -0
- package/vendor/babel-parser.js +9 -0
- package/vendor/babel-plugin-syntax-import-assertions.js +50 -0
- package/vendor/babel-preset-react.js +872 -0
- package/vendor/babel-preset-typescript.js +26 -0
- package/vendor/babel-types.js +9 -0
- package/vendor/chalk-extensions.js +1994 -0
- package/vendor/chalk.js +647 -0
- package/vendor/chokidar.js +6889 -0
- package/vendor/chunk-1TN2rK3j.js +1218 -0
- package/vendor/chunk-1UuLTU0U.js +34 -0
- package/vendor/chunk-B_NeooyV.js +86 -0
- package/vendor/chunk-C12hSZn7.js +88 -0
- package/vendor/chunk-C3YkUGz5.js +19 -0
- package/vendor/chunk-C3fcZDjl.js +41964 -0
- package/vendor/chunk-C9FSKeSx.js +14603 -0
- package/vendor/chunk-CPArXGxa.js +14623 -0
- package/vendor/cjs-module-lexer.js +6 -0
- package/vendor/dotenv.js +412 -0
- package/vendor/express.js +40577 -0
- package/vendor/import-meta-resolve.js +2201 -0
- package/vendor/manifest.json +29 -0
- package/vendor/postcss.js +8546 -0
- package/vendor/serialize-javascript.js +293 -0
- package/vendor/sxy-lib-arrays.js +113 -0
- package/vendor/sxy-lib-object-copy.js +1781 -0
- package/vendor/sxy-lib-objects.js +156 -0
- package/vendor/sxy-lib-promises.js +47 -0
- package/vendor/sxy-package-investigator.js +202 -0
- package/vendor/valibot.js +7664 -0
- package/dist/Servers/hono/DevServerHono.d.ts +0 -2
- package/dist/Servers/hono/DevServerHono.d.ts.map +0 -1
- package/dist/Servers/hono/DevServerHono.js +0 -423
- package/dist/Servers/hono/ProdServerHono.d.ts +0 -2
- package/dist/Servers/hono/ProdServerHono.d.ts.map +0 -1
- package/dist/Servers/hono/ProdServerHono.js +0 -220
- package/dist/Servers/hono/TungstenServerHono.d.ts +0 -6
- package/dist/Servers/hono/TungstenServerHono.d.ts.map +0 -1
- package/dist/Servers/hono/TungstenServerHono.js +0 -36
- package/dist/api/ApiEndpointHono.d.ts +0 -3
- package/dist/api/ApiEndpointHono.d.ts.map +0 -1
- package/dist/api/ApiEndpointHono.js +0 -1
- package/dist/api/ApiRouteHono.d.ts +0 -7
- package/dist/api/ApiRouteHono.d.ts.map +0 -1
- package/dist/api/ApiRouteHono.js +0 -1
- package/dist/api/ApiRoutesHono.d.ts +0 -5
- package/dist/api/ApiRoutesHono.d.ts.map +0 -1
- package/dist/api/ApiRoutesHono.js +0 -1
- package/dist/api/getApiRoutesHono.d.ts +0 -6
- package/dist/api/getApiRoutesHono.d.ts.map +0 -1
- package/dist/api/getApiRoutesHono.js +0 -14
- package/dist/build/compilePackages.d.ts +0 -2
- package/dist/build/compilePackages.d.ts.map +0 -1
- package/dist/build/compilePackages.js +0 -89
- package/dist/build/findRequiredUserModule.d.ts +0 -2
- package/dist/build/findRequiredUserModule.d.ts.map +0 -1
- package/dist/build/findRequiredUserModule.js +0 -36
- package/dist/build/processPackage.d.ts +0 -4
- package/dist/build/processPackage.d.ts.map +0 -1
- package/dist/build/processPackage.js +0 -91
- package/dist/build/tallyBabelPlugins.d.ts +0 -3
- package/dist/build/tallyBabelPlugins.d.ts.map +0 -1
- package/dist/build/tallyBabelPlugins.js +0 -68
- package/dist/testing/loadEnvSetup.d.ts +0 -2
- package/dist/testing/loadEnvSetup.d.ts.map +0 -1
- package/dist/testing/loadEnvSetup.js +0 -7
- package/sxy-loader.config.js +0 -7
package/dist/env/Env.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// const globalObj = (typeof window !== 'undefined') ? window : global
|
|
2
2
|
export {};
|
|
3
3
|
// console.log('providing env')
|
|
4
|
-
// // eslint-disable-next-line
|
|
4
|
+
// // eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion
|
|
5
5
|
// export const tungstenPrivateEnv = globalObj.tungstenPrivateEnv as TungstenPrivateEnv
|
|
6
|
-
// // eslint-disable-next-line
|
|
6
|
+
// // eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion
|
|
7
7
|
// export const tungstenPublicEnv = globalObj.tungstenPublicEnv as TungstenPublicEnv
|
package/dist/env/addToEnv.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { cliWarn } from
|
|
1
|
+
import { cliWarn } from '../cliOutput.js';
|
|
2
2
|
export function addToEnv(newEnv, env = process.env, prefix = '',
|
|
3
3
|
// the real (OS/shell) environment as it was before any .env file was loaded - these values
|
|
4
4
|
// always win over .env files, they're never overwritten, only warned about on conflict
|
package/dist/env/funcs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export * from
|
|
2
|
-
export * from
|
|
3
|
-
export * from
|
|
4
|
-
export * from
|
|
1
|
+
export * from './privateEnv.js';
|
|
2
|
+
export * from './privateEnvOrThrow.js';
|
|
3
|
+
export * from './publicEnv.js';
|
|
4
|
+
export * from './publicEnvOrThrow.js';
|
|
@@ -5,7 +5,7 @@ export type EnvSchemas = {
|
|
|
5
5
|
privateEnvSchema?: StandardSchema<TungstenEnv & TungstenPrivateEnv>;
|
|
6
6
|
publicEnvSchema?: StandardSchema<TungstenEnv & TungstenPublicEnv>;
|
|
7
7
|
};
|
|
8
|
-
export declare function getEnvSchemas(config: FrameworkConfigComplete, iteration: number, dev: 'dev'): Promise<EnvSchemas>;
|
|
8
|
+
export declare function getEnvSchemas(config: FrameworkConfigComplete, iteration: number, dev: 'dev', buildCodeFolder?: string): Promise<EnvSchemas>;
|
|
9
9
|
export declare function getEnvSchemas(config: FrameworkConfigComplete, iteration?: null, dev?: 'prod'): Promise<EnvSchemas>;
|
|
10
|
-
export declare function getEnvSchemasDev(config: FrameworkConfigComplete, iteration: number): Promise<EnvSchemas>;
|
|
10
|
+
export declare function getEnvSchemasDev(config: FrameworkConfigComplete, iteration: number, buildCodeFolder?: string): Promise<EnvSchemas>;
|
|
11
11
|
//# sourceMappingURL=getEnvSchemas.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getEnvSchemas.d.ts","sourceRoot":"","sources":["../../src/env/getEnvSchemas.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getEnvSchemas.d.ts","sourceRoot":"","sources":["../../src/env/getEnvSchemas.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,uBAAuB,CAAA;AAEpE,OAAO,EAAyB,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAMjF,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC,MAAM,MAAM,UAAU,GAAG;IACrB,gBAAgB,CAAC,EAAE,cAAc,CAAC,WAAW,GAAG,kBAAkB,CAAC,CAAC;IACpE,eAAe,CAAC,EAAE,cAAc,CAAC,WAAW,GAAG,iBAAiB,CAAC,CAAC;CACrE,CAAA;AAKD,wBAAsB,aAAa,CAC/B,MAAM,EAAE,uBAAuB,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,eAAe,CAAC,EAAE,MAAM,GACzF,OAAO,CAAC,UAAU,CAAC,CAAA;AACtB,wBAAsB,aAAa,CAAC,MAAM,EAAE,uBAAuB,EAAE,SAAS,CAAC,EAAE,IAAI,EAAE,GAAG,CAAC,EAAE,MAAM,GACjG,OAAO,CAAC,UAAU,CAAC,CAAA;AAwDrB,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,uBAAuB,EAAE,SAAS,EAAE,MAAM,EAAE,eAAe,CAAC,EAAE,MAAM,uBAG5G"}
|
|
@@ -1,17 +1,23 @@
|
|
|
1
1
|
import { join } from 'path';
|
|
2
|
-
import { checkIsStandardSchema } from
|
|
3
|
-
import { fixExtension } from
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
2
|
+
import { checkIsStandardSchema } from '../standardSchema.js';
|
|
3
|
+
import { fixExtension } from '../fixExtension.js';
|
|
4
|
+
import { devBuildFolder, prodBuildCodeFolder } from '../settings.js';
|
|
5
|
+
import { throwError } from '../throwError.js';
|
|
6
|
+
import { iterationQueryString } from '../iterationQueryString.js';
|
|
7
|
+
import { importDevModuleWithRetry } from '../importDevModuleWithRetry.js';
|
|
8
|
+
export async function getEnvSchemas(config, iteration = null, mode = 'prod',
|
|
9
|
+
// a compiled tree other than the mode's own - a test run's `compile --output`
|
|
10
|
+
buildCodeFolderOverride) {
|
|
8
11
|
const {
|
|
9
12
|
envSchemasLocation
|
|
10
13
|
} = config;
|
|
11
14
|
//if (envSchemasLocation === undefined) return {} // I think we're validating configs now, so don't need this
|
|
12
|
-
//console.log('envSchemasLocation', envSchemasLocation)
|
|
15
|
+
//console.log('envSchemasLocation', envSchemasLocation)
|
|
13
16
|
const projectDir = process.cwd();
|
|
14
|
-
|
|
17
|
+
// the compiled copy in the build, like every other module the server runs - codeDir may hold
|
|
18
|
+
// typescript (config.typescript) that node cannot import
|
|
19
|
+
const buildCodeFolder = buildCodeFolderOverride ?? (mode === 'dev' ? devBuildFolder : prodBuildCodeFolder);
|
|
20
|
+
const fullFilePath = 'file://' + join(projectDir, buildCodeFolder, fixExtension(envSchemasLocation));
|
|
15
21
|
let module;
|
|
16
22
|
try {
|
|
17
23
|
if (mode === 'dev') {
|
|
@@ -40,7 +46,7 @@ export async function getEnvSchemas(config, iteration = null, mode = 'prod') {
|
|
|
40
46
|
}
|
|
41
47
|
}
|
|
42
48
|
//export function getEnvSchemasDev(config: FrameworkConfigComplete, load: Load) {
|
|
43
|
-
export function getEnvSchemasDev(config, iteration) {
|
|
49
|
+
export function getEnvSchemasDev(config, iteration, buildCodeFolder) {
|
|
44
50
|
//return getEnvSchemas(config, load, true)
|
|
45
|
-
return getEnvSchemas(config, iteration, 'dev');
|
|
51
|
+
return getEnvSchemas(config, iteration, 'dev', buildCodeFolder);
|
|
46
52
|
}
|
package/dist/env/privateEnv.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { isClient } from
|
|
2
|
-
import { throwError } from
|
|
1
|
+
import { isClient } from '../isClient.js';
|
|
2
|
+
import { throwError } from '../throwError.js';
|
|
3
3
|
export function privateEnv(key) {
|
|
4
4
|
if (isClient) throw new Error('Error, tried to access privateEnv from client');
|
|
5
5
|
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
package/dist/env/publicEnv.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"windowGlobalEnvStatement.d.ts","sourceRoot":"","sources":["../../src/env/windowGlobalEnvStatement.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"windowGlobalEnvStatement.d.ts","sourceRoot":"","sources":["../../src/env/windowGlobalEnvStatement.ts"],"names":[],"mappings":"AAEA,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAE7E"}
|
package/dist/filePathFromUrl.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"findProjectDir.d.ts","sourceRoot":"","sources":["../src/findProjectDir.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"findProjectDir.d.ts","sourceRoot":"","sources":["../src/findProjectDir.ts"],"names":[],"mappings":"AAkBA,MAAM,MAAM,qBAAqB,GAAG;IAIhC,WAAW,CAAC,EAAE,OAAO,CAAA;CACxB,CAAA;AAED,wBAAgB,cAAc,CAAC,aAAa,EAAE,MAAM,EAAE,OAAO,GAAE,qBAA0B,UAkBxF"}
|
package/dist/findProjectDir.js
CHANGED
|
@@ -1,13 +1,27 @@
|
|
|
1
|
-
import { dirname } from 'path';
|
|
1
|
+
import { dirname, join } from 'path';
|
|
2
|
+
import { existsSync, readFileSync } from 'fs';
|
|
2
3
|
import { fileURLToPath } from 'url';
|
|
3
|
-
import
|
|
4
|
-
|
|
4
|
+
import { TungstenError } from './TungstenError.js';
|
|
5
|
+
// find-package-json in-house: every package.json from startLocation up to the root
|
|
6
|
+
function* packageJsonFinder(startLocation) {
|
|
7
|
+
let dir = startLocation;
|
|
8
|
+
for (;;) {
|
|
9
|
+
const filename = join(dir, 'package.json');
|
|
10
|
+
if (existsSync(filename)) yield {
|
|
11
|
+
filename,
|
|
12
|
+
value: JSON.parse(readFileSync(filename, 'utf8'))
|
|
13
|
+
};
|
|
14
|
+
const parent = dirname(dir);
|
|
15
|
+
if (parent === dir) return;
|
|
16
|
+
dir = parent;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
5
19
|
export function findProjectDir(startLocation, options = {}) {
|
|
6
20
|
if (startLocation.startsWith('file:')) startLocation = fileURLToPath(startLocation);
|
|
7
21
|
const finder = packageJsonFinder(startLocation);
|
|
8
22
|
let packageJson = finder.next();
|
|
9
23
|
if (options.requireName) {
|
|
10
|
-
while (!packageJson.done && !hasName(packageJson.value)) {
|
|
24
|
+
while (!packageJson.done && !hasName(packageJson.value.value)) {
|
|
11
25
|
packageJson = finder.next();
|
|
12
26
|
}
|
|
13
27
|
if (packageJson.done) {
|
|
@@ -18,7 +32,7 @@ export function findProjectDir(startLocation, options = {}) {
|
|
|
18
32
|
// couldn't find a package.json
|
|
19
33
|
throw new TungstenError(`findProjectDir() error - could not find the package.json is the project directory`);
|
|
20
34
|
}
|
|
21
|
-
return dirname(packageJson.filename);
|
|
35
|
+
return dirname(packageJson.value.filename);
|
|
22
36
|
}
|
|
23
37
|
function hasName(packageJson) {
|
|
24
38
|
return typeof packageJson === 'object' && packageJson !== null && 'name' in packageJson && typeof packageJson.name === 'string' && packageJson.name !== '';
|
package/dist/findUserConfig.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import fs from 'fs';
|
|
2
|
-
import slash from 'slash';
|
|
3
|
-
import { loadPackageDotJsonFromDir } from
|
|
4
|
-
import { configName } from
|
|
5
|
-
import { cliNote, cliWarn } from
|
|
6
|
-
import { TungstenError } from
|
|
7
|
-
import { packageNameCapitalized } from
|
|
2
|
+
import slash from './slash.js';
|
|
3
|
+
import { loadPackageDotJsonFromDir } from './loadPackageDotJsonFromDir.js';
|
|
4
|
+
import { configName } from './packageSettings.js';
|
|
5
|
+
import { cliNote, cliWarn } from './cliOutput.js';
|
|
6
|
+
import { TungstenError } from './TungstenError.js';
|
|
7
|
+
import { packageNameCapitalized } from './settings.js';
|
|
8
8
|
//import { throwError } from './throwError.js'
|
|
9
9
|
export async function findUserConfig(projectDir, volume = 'noisy') {
|
|
10
|
-
const packageConfig = await loadPackageDotJsonFromDir(projectDir); // eslint-disable-line
|
|
10
|
+
const packageConfig = await loadPackageDotJsonFromDir(projectDir); // eslint-disable-line @typescript-eslint/no-unsafe-type-assertion
|
|
11
11
|
if (packageConfig === null) {
|
|
12
12
|
throw new TungstenError(`findUserConfig() error: Could not find project tungsten config`);
|
|
13
13
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fixExtension.d.ts","sourceRoot":"","sources":["../src/fixExtension.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fixExtension.d.ts","sourceRoot":"","sources":["../src/fixExtension.ts"],"names":[],"mappings":"AAGA,wBAAgB,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAKrD"}
|
package/dist/fixExtension.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
// a configured source path (Root.jsx, Root.tsx, env.ts) to its name in the build, where
|
|
2
|
+
// everything compiled is .js
|
|
1
3
|
export function fixExtension(filePath) {
|
|
2
|
-
if (filePath.endsWith('.jsx'))
|
|
3
|
-
|
|
4
|
-
}
|
|
4
|
+
if (filePath.endsWith('.jsx')) return filePath.slice(0, -1);
|
|
5
|
+
if (filePath.endsWith('.tsx')) return `${filePath.slice(0, -3)}js`;
|
|
6
|
+
if (filePath.endsWith('.ts')) return `${filePath.slice(0, -2)}js`;
|
|
5
7
|
return filePath;
|
|
6
8
|
}
|
package/dist/foreach.js
CHANGED
|
@@ -4,6 +4,7 @@ export function foreach(list, callback) {
|
|
|
4
4
|
if (Array.isArray(list)) {
|
|
5
5
|
return list.map(callback);
|
|
6
6
|
} else if (typeof list === 'object' && list !== null) {
|
|
7
|
+
// eslint-disable-line @typescript-eslint/no-unnecessary-condition -- runtime callers may pass anything
|
|
7
8
|
//return Object.entries(list).map(([key, value]) => (callback as ObjectCallback<L, R>)(value, key, list))
|
|
8
9
|
const result = [];
|
|
9
10
|
for (const key in list) {
|
|
@@ -11,6 +11,7 @@ export declare const frameworkConfigValidator: v.VariantSchema<"useRootComponent
|
|
|
11
11
|
readonly exclude: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
12
12
|
readonly copyExclude: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
13
13
|
readonly sourceDir: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
14
|
+
readonly typescript: v.ExactOptionalSchema<v.BooleanSchema<undefined>, undefined>;
|
|
14
15
|
readonly publicDir: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
15
16
|
readonly assetsDir: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
16
17
|
readonly styleImportBase: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
@@ -25,9 +26,16 @@ export declare const frameworkConfigValidator: v.VariantSchema<"useRootComponent
|
|
|
25
26
|
readonly packageSystem: v.ExactOptionalSchema<v.PicklistSchema<["rewrites", "aliases"], undefined>, undefined>;
|
|
26
27
|
readonly ignoreDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
27
28
|
readonly ignorePatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
29
|
+
readonly clientDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
30
|
+
readonly clientPatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
31
|
+
readonly rawDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
32
|
+
readonly rawPatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
28
33
|
readonly testDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
29
34
|
readonly testPatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
30
35
|
readonly skipPackageCompilation: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
36
|
+
readonly build: v.ExactOptionalSchema<v.ObjectSchema<{
|
|
37
|
+
readonly targets: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
38
|
+
}, undefined>, undefined>;
|
|
31
39
|
readonly serverMiddleware: v.ExactOptionalSchema<v.TupleSchema<[v.StringSchema<undefined>, v.StringSchema<undefined>, v.StringSchema<undefined>], undefined>, undefined>;
|
|
32
40
|
readonly apiRoutes: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
33
41
|
readonly apiPath: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
@@ -39,6 +47,7 @@ export declare const frameworkConfigValidator: v.VariantSchema<"useRootComponent
|
|
|
39
47
|
readonly exclude: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
40
48
|
readonly copyExclude: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
41
49
|
readonly sourceDir: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
50
|
+
readonly typescript: v.ExactOptionalSchema<v.BooleanSchema<undefined>, undefined>;
|
|
42
51
|
readonly publicDir: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
43
52
|
readonly assetsDir: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
44
53
|
readonly styleImportBase: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
@@ -53,9 +62,16 @@ export declare const frameworkConfigValidator: v.VariantSchema<"useRootComponent
|
|
|
53
62
|
readonly packageSystem: v.ExactOptionalSchema<v.PicklistSchema<["rewrites", "aliases"], undefined>, undefined>;
|
|
54
63
|
readonly ignoreDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
55
64
|
readonly ignorePatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
65
|
+
readonly clientDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
66
|
+
readonly clientPatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
67
|
+
readonly rawDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
68
|
+
readonly rawPatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
56
69
|
readonly testDirs: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
57
70
|
readonly testPatterns: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
58
71
|
readonly skipPackageCompilation: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
72
|
+
readonly build: v.ExactOptionalSchema<v.ObjectSchema<{
|
|
73
|
+
readonly targets: v.ExactOptionalSchema<v.UnionSchema<[v.StringSchema<undefined>, v.ArraySchema<v.StringSchema<undefined>, undefined>], undefined>, undefined>;
|
|
74
|
+
}, undefined>, undefined>;
|
|
59
75
|
readonly serverMiddleware: v.ExactOptionalSchema<v.TupleSchema<[v.StringSchema<undefined>, v.StringSchema<undefined>, v.StringSchema<undefined>], undefined>, undefined>;
|
|
60
76
|
readonly apiRoutes: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
61
77
|
readonly apiPath: v.ExactOptionalSchema<v.StringSchema<undefined>, undefined>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"frameworkConfigSchema.d.ts","sourceRoot":"","sources":["../src/frameworkConfigSchema.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,aAAa,IAAI,kBAAkB,EAAE,MAAM,eAAe,CAAA;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAGnD,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAI5B,MAAM,WAAW,YAAa,SAAQ,kBAAkB;CAAG;
|
|
1
|
+
{"version":3,"file":"frameworkConfigSchema.d.ts","sourceRoot":"","sources":["../src/frameworkConfigSchema.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,aAAa,IAAI,kBAAkB,EAAE,MAAM,eAAe,CAAA;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAGnD,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAI5B,MAAM,WAAW,YAAa,SAAQ,kBAAkB;CAAG;AAwE3D,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0BAGnC,CAAA;AAEF,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,wBAAwB,CAAC,CAAA"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import * as v from 'valibot';
|
|
4
4
|
// shape only - babel validates its own options, and a hand-copied key list just drifts from theirs
|
|
5
5
|
const babelParserOptionsSchema = v.pipe(v.looseObject({}),
|
|
6
|
-
// eslint-disable-next-line
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion -- see above
|
|
7
7
|
v.transform(options => options));
|
|
8
8
|
const stringOrStrings = v.union([v.string(), v.array(v.string())]);
|
|
9
9
|
const frameworkConfigBaseEntries = {
|
|
@@ -12,12 +12,14 @@ const frameworkConfigBaseEntries = {
|
|
|
12
12
|
exclude: v.exactOptional(v.string()),
|
|
13
13
|
copyExclude: v.exactOptional(v.string()),
|
|
14
14
|
sourceDir: v.exactOptional(v.string()),
|
|
15
|
+
// compile .ts/.tsx in codeDir directly (babel strips types); the app keeps only a type checker
|
|
16
|
+
typescript: v.exactOptional(v.boolean()),
|
|
15
17
|
publicDir: v.exactOptional(v.string()),
|
|
16
18
|
assetsDir: v.exactOptional(v.string()),
|
|
17
19
|
styleImportBase: v.exactOptional(v.string()),
|
|
18
20
|
// valibot has no template-literal schema, so the regex proves what the cast then states
|
|
19
21
|
siteBasePath: v.exactOptional(v.pipe(v.union([v.literal(''), v.pipe(v.string(), v.regex(/^\/.*$/))]),
|
|
20
|
-
// eslint-disable-next-line
|
|
22
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion -- see above
|
|
21
23
|
v.transform(path => path))),
|
|
22
24
|
clientSideNav: v.exactOptional(v.boolean()),
|
|
23
25
|
staticSite: v.exactOptional(v.boolean()),
|
|
@@ -31,10 +33,20 @@ const frameworkConfigBaseEntries = {
|
|
|
31
33
|
// rename to ignoreFolders?
|
|
32
34
|
ignorePatterns: v.exactOptional(stringOrStrings),
|
|
33
35
|
// test files: left out of every compile unless `tungsten compile --tests` asks for them -
|
|
36
|
+
// which sources each pipeline compiles (see FrameworkConfig.ts): unset, client is everything
|
|
37
|
+
// and raw is nothing
|
|
38
|
+
clientDirs: v.exactOptional(stringOrStrings),
|
|
39
|
+
clientPatterns: v.exactOptional(stringOrStrings),
|
|
40
|
+
rawDirs: v.exactOptional(stringOrStrings),
|
|
41
|
+
rawPatterns: v.exactOptional(stringOrStrings),
|
|
34
42
|
// the same two shapes as ignoreDirs/ignorePatterns
|
|
35
43
|
testDirs: v.exactOptional(stringOrStrings),
|
|
36
44
|
testPatterns: v.exactOptional(stringOrStrings),
|
|
37
45
|
skipPackageCompilation: v.exactOptional(stringOrStrings),
|
|
46
|
+
build: v.exactOptional(v.object({
|
|
47
|
+
// browserslist query the production bundle is lowered to; unset = the framework default
|
|
48
|
+
targets: v.exactOptional(stringOrStrings)
|
|
49
|
+
})),
|
|
38
50
|
serverMiddleware: v.exactOptional(v.tuple([v.string(), v.string(), v.string()])),
|
|
39
51
|
apiRoutes: v.exactOptional(v.string()),
|
|
40
52
|
apiPath: v.exactOptional(v.string()),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getComponent.d.ts","sourceRoot":"","sources":["../src/getComponent.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getComponent.d.ts","sourceRoot":"","sources":["../src/getComponent.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAA;AAG7D,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAA;AAOhC,wBAAsB,YAAY,CAC9B,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,MAAM,EAEhB,SAAS,GAAE,MAAM,GAAG,IAAW,EAC/B,IAAI,GAAE,IAAa,GACpB,OAAO,CAAC,gBAAgB,CAAC,CA6B3B"}
|
package/dist/getComponent.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { fixExtension } from
|
|
2
|
-
import { TungstenError } from
|
|
3
|
-
import { throwError } from
|
|
4
|
-
import { iterationQueryString } from
|
|
5
|
-
import { importDevModuleWithRetry } from
|
|
1
|
+
import { fixExtension } from './fixExtension.js';
|
|
2
|
+
import { TungstenError } from './TungstenError.js';
|
|
3
|
+
import { throwError } from './throwError.js';
|
|
4
|
+
import { iterationQueryString } from './iterationQueryString.js';
|
|
5
|
+
import { importDevModuleWithRetry } from './importDevModuleWithRetry.js';
|
|
6
6
|
//let load //// !! future improvement
|
|
7
7
|
export async function getComponent(filePath, filename,
|
|
8
8
|
//load: Load | null = null,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getComponentDev.d.ts","sourceRoot":"","sources":["../src/getComponentDev.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getComponentDev.d.ts","sourceRoot":"","sources":["../src/getComponentDev.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAA;AAI7D,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAGhH"}
|
package/dist/getComponentDev.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getComponent } from
|
|
1
|
+
import { getComponent } from './getComponent.js';
|
|
2
2
|
//export function getComponentDev(filePath: string, filename: string, load: Load): Promise<AnyComponentType> {
|
|
3
3
|
export function getComponentDev(filePath, filename, iteration) {
|
|
4
4
|
//return getComponent(filePath, filename, load, true)
|
package/dist/getFrameworkDir.js
CHANGED
package/dist/getRoutes.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getRoutes.d.ts","sourceRoot":"","sources":["../src/getRoutes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getRoutes.d.ts","sourceRoot":"","sources":["../src/getRoutes.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAA;AACvD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAA;AAGrC,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAA;AAE9D,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAM5D,wBAAsB,SAAS,CAC3B,eAAe,EAAE,eAAe,EAChC,MAAM,EAAE,uBAAuB,EAE/B,SAAS,GAAE,MAAM,GAAG,IAAW,EAC/B,IAAI,GAAE,IAAa,GACnB,OAAO,CAAC,SAAS,CAAC,CA0BrB"}
|
package/dist/getRoutes.js
CHANGED
|
@@ -1,36 +1,27 @@
|
|
|
1
1
|
import { join } from 'path';
|
|
2
|
-
import { fixExtension } from
|
|
3
|
-
import { TungstenError } from
|
|
4
|
-
import { iterationQueryString } from
|
|
5
|
-
import { throwError } from
|
|
6
|
-
import { importDevModuleWithRetry } from
|
|
2
|
+
import { fixExtension } from './fixExtension.js';
|
|
3
|
+
import { TungstenError } from './TungstenError.js';
|
|
4
|
+
import { iterationQueryString } from './iterationQueryString.js';
|
|
5
|
+
import { throwError } from './throwError.js';
|
|
6
|
+
import { importDevModuleWithRetry } from './importDevModuleWithRetry.js';
|
|
7
7
|
export async function getRoutes(compilationInfo, config,
|
|
8
8
|
//load: Load | null = null,
|
|
9
9
|
iteration = null, mode = 'prod') {
|
|
10
10
|
//console.log('config.routesLocation', config.routesLocation)
|
|
11
11
|
//console.log('config.routesLocation', config.routesLocation)
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
const [routesFile, routeExport] = config.routesLocation;
|
|
13
|
+
const filePath = 'file://' + fixExtension(join(compilationInfo.buildCodeLocation, routesFile));
|
|
14
|
+
let module;
|
|
15
|
+
if (mode === 'dev') {
|
|
16
|
+
if (iteration === null) throwError('getComponent()', 'iteration is null in dev mode');
|
|
17
|
+
// can we share load across the render?
|
|
18
|
+
module = await importDevModuleWithRetry(iterationQueryString(filePath, iteration));
|
|
15
19
|
} else {
|
|
16
|
-
|
|
17
|
-
//console.log(join(compilationInfo.location, routesFile))
|
|
18
|
-
//console.log(fixExtension( join(compilationInfo.location, routesFile) ))
|
|
19
|
-
const filePath = 'file://' + fixExtension(join(compilationInfo.buildCodeLocation, routesFile));
|
|
20
|
-
let module;
|
|
21
|
-
if (mode === 'dev') {
|
|
22
|
-
if (iteration === null) throwError('getComponent()', 'iteration is null in dev mode');
|
|
23
|
-
// can we share load across the render?
|
|
24
|
-
//const load = await createLoad(import.meta.url, sxyLoaderConfig)
|
|
25
|
-
//module = await load(filePath)
|
|
26
|
-
module = await importDevModuleWithRetry(iterationQueryString(filePath, iteration));
|
|
27
|
-
} else {
|
|
28
|
-
module = await import(filePath); // import the module
|
|
29
|
-
}
|
|
30
|
-
// use the config to determine the export name
|
|
31
|
-
if (!(routeExport in module)) {
|
|
32
|
-
throw new TungstenError(`Could not find an export named ${routeExport} in routes file ${routesFile}.` + ` These settings are set in config.routesLocation.`);
|
|
33
|
-
}
|
|
34
|
-
return module[routeExport];
|
|
20
|
+
module = await import(filePath); // import the module
|
|
35
21
|
}
|
|
22
|
+
// use the config to determine the export name
|
|
23
|
+
if (!(routeExport in module)) {
|
|
24
|
+
throw new TungstenError(`Could not find an export named ${routeExport} in routes file ${routesFile}.` + ` These settings are set in config.routesLocation.`);
|
|
25
|
+
}
|
|
26
|
+
return module[routeExport];
|
|
36
27
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getRoutesDevs.d.ts","sourceRoot":"","sources":["../src/getRoutesDevs.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getRoutesDevs.d.ts","sourceRoot":"","sources":["../src/getRoutesDevs.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAA;AACnE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAKjE,wBAAgB,YAAY,CAAC,eAAe,EAAE,eAAe,EAAE,MAAM,EAAE,uBAAuB,EAAE,SAAS,EAAE,MAAM,uDAGhH"}
|
package/dist/getRoutesDevs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getRoutes } from
|
|
1
|
+
import { getRoutes } from './getRoutes.js';
|
|
2
2
|
// async
|
|
3
3
|
//export function getRoutesDev(compilationInfo: CompilationInfo, config: FrameworkConfigComplete, load: Load) {
|
|
4
4
|
export function getRoutesDev(compilationInfo, config, iteration) {
|
package/dist/getStackTrace.js
CHANGED
package/dist/getUserConfig.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defaultConfig } from
|
|
2
|
-
import { findUserConfig } from
|
|
3
|
-
import { frameworkConfigValidator } from
|
|
4
|
-
import { makeFinalConfig } from
|
|
5
|
-
import { throwError } from
|
|
6
|
-
import { cliOut } from
|
|
7
|
-
import { validate } from
|
|
1
|
+
import { defaultConfig } from './defaultConfig.js';
|
|
2
|
+
import { findUserConfig } from './findUserConfig.js';
|
|
3
|
+
import { frameworkConfigValidator } from './frameworkConfigSchema.js';
|
|
4
|
+
import { makeFinalConfig } from './makeFinalConfig.js';
|
|
5
|
+
import { throwError } from './throwError.js';
|
|
6
|
+
import { cliOut } from './cliOutput.js';
|
|
7
|
+
import { validate } from './standardSchema.js';
|
|
8
8
|
export async function getUserConfig(overrides = null, volume = 'noisy') {
|
|
9
9
|
const userConfigOrNull = await findUserConfig(process.cwd(), volume);
|
|
10
10
|
//frameworkCon
|
package/dist/glob.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"glob.d.ts","sourceRoot":"","sources":["../src/glob.ts"],"names":[],"mappings":"AA8CA,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAEpD;AAyBD,wBAAsB,IAAI,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,EAAE,EAAE,OAAO,GAAE;IAAE,GAAG,CAAC,EAAE,MAAM,CAAA;CAAO,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAyBzG"}
|
package/dist/glob.js
ADDED
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { readdirSync } from 'fs';
|
|
2
|
+
import { isAbsolute } from 'path';
|
|
3
|
+
import slash from './slash.js';
|
|
4
|
+
// globby's job for the patterns tungsten uses (`**`, `*`, `?`, `{a,b}`, `[…]`, `!` excludes):
|
|
5
|
+
// a sync walk from each pattern's static prefix, matched with precompiled regexes. Results are
|
|
6
|
+
// absolute forward-slash paths. Dot segments are skipped, node_modules is not - both as globby
|
|
7
|
+
// did. Sync on purpose: node's fs.glob and a promise-per-directory walk both sat behind the
|
|
8
|
+
// sync sass compile at startup (35ms standalone, ~380ms in dev), a sync walk cannot.
|
|
9
|
+
const globChars = /[*?{[]/;
|
|
10
|
+
function escapeRegExp(text) {
|
|
11
|
+
return text.replace(/[.+^$()|\\]/g, '\\$&');
|
|
12
|
+
}
|
|
13
|
+
// glob source -> regex source, no anchors
|
|
14
|
+
function convert(pattern) {
|
|
15
|
+
let out = '';
|
|
16
|
+
for (let i = 0; i < pattern.length; i++) {
|
|
17
|
+
const char = pattern[i];
|
|
18
|
+
if (char === '*') {
|
|
19
|
+
if (pattern[i + 1] === '*') {
|
|
20
|
+
if (pattern[i + 2] === '/') {
|
|
21
|
+
out += '(?:[^/]*/)*';
|
|
22
|
+
i += 2;
|
|
23
|
+
} // any depth, including none
|
|
24
|
+
else {
|
|
25
|
+
out += '.*';
|
|
26
|
+
i += 1;
|
|
27
|
+
}
|
|
28
|
+
} else out += '[^/]*';
|
|
29
|
+
} else if (char === '?') {
|
|
30
|
+
out += '[^/]';
|
|
31
|
+
} else if (char === '{') {
|
|
32
|
+
const end = pattern.indexOf('}', i);
|
|
33
|
+
if (end === -1) {
|
|
34
|
+
out += '\\{';
|
|
35
|
+
continue;
|
|
36
|
+
}
|
|
37
|
+
out += `(?:${pattern.slice(i + 1, end).split(',').map(convert).join('|')})`;
|
|
38
|
+
i = end;
|
|
39
|
+
} else if (char === '[') {
|
|
40
|
+
const end = pattern.indexOf(']', i);
|
|
41
|
+
if (end === -1) {
|
|
42
|
+
out += '\\[';
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
const body = pattern.slice(i + 1, end);
|
|
46
|
+
out += `[${body.startsWith('!') ? '^' + body.slice(1) : body}]`;
|
|
47
|
+
i = end;
|
|
48
|
+
} else {
|
|
49
|
+
out += escapeRegExp(char ?? '');
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
return out;
|
|
53
|
+
}
|
|
54
|
+
export function globToRegExp(pattern) {
|
|
55
|
+
return new RegExp(`^${convert(pattern)}$`);
|
|
56
|
+
}
|
|
57
|
+
// the directory to walk: the segments before the first one holding a glob character
|
|
58
|
+
function staticPrefix(pattern) {
|
|
59
|
+
const segments = pattern.split('/');
|
|
60
|
+
const firstGlob = segments.findIndex(segment => globChars.test(segment));
|
|
61
|
+
return (firstGlob === -1 ? segments.slice(0, -1) : segments.slice(0, firstGlob)).join('/');
|
|
62
|
+
}
|
|
63
|
+
function walk(dir, files = []) {
|
|
64
|
+
let entries;
|
|
65
|
+
try {
|
|
66
|
+
entries = readdirSync(dir, {
|
|
67
|
+
withFileTypes: true
|
|
68
|
+
});
|
|
69
|
+
} catch (error) {
|
|
70
|
+
if (error.code === 'ENOENT') return files; // eslint-disable-line @typescript-eslint/no-unsafe-type-assertion -- fs errors carry a code
|
|
71
|
+
throw error;
|
|
72
|
+
}
|
|
73
|
+
for (const entry of entries) {
|
|
74
|
+
if (entry.name.startsWith('.')) continue;
|
|
75
|
+
if (entry.isDirectory()) walk(`${dir}/${entry.name}`, files);else if (entry.isFile()) files.push(`${dir}/${entry.name}`);
|
|
76
|
+
}
|
|
77
|
+
return files;
|
|
78
|
+
}
|
|
79
|
+
export async function glob(patterns, options = {}) {
|
|
80
|
+
const cwd = slash(options.cwd ?? process.cwd());
|
|
81
|
+
const full = pattern => {
|
|
82
|
+
const normalised = slash(pattern);
|
|
83
|
+
return isAbsolute(normalised) ? normalised : `${cwd}/${normalised}`;
|
|
84
|
+
};
|
|
85
|
+
const list = (Array.isArray(patterns) ? patterns : [patterns]).map(slash);
|
|
86
|
+
const includes = list.filter(pattern => !pattern.startsWith('!')).map(full);
|
|
87
|
+
const excludes = list.filter(pattern => pattern.startsWith('!')).map(pattern => globToRegExp(full(pattern.slice(1))));
|
|
88
|
+
// one walk per distinct base, every include tested against each of its files
|
|
89
|
+
const byBase = new Map();
|
|
90
|
+
for (const pattern of includes) {
|
|
91
|
+
const base = staticPrefix(pattern);
|
|
92
|
+
byBase.set(base, [...(byBase.get(base) ?? []), globToRegExp(pattern)]);
|
|
93
|
+
}
|
|
94
|
+
const found = new Set();
|
|
95
|
+
for (const [base, matchers] of byBase) {
|
|
96
|
+
for (const file of walk(base)) {
|
|
97
|
+
if (!matchers.some(matcher => matcher.test(file))) continue;
|
|
98
|
+
if (excludes.some(matcher => matcher.test(file))) continue;
|
|
99
|
+
found.add(file);
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
return [...found];
|
|
103
|
+
}
|
package/dist/hasValidKey.js
CHANGED
|
@@ -11,10 +11,10 @@ export function getFetchCompatibleHeaders(req) {
|
|
|
11
11
|
...restHeaders
|
|
12
12
|
} = req.headers;
|
|
13
13
|
const headers = block(
|
|
14
|
-
// eslint-disable-line
|
|
14
|
+
// eslint-disable-line @typescript-eslint/no-unsafe-type-assertion -- this refers to the typecast at the end of this block: recast it as a record to avoid difficulty getting required values of partials
|
|
15
15
|
// Headers will all be strings, except for set-cookie, so we will override the types from @types/node here
|
|
16
16
|
restHeaders,
|
|
17
|
-
// eslint-disable-line
|
|
17
|
+
// eslint-disable-line @typescript-eslint/no-unsafe-type-assertion -- countering bad typing in @types/node for 'http' incoming headers
|
|
18
18
|
header => header === undefined);
|
|
19
19
|
return new Headers({
|
|
20
20
|
...headers
|