diff --git a/packages/build-info/e2e/fixture/index.html b/packages/build-info/e2e/fixture/index.html
index aaa8a8ddb7..a093835a91 100644
--- a/packages/build-info/e2e/fixture/index.html
+++ b/packages/build-info/e2e/fixture/index.html
@@ -1,4 +1,4 @@
-
+
diff --git a/packages/build-info/index.html b/packages/build-info/index.html
index 02cee41633..bbfee57454 100644
--- a/packages/build-info/index.html
+++ b/packages/build-info/index.html
@@ -1,4 +1,4 @@
-
+
diff --git a/packages/build-info/src/browser/file-system.ts b/packages/build-info/src/browser/file-system.ts
index 7fc854fdbe..27fcef2c46 100644
--- a/packages/build-info/src/browser/file-system.ts
+++ b/packages/build-info/src/browser/file-system.ts
@@ -2,7 +2,10 @@ import { DirType, Environment, FileSystem } from '../file-system.js'
/** A sample implementation of a GitHub provider */
export class GithubProvider {
- constructor(public repo: string, public branch?: string) {}
+ constructor(
+ public repo: string,
+ public branch?: string,
+ ) {}
async dir(filePath = ''): Promise<{ path: string; type: 'file' | 'dir' }[]> {
let path = `/repos/${this.repo}/contents${filePath}`
diff --git a/packages/build-info/src/project.ts b/packages/build-info/src/project.ts
index a528c047b4..9f3ca27f8d 100644
--- a/packages/build-info/src/project.ts
+++ b/packages/build-info/src/project.ts
@@ -103,7 +103,11 @@ export class Project {
return await this.fs.fileExists(this.fs.resolve(this.fs.cwd, 'redwood.toml'))
}
- constructor(public fs: FileSystem, baseDirectory?: string, root?: string) {
+ constructor(
+ public fs: FileSystem,
+ baseDirectory?: string,
+ root?: string,
+ ) {
this.baseDirectory = fs.resolve(root || '', baseDirectory !== undefined ? baseDirectory : fs.cwd)
this.root = root ? fs.resolve(fs.cwd, root) : undefined
diff --git a/packages/build-info/src/workspaces/get-workspace-packages.ts b/packages/build-info/src/workspaces/get-workspace-packages.ts
index 59d0c163fa..eac0d43f9b 100644
--- a/packages/build-info/src/workspaces/get-workspace-packages.ts
+++ b/packages/build-info/src/workspaces/get-workspace-packages.ts
@@ -66,8 +66,8 @@ export async function findPackages(
const startDir = project.jsWorkspaceRoot
? project.fs.resolve(project.jsWorkspaceRoot, dir)
: project.root
- ? project.fs.resolve(project.root, dir)
- : project.fs.resolve(dir)
+ ? project.fs.resolve(project.root, dir)
+ : project.fs.resolve(dir)
try {
content = await project.fs.readDir(startDir, true)
} catch (err) {
diff --git a/packages/config/src/env/main.ts b/packages/config/src/env/main.ts
index 5ce066ba93..2c6ff08f94 100644
--- a/packages/config/src/env/main.ts
+++ b/packages/config/src/env/main.ts
@@ -130,12 +130,15 @@ const getGeneralEnv = async function ({
const getInternalEnv = function (
cachedEnv: Record,
): Record {
- return Object.entries(cachedEnv).reduce((prev, [key, { sources, value }]) => {
- if (sources.includes('internal')) {
- prev[key] = value
- }
- return prev
- }, {} as Record)
+ return Object.entries(cachedEnv).reduce(
+ (prev, [key, { sources, value }]) => {
+ if (sources.includes('internal')) {
+ prev[key] = value
+ }
+ return prev
+ },
+ {} as Record,
+ )
}
const getDeployUrls = function ({
diff --git a/packages/edge-bundler/node/bundler.ts b/packages/edge-bundler/node/bundler.ts
index 4c001a4e62..6de583622c 100644
--- a/packages/edge-bundler/node/bundler.ts
+++ b/packages/edge-bundler/node/bundler.ts
@@ -241,14 +241,17 @@ interface CreateFunctionConfigOptions {
}
const createFunctionConfig = ({ internalFunctionsWithConfig, declarations }: CreateFunctionConfigOptions) =>
- Object.entries(internalFunctionsWithConfig).reduce((acc, [functionName, config]) => {
- const mergedConfigFields = mergeWithDeclarationConfig({ functionName, config, declarations })
-
- return {
- ...acc,
- [functionName]: addGeneratorFallback(mergedConfigFields),
- }
- }, {} as Record)
+ Object.entries(internalFunctionsWithConfig).reduce(
+ (acc, [functionName, config]) => {
+ const mergedConfigFields = mergeWithDeclarationConfig({ functionName, config, declarations })
+
+ return {
+ ...acc,
+ [functionName]: addGeneratorFallback(mergedConfigFields),
+ }
+ },
+ {} as Record,
+ )
interface VendorNPMOptions {
basePath: string
diff --git a/packages/framework-info/index.html b/packages/framework-info/index.html
index 677ac9d101..d1268d76ed 100644
--- a/packages/framework-info/index.html
+++ b/packages/framework-info/index.html
@@ -1,4 +1,4 @@
-
+
diff --git a/packages/zip-it-and-ship-it/src/main.ts b/packages/zip-it-and-ship-it/src/main.ts
index 9a81132629..8c2acd50ce 100644
--- a/packages/zip-it-and-ship-it/src/main.ts
+++ b/packages/zip-it-and-ship-it/src/main.ts
@@ -158,7 +158,7 @@ const getListedFunction = function ({
mainFile,
name,
runtime: runtime.name,
- runtimeAPIVersion: staticAnalysisResult ? staticAnalysisResult?.runtimeAPIVersion ?? 1 : undefined,
+ runtimeAPIVersion: staticAnalysisResult ? (staticAnalysisResult?.runtimeAPIVersion ?? 1) : undefined,
schedule: staticAnalysisResult?.config?.schedule ?? config.schedule,
inputModuleFormat: staticAnalysisResult?.inputModuleFormat,
}
diff --git a/packages/zip-it-and-ship-it/src/runtimes/index.ts b/packages/zip-it-and-ship-it/src/runtimes/index.ts
index 617a8f8329..c314d548eb 100644
--- a/packages/zip-it-and-ship-it/src/runtimes/index.ts
+++ b/packages/zip-it-and-ship-it/src/runtimes/index.ts
@@ -104,21 +104,27 @@ export const getFunctionsFromPaths = async (
// through `findFunctionsInRuntime`. For each iteration, we collect all the
// functions found plus the list of paths that still need to be evaluated,
// using them as the input for the next iteration until the last runtime.
- const { functions } = await RUNTIMES.reduce(async (aggregate, runtime) => {
- const { functions: aggregateFunctions, remainingPaths: aggregatePaths } = await aggregate
- const { functions: runtimeFunctions, remainingPaths: runtimePaths } = await findFunctionsInRuntime({
- cache,
- dedupe,
- featureFlags,
- paths: aggregatePaths,
- runtime,
- })
-
- return {
- functions: [...aggregateFunctions, ...runtimeFunctions],
- remainingPaths: runtimePaths,
- }
- }, Promise.resolve({ functions: [], remainingPaths: paths } as { functions: FunctionTupleWithoutConfig[]; remainingPaths: string[] }))
+ const { functions } = await RUNTIMES.reduce(
+ async (aggregate, runtime) => {
+ const { functions: aggregateFunctions, remainingPaths: aggregatePaths } = await aggregate
+ const { functions: runtimeFunctions, remainingPaths: runtimePaths } = await findFunctionsInRuntime({
+ cache,
+ dedupe,
+ featureFlags,
+ paths: aggregatePaths,
+ runtime,
+ })
+
+ return {
+ functions: [...aggregateFunctions, ...runtimeFunctions],
+ remainingPaths: runtimePaths,
+ }
+ },
+ Promise.resolve({ functions: [], remainingPaths: paths } as {
+ functions: FunctionTupleWithoutConfig[]
+ remainingPaths: string[]
+ }),
+ )
const functionConfigs = await Promise.all(
functions.map(([, func]) => getConfigForFunction({ config, configFileDirectories, func })),
)
diff --git a/packages/zip-it-and-ship-it/src/runtimes/node/parser/exports.ts b/packages/zip-it-and-ship-it/src/runtimes/node/parser/exports.ts
index caf2b7a253..79e320b52a 100644
--- a/packages/zip-it-and-ship-it/src/runtimes/node/parser/exports.ts
+++ b/packages/zip-it-and-ship-it/src/runtimes/node/parser/exports.ts
@@ -200,23 +200,26 @@ const parseConfigESMExport = (node: Statement) => {
* and any others will be ignored and excluded from the resulting object.
*/
const parseObject = (node: ObjectExpression) =>
- node.properties.reduce((acc, property): Record => {
- if (property.type === 'ObjectProperty' && property.key.type === 'Identifier') {
- return {
- ...acc,
- [property.key.name]: parsePrimitive(property.value),
+ node.properties.reduce(
+ (acc, property): Record => {
+ if (property.type === 'ObjectProperty' && property.key.type === 'Identifier') {
+ return {
+ ...acc,
+ [property.key.name]: parsePrimitive(property.value),
+ }
}
- }
- if (property.type === 'ObjectProperty' && property.key.type === 'StringLiteral') {
- return {
- ...acc,
- [property.key.value]: parsePrimitive(property.value),
+ if (property.type === 'ObjectProperty' && property.key.type === 'StringLiteral') {
+ return {
+ ...acc,
+ [property.key.value]: parsePrimitive(property.value),
+ }
}
- }
- return acc
- }, {} as Record)
+ return acc
+ },
+ {} as Record,
+ )
/**
* Takes an expression and, if it matches a JavaScript primitive type, returns