From d532df1222273f9ef900abafc7aa4308235bb2ff Mon Sep 17 00:00:00 2001 From: Ben Holmes Date: Mon, 5 Aug 2024 12:23:26 +0000 Subject: [PATCH] [ci] format --- packages/astro/src/actions/runtime/middleware.ts | 2 +- packages/astro/src/actions/runtime/virtual/shared.ts | 2 +- packages/astro/src/core/render-context.ts | 2 +- packages/astro/templates/actions.mjs | 2 +- packages/astro/test/actions.test.js | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/astro/src/actions/runtime/middleware.ts b/packages/astro/src/actions/runtime/middleware.ts index cec01b8dd7e8..2cc1b1e28a29 100644 --- a/packages/astro/src/actions/runtime/middleware.ts +++ b/packages/astro/src/actions/runtime/middleware.ts @@ -7,12 +7,12 @@ import { import { AstroError } from '../../core/errors/errors.js'; import { defineMiddleware } from '../../core/middleware/index.js'; import { formContentTypes, hasContentType } from './utils.js'; +import { getAction } from './virtual/get-action.js'; import { type SafeResult, type SerializedActionResult, serializeActionResult, } from './virtual/shared.js'; -import { getAction } from './virtual/get-action.js'; export type Locals = { _actionsInternal: { diff --git a/packages/astro/src/actions/runtime/virtual/shared.ts b/packages/astro/src/actions/runtime/virtual/shared.ts index 354b39478a03..e00a89c68495 100644 --- a/packages/astro/src/actions/runtime/virtual/shared.ts +++ b/packages/astro/src/actions/runtime/virtual/shared.ts @@ -1,6 +1,6 @@ +import { parse as devalueParse, stringify as devalueStringify } from 'devalue'; import type { z } from 'zod'; import type { ErrorInferenceObject, MaybePromise } from '../utils.js'; -import { stringify as devalueStringify, parse as devalueParse } from 'devalue'; export const ACTION_ERROR_CODES = [ 'BAD_REQUEST', diff --git a/packages/astro/src/core/render-context.ts b/packages/astro/src/core/render-context.ts index 259097705d49..4a824bfb099c 100644 --- a/packages/astro/src/core/render-context.ts +++ b/packages/astro/src/core/render-context.ts @@ -1,4 +1,3 @@ -import { deserializeActionResult } from '../actions/runtime/virtual/shared.js'; import type { APIContext, AstroGlobal, @@ -11,6 +10,7 @@ import type { SSRResult, } from '../@types/astro.js'; import type { ActionAPIContext } from '../actions/runtime/utils.js'; +import { deserializeActionResult } from '../actions/runtime/virtual/shared.js'; import { createCallAction, createGetActionResult, hasActionsInternal } from '../actions/utils.js'; import { computeCurrentLocale, diff --git a/packages/astro/templates/actions.mjs b/packages/astro/templates/actions.mjs index b5ac6dea405b..3c00fc9140c1 100644 --- a/packages/astro/templates/actions.mjs +++ b/packages/astro/templates/actions.mjs @@ -1,4 +1,4 @@ -import { ActionError, getActionQueryString, deserializeActionResult } from 'astro:actions'; +import { ActionError, deserializeActionResult, getActionQueryString } from 'astro:actions'; function toActionProxy(actionCallback = {}, aggregatedPath = '') { return new Proxy(actionCallback, { diff --git a/packages/astro/test/actions.test.js b/packages/astro/test/actions.test.js index 8e5919b3159e..aea929e1b8f3 100644 --- a/packages/astro/test/actions.test.js +++ b/packages/astro/test/actions.test.js @@ -1,9 +1,9 @@ import assert from 'node:assert/strict'; import { after, before, describe, it } from 'node:test'; import * as cheerio from 'cheerio'; +import * as devalue from 'devalue'; import testAdapter from './test-adapter.js'; import { loadFixture } from './test-utils.js'; -import * as devalue from 'devalue'; describe('Astro Actions', () => { let fixture;