@netlify/build 27.17.1 → 27.17.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@netlify/build",
3
- "version": "27.17.1",
3
+ "version": "27.17.2",
4
4
  "description": "Netlify build module",
5
5
  "type": "module",
6
6
  "exports": "./src/core/main.js",
@@ -59,11 +59,11 @@
59
59
  "@netlify/edge-bundler": "^1.14.1",
60
60
  "@netlify/cache-utils": "^4.0.0",
61
61
  "@netlify/config": "^18.2.3",
62
- "@netlify/functions-utils": "^4.2.7",
62
+ "@netlify/functions-utils": "^4.2.8",
63
63
  "@netlify/git-utils": "^4.0.0",
64
- "@netlify/plugins-list": "^6.41.0",
64
+ "@netlify/plugins-list": "^6.42.0",
65
65
  "@netlify/run-utils": "^4.0.0",
66
- "@netlify/zip-it-and-ship-it": "^7.1.0",
66
+ "@netlify/zip-it-and-ship-it": "^7.1.1",
67
67
  "@sindresorhus/slugify": "^2.0.0",
68
68
  "@types/node": "^16.0.0",
69
69
  "ajv": "^8.11.0",
@@ -10,7 +10,7 @@ export const logRuntime = (logs, pluginOptions) => {
10
10
  const runtimes = pluginOptions.filter(isRuntime)
11
11
 
12
12
  // Once we have more runtimes, this hardcoded check should be removed
13
- if (runtimes.length > 1) {
13
+ if (runtimes.length !== 0) {
14
14
  const [nextRuntime] = runtimes
15
15
 
16
16
  logSubHeader(logs, `Using Next.js Runtime - v${nextRuntime.pluginPackageJson.version}`)
@@ -1,4 +1,5 @@
1
- export const isRuntime = function (packageName) {
1
+ export const isRuntime = function (pluginOption) {
2
+ const { packageName } = pluginOption
2
3
  // Make this a bit more robust in the future
3
4
  return ['@netlify/next-runtime', '@netlify/plugin-nextjs'].includes(packageName)
4
5
  }
@@ -22,9 +22,9 @@ interface Header {
22
22
  values: Partial<Record<string, Many<string, 'mutable'>>>
23
23
  }
24
24
 
25
- interface EdgeHandler {
25
+ interface EdgeFunction {
26
26
  path?: `/${string}`
27
- handler: string
27
+ function: string
28
28
  }
29
29
 
30
30
  interface NetlifyPlugin {
@@ -44,9 +44,9 @@ interface NetlifyConfig {
44
44
  */
45
45
  headers: Header[]
46
46
  /**
47
- * array of Edge Handlers with their modifiable options
47
+ * array of Edge Functions with their modifiable options
48
48
  */
49
- edge_handlers: EdgeHandler[]
49
+ edge_functions: EdgeFunction[]
50
50
  /**
51
51
  * object with options for modifying [functions](https://docs.netlify.com/configure-builds/file-based-configuration/#functions)
52
52
  */
@@ -14,10 +14,10 @@ export interface NetlifyPluginConstants {
14
14
  */
15
15
  FUNCTIONS_SRC?: string
16
16
  /**
17
- * the directory where internal Edge Handlers source code lives. This is where build plugins should place auto-generated handlers.
18
- * `undefined` if the version of @netlify/build does not support internal Edge Handlers
17
+ * the directory where internal Edge Functions source code lives. This is where build plugins should place auto-generated functions.
18
+ * `undefined` if the version of @netlify/build does not support internal Edge Functions
19
19
  */
20
- INTERNAL_EDGE_HANDLERS_SRC?: string
20
+ INTERNAL_EDGE_FUNCTIONS_SRC?: string
21
21
  /**
22
22
  * the directory where internal function source code lives. This is where build plugins should place auto-generated functions.
23
23
  * `undefined` if the version of @netlify/build does not support internal functions
@@ -28,14 +28,14 @@ export interface NetlifyPluginConstants {
28
28
  */
29
29
  FUNCTIONS_DIST: string
30
30
  /**
31
- * the directory where built Edge Handlers are placed before deployment. Its value is always defined, but the target might not have been created yet.
31
+ * the directory where built Edge Functions are placed before deployment. Its value is always defined, but the target might not have been created yet.
32
32
  */
33
- EDGE_HANDLERS_DIST: string
33
+ EDGE_FUNCTIONS_DIST: string
34
34
  /**
35
- * the directory where Edge Handlers source code lives.
36
- * `undefined` if no `netlify/edge-handlers` directory exists in the base directory and if not specified in `netlify.toml`.
35
+ * the directory where Edge Functions source code lives.
36
+ * `undefined` if no `netlify/edge-functions` directory exists.
37
37
  */
38
- EDGE_HANDLERS_SRC?: string
38
+ EDGE_FUNCTIONS_SRC?: string
39
39
  /**
40
40
  * boolean indicating whether the build was [run locally](https://docs.netlify.com/cli/get-started/#run-builds-locally) or on Netlify
41
41
  */