0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-16 21:46:22 -05:00

Revert "[ci] format" (#10417)

* Revert "[ci] format"

This reverts commit 1863727215.

* pin dependency

* update lock
This commit is contained in:
Emanuele Stoppa 2024-03-13 09:55:24 +00:00 committed by GitHub
parent 8dceb5eb36
commit dfd146f591
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
128 changed files with 253 additions and 207 deletions

View file

@ -47,10 +47,10 @@
},
"packageManager": "pnpm@8.6.12",
"dependencies": {
"@biomejs/biome": "^1.5.3",
"astro-benchmark": "workspace:*"
},
"devDependencies": {
"@biomejs/biome": "1.5.3",
"@astrojs/check": "^0.5.8",
"@changesets/changelog-github": "^0.4.8",
"@changesets/cli": "^2.26.2",

View file

@ -1,5 +1,5 @@
---
import { type LocalImageProps, type RemoteImageProps, getImage } from 'astro:assets';
import { getImage, type LocalImageProps, type RemoteImageProps } from 'astro:assets';
import { AstroError, AstroErrorData } from '../dist/core/errors/index.js';
import type { HTMLAttributes } from '../types';

View file

@ -1,5 +1,5 @@
---
import { type LocalImageProps, type RemoteImageProps, getImage } from 'astro:assets';
import { getImage, type LocalImageProps, type RemoteImageProps } from 'astro:assets';
import type { GetImageResult, ImageOutputFormat } from '../dist/@types/astro';
import { isESMImportedImage } from '../dist/assets/utils/imageKind';
import { AstroError, AstroErrorData } from '../dist/core/errors/index.js';

View file

@ -1,7 +1,7 @@
---
import Hero from '../components/Hero.astro';
import LinkedLib from '@e2e/astro-linked-lib'
import HoistedScript from '@e2e/astro-linked-lib/HoistedScript'
import Hero from '../components/Hero.astro';
---
<html>

View file

@ -1,9 +1,9 @@
---
import { PreactCounter } from '../components/preact/PreactCounter.jsx';
import * as react from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.jsx';
import SolidCounter from '../components/solid/SolidCounter.jsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,6 +1,6 @@
---
import Deeper from './Deeper.astro';
import One from './One.jsx';
import Deeper from './Deeper.astro';
---

View file

@ -1,7 +1,7 @@
---
import ClientOnlyComponent from '../components/ClientOnlyComponent.js';
import MyCounter from '../components/Counter.js';
import NonDeferredCounter from '../components/NonDeferredCounter.js';
import ClientOnlyComponent from '../components/ClientOnlyComponent.js';
const someProps = {
count: 10,

View file

@ -1,13 +1,13 @@
---
// Component Imports
import { A, B as Renamed } from '../components';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import * as react from '../components/react/ReactCounter.jsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
// Style Imports
import '../styles/global.css';
// Component Imports
import { A, B as Renamed } from '../components';
import * as react from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,9 +1,9 @@
---
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import ReactCounter from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,9 +1,9 @@
---
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import ReactCounter from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,9 +1,9 @@
---
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import { Counter as ReactCounter } from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,9 +1,9 @@
---
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import { Counter as ReactCounter } from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,9 +1,9 @@
---
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import { Counter as ReactCounter } from '../components/react/ReactCounter.jsx';
import { PreactCounter } from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
// Full Astro Component Syntax:
// https://docs.astro.build/basics/astro-components/

View file

@ -1,9 +1,9 @@
---
import PreactCounter from '../components/preact/PreactCounter.tsx';
import ReactCounter from '../components/react/ReactCounter.jsx';
import PreactCounter from '../components/preact/PreactCounter.tsx';
import SolidCounter from '../components/solid/SolidCounter.tsx';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
import VueCounter from '../components/vue/VueCounter.vue';
import SvelteCounter from '../components/svelte/SvelteCounter.svelte';
---
<html lang="en">

View file

@ -1,6 +1,6 @@
---
import Component from '../components/React';
import type { BigNestedObject } from '../types';
import Component from '../components/React';
const object: BigNestedObject = {
nested: {

View file

@ -1,6 +1,6 @@
---
import WrapperA from "../components/WrapperA.jsx";
import WrapperB from "../components/WrapperB.jsx";
import WrapperA from "../components/WrapperA.jsx";
---
<html>

View file

@ -1,8 +1,8 @@
---
import Button from '../components/Button.astro';
import Complex from '../components/Complex.astro';
// Component Imports
import Layout from '../components/Layout.astro';
import Button from '../components/Button.astro';
import Complex from '../components/Complex.astro';
---
<Layout>

View file

@ -1,5 +1,5 @@
import { navigate } from "astro:transitions/client";
import React from 'react';
import { navigate } from "astro:transitions/client";
export default function ClickToNavigate({ to, id }) {
return <button id={id} onClick={() => navigate(to)}>Navigate to `{to}`</button>;
}

View file

@ -1,6 +1,6 @@
---
import { ViewTransitions } from "astro:transitions";
import ClickToNavigate from "../components/ClickToNavigate.jsx"
import { ViewTransitions } from "astro:transitions";
---
<html>
<head>

View file

@ -1,8 +1,8 @@
---
import Island from '../components/Island';
import Layout from '../components/Layout.astro';
import SvelteCounter from '../components/SvelteCounter.svelte';
import Island from '../components/Island';
import VueCounter from '../components/VueCounter.vue';
import SvelteCounter from '../components/SvelteCounter.svelte';
---
<Layout>
<p id="page-four">Page 4</p>

View file

@ -1,6 +1,6 @@
---
import Island from '../components/Island';
import Layout from '../components/Layout.astro';
import Island from '../components/Island';
---
<Layout>
<a id="click-two" href="/client-only-two">go to page 2</a>

View file

@ -1,8 +1,8 @@
---
import Island from '../components/Island';
import Layout from '../components/Layout.astro';
import SvelteCounter from '../components/SvelteCounter.svelte';
import Island from '../components/Island';
import VueCounter from '../components/VueCounter.vue';
import SvelteCounter from '../components/SvelteCounter.svelte';
---
<Layout>
<a id="click-four" href="/client-only-four">go to page 4</a>

View file

@ -1,6 +1,6 @@
---
import Island from '../components/Island';
import Layout from '../components/Layout.astro';
import Island from '../components/Island';
---
<Layout>
<p id="page-two">Page 2</p>

View file

@ -1,6 +1,6 @@
---
import InlineScript from '../components/InlineScript.astro';
import Layout from '../components/Layout.astro';
import InlineScript from '../components/InlineScript.astro';
---
<Layout>
<InlineScript />

View file

@ -1,6 +1,6 @@
---
import InlineScript from '../components/InlineScript.astro';
import Layout from '../components/Layout.astro';
import InlineScript from '../components/InlineScript.astro';
---
<Layout>
<InlineScript />

View file

@ -1,6 +1,6 @@
---
import Island from '../components/Island.jsx';
import Layout from '../components/Layout.astro';
import Island from '../components/Island.jsx';
export const prerender = false;
const persistProps = Astro.url.searchParams.has('persist');

View file

@ -1,6 +1,6 @@
---
import Island from '../components/Island.jsx';
import Layout from '../components/Layout.astro';
import Island from '../components/Island.jsx';
---
<Layout>
<p id="island-two">Page 2</p>

View file

@ -1,8 +1,8 @@
---
import Counter from '../components/Counter.vue';
import State from '../components/State.vue'
import AsyncTest from '../components/Test.vue'
import VueComponent from '../components/VueComponent.vue';
import AsyncTest from '../components/Test.vue'
import State from '../components/State.vue'
const someProps = {
count: 0,

View file

@ -1,4 +1,4 @@
import { test as base, expect } from '@playwright/test';
import { expect, test as base } from '@playwright/test';
import { loadFixture, waitForHydrate } from './test-utils.js';
const test = base.extend({

View file

@ -1,6 +1,6 @@
---
import { Heading, Aside, LikeButton, HydratedLikeButton } from '@performance/utils';
import type { CollectionEntry } from 'astro:content';
import { Aside, Heading, HydratedLikeButton, LikeButton } from '@performance/utils';
type Props = {
entry: CollectionEntry<'generated'>;

View file

@ -1,6 +1,6 @@
---
import type { CollectionEntry } from 'astro:content';
import Title from './Title.astro';
import type { CollectionEntry } from 'astro:content';
type Props = {
entry: CollectionEntry<'generated'>;

View file

@ -1,11 +1,11 @@
// @ts-expect-error
import { imageConfig } from 'astro:assets';
import { isRemotePath } from '@astrojs/internal-helpers/path';
import mime from 'mime/lite.js';
import type { APIRoute } from '../../@types/astro.js';
import { getConfiguredImageService } from '../internal.js';
import { etag } from '../utils/etag.js';
import { isRemoteAllowed } from '../utils/remotePattern.js';
// @ts-expect-error
import { imageConfig } from 'astro:assets';
async function loadRemoteImage(src: URL) {
try {

View file

@ -2,8 +2,6 @@
import os from 'node:os';
import { isAbsolute } from 'node:path';
import { fileURLToPath, pathToFileURL } from 'node:url';
// @ts-expect-error
import { assetsDir, imageConfig, outDir } from 'astro:assets';
import { isRemotePath, removeQueryString } from '@astrojs/internal-helpers/path';
import { readFile } from 'fs/promises';
import mime from 'mime/lite.js';
@ -11,6 +9,8 @@ import type { APIRoute } from '../../@types/astro.js';
import { getConfiguredImageService } from '../internal.js';
import { etag } from '../utils/etag.js';
import { isRemoteAllowed } from '../utils/remotePattern.js';
// @ts-expect-error
import { assetsDir, imageConfig, outDir } from 'astro:assets';
function replaceFileSystemReferences(src: string) {
return os.platform().includes('win32') ? src.replace(/^\/@fs\//, '') : src.replace(/^\/@fs/, '');

View file

@ -1,4 +1,4 @@
import type { Rollup, Plugin as VitePlugin } from 'vite';
import type { Plugin as VitePlugin, Rollup } from 'vite';
import type { BuildInternals } from './internal.js';
import type { StaticBuildOptions, ViteBuildReturn } from './types.js';

View file

@ -1,5 +1,5 @@
import type { GetModuleInfo } from 'rollup';
import type { BuildOptions, ResolvedConfig, Rollup, Plugin as VitePlugin } from 'vite';
import type { BuildOptions, Plugin as VitePlugin, ResolvedConfig, Rollup } from 'vite';
import { isBuildableCSSRequest } from '../../../vite-plugin-astro-server/util.js';
import type { BuildInternals } from '../internal.js';
import type { AstroBuildPlugin, BuildTarget } from '../plugin.js';

View file

@ -1,5 +1,5 @@
import { extname } from 'node:path';
import type { BuildOptions, Rollup, Plugin as VitePlugin } from 'vite';
import type { BuildOptions, Plugin as VitePlugin, Rollup } from 'vite';
// eslint-disable-next-line @typescript-eslint/ban-types
type OutputOptionsHook = Extract<VitePlugin['outputOptions'], Function>;

View file

@ -1,8 +1,8 @@
import type {
ShikiConfig,
RehypePlugin as _RehypePlugin,
RemarkPlugin as _RemarkPlugin,
RemarkRehype as _RemarkRehype,
ShikiConfig,
} from '@astrojs/markdown-remark';
import { markdownConfigDefaults } from '@astrojs/markdown-remark';
import { type BuiltinTheme, bundledThemes } from 'shiki';

View file

@ -1,6 +1,6 @@
import { fileURLToPath } from 'url';
import stripAnsi from 'strip-ansi';
import type { LogLevel, Rollup, Logger as ViteLogger } from 'vite';
import type { LogLevel, Logger as ViteLogger, Rollup } from 'vite';
import { isAstroError } from '../errors/errors.js';
import { serverShortcuts as formatServerShortcuts } from '../messages.js';
import { type Logger as AstroLogger, isLogLevelEnabled } from './core.js';

View file

@ -1,8 +1,8 @@
// @ts-expect-error
import { loadDevToolbarApps } from 'astro:dev-toolbar';
import type { DevToolbarApp as DevToolbarAppDefinition } from '../../../@types/astro.js';
import { settings } from './settings.js';
import type { AstroDevToolbar, DevToolbarApp } from './toolbar.js';
// @ts-expect-error
import { loadDevToolbarApps } from 'astro:dev-toolbar';
let overlay: AstroDevToolbar;

View file

@ -716,8 +716,8 @@ async function prepareForClientOnlyComponents(newDocument: Document, toLocation:
// return a promise that resolves when all astro-islands are hydrated
async function hydrationDone(loadingPage: HTMLIFrameElement) {
await new Promise((r) =>
loadingPage.contentWindow?.addEventListener('load', r, { once: true })
await new Promise(
(r) => loadingPage.contentWindow?.addEventListener('load', r, { once: true })
);
return new Promise<void>(async (r) => {

View file

@ -3,9 +3,9 @@ import type * as vite from 'vite';
import type { AstroConfig, AstroSettings } from '../@types/astro.js';
import type { Logger } from '../core/logger/core.js';
import type {
CompileMetadata,
PluginCssMetadata as AstroPluginCssMetadata,
PluginMetadata as AstroPluginMetadata,
CompileMetadata,
} from './types.js';
import { normalizePath } from 'vite';

View file

@ -1,6 +1,6 @@
import path from 'node:path';
import type { CompilerOptions } from 'typescript';
import { type ResolvedConfig, type Plugin as VitePlugin, normalizePath } from 'vite';
import { type Plugin as VitePlugin, type ResolvedConfig, normalizePath } from 'vite';
import type { AstroSettings } from '../@types/astro.js';
type Alias = {

View file

@ -5,16 +5,13 @@ import AstroComponent from '../components/Astro.astro';
import AstroComponentNone from '../components/AstroNone.astro';
import AstroSass from '../components/AstroSass.astro';
import AstroScss from '../components/AstroScss.astro';
import ModuleOrdering from '../components/ModuleOrdering.jsx';
import ReactCSS from '../components/ReactCSS.jsx';
import ReactDynamic from '../components/ReactDynamic.jsx';
import ReactModules from '../components/ReactModules.jsx';
import ReactModulesSass from '../components/ReactModulesSass.jsx';
import ReactModulesScss from '../components/ReactModulesScss.jsx';
import ReactSass from '../components/ReactSass.jsx';
import ReactScss from '../components/ReactScss.jsx';
import SvelteCSS from '../components/SvelteCSS.svelte';
import SvelteDynamic from '../components/SvelteDynamic.svelte';
import SvelteSass from '../components/SvelteSass.svelte';
import SvelteScss from '../components/SvelteScss.svelte';
import VueCSS from '../components/VueCSS.vue';
@ -22,6 +19,9 @@ import VueModules from '../components/VueModules.vue';
import VueSass from '../components/VueSass.vue';
import VueScoped from '../components/VueScoped.vue';
import VueScss from '../components/VueScss.vue';
import ReactDynamic from '../components/ReactDynamic.jsx';
import SvelteDynamic from '../components/SvelteDynamic.svelte';
import ModuleOrdering from '../components/ModuleOrdering.jsx';
import '../styles/imported-url.css';
import '../styles/imported.sass';

View file

@ -1,10 +1,10 @@
---
import Alias from 'components/Alias.svelte';
import Client from 'components/Client.svelte'
import Foo from 'components/Foo.astro';
import StyleComp from 'components/Style.astro';
import 'styles/main.css';
import Alias from 'components/Alias.svelte';
import { foo, index } from 'utils/constants';
import 'styles/main.css';
---
<html lang="en">
<head>

View file

@ -1,11 +1,11 @@
---
import Alias from '@components/Alias.svelte';
import Client from '@components/Client.svelte'
import '@styles/main.css';
import { namespace } from '@test/namespace-package'
import Foo from 'src/components/Foo.astro';
import StyleComp from 'src/components/Style.astro';
import Alias from '@components/Alias.svelte';
import { namespace } from '@test/namespace-package'
import { foo, index } from 'src/utils/constants';
import '@styles/main.css';
const globResult = Object.keys(import.meta.glob('@components/glob/*.js')).join(', ')
---

View file

@ -1,5 +1,5 @@
---
console.log(doesntExist)
console.log(doesntExist)
---
<html lang="en">

View file

@ -1,7 +1,7 @@
---
import PreactComponent from '../components/Component.jsx';
import SvelteComponent from '../components/Component.svelte';
import VueComponent from '../components/Component.vue';
import SvelteComponent from '../components/Component.svelte';
---
<html>
<head><title>Children</title></head>

View file

@ -1,7 +1,7 @@
---
import PreactComponent from '../components/Component.jsx';
import SvelteComponent from '../components/Component.svelte';
import VueComponent from '../components/Component.vue';
import SvelteComponent from '../components/Component.svelte';
---
<html>
<head><title>Children</title></head>

View file

@ -1,7 +1,7 @@
---
import PreactComponent from '../components/Component.jsx';
import SvelteComponent from '../components/Component.svelte';
import VueComponent from '../components/Component.vue';
import SvelteComponent from '../components/Component.svelte';
---
<html>
<head><title>Children</title></head>

View file

@ -1,6 +1,6 @@
---
import ReactComponent from '../components/JSXComponent.jsx';
import PersistentCounter from '../components/PersistentCounter.svelte';
import ReactComponent from '../components/JSXComponent.jsx';
---
<html>
<head><title>Client only pages</title></head>

View file

@ -1,6 +1,6 @@
---
import PreactCounter from '../components/PreactCounter.tsx';
import ReactCounter from '../components/ReactCounter.jsx';
import PreactCounter from '../components/PreactCounter.tsx';
import SolidCounter from '../components/SolidCounter.jsx';
---

View file

@ -1,6 +1,6 @@
---
import Component from '../components/Component.jsx';
import Head from '../components/Head.astro';
import Component from '../components/Component.jsx';
---
<html>

View file

@ -1,6 +1,6 @@
---
import Component from '../components/Component.jsx';
import Layout from '../components/Layout.astro';
import Component from '../components/Component.jsx';
// note: this test requires <Layout> to be the very first element
---

View file

@ -1,6 +1,6 @@
---
import Inner from '../components/react/Inner'
import Parent from '../components/react/Parent'
import Inner from '../components/react/Inner'
---
<html lang="en">

View file

@ -1,9 +1,9 @@
---
import PassesChildren from '../components/react/PassesChildren.jsx';
import PassesChildrenP from '../components/preact/PassesChildrenP.jsx';
import PassesChildrenS from '../components/solid/PassesChildrenS.jsx';
import PassesChildrenSv from '../components/PassesChildrenSv.svelte';
import PassesChildrenV from '../components/PassesChildrenV.vue';
import PassesChildrenP from '../components/preact/PassesChildrenP.jsx';
import PassesChildren from '../components/react/PassesChildren.jsx';
import PassesChildrenS from '../components/solid/PassesChildrenS.jsx';
---
<html lang="en">

View file

@ -1,7 +1,7 @@
---
import Render from '../components/Render.astro';
import RenderArgs from '../components/RenderArgs.astro';
import RenderFn from '../components/RenderFn.astro';
import RenderArgs from '../components/RenderArgs.astro';
---
<html>

View file

@ -1,6 +1,6 @@
---
import { Image } from 'astro:assets';
import { getEntries, getEntry } from 'astro:content';
import { getEntry, getEntries } from 'astro:content';
const welcomePost = await getEntry('blog', 'welcome');

View file

@ -1,6 +1,6 @@
import { getCollection } from 'astro:content';
import * as devalue from 'devalue';
import { stripAllRenderFn } from '../utils.js';
import { getCollection } from 'astro:content';
export async function GET() {
const withoutConfig = stripAllRenderFn(await getCollection('without-config'));

View file

@ -1,6 +1,6 @@
import { getEntryBySlug } from 'astro:content';
import * as devalue from 'devalue';
import { stripRenderFn } from '../utils.js';
import { getEntryBySlug } from 'astro:content';
export async function GET() {
const columbiaWithoutConfig = stripRenderFn(await getEntryBySlug('without-config', 'columbia'));

View file

@ -1,6 +1,6 @@
---
import { getCollection } from "astro:content";
import type { GetStaticPaths } from "astro";
import { getCollection } from "astro:content";
export const getStaticPaths = (async () => {
const blog = await getCollection("blog");

View file

@ -1,5 +1,5 @@
---
import { Image, getImage} from 'astro:assets';
import { getImage,Image } from 'astro:assets';
import { getCollection } from 'astro:content';
export async function getStaticPaths() {

View file

@ -1,6 +1,6 @@
---
import inline from '../inline.css?inline';
import Layout from '../layouts/Layout.astro';
import inline from '../inline.css?inline';
import raw from '../raw.css?raw';
---
<Layout title="Welcome to Astro.">

View file

@ -1,6 +1,6 @@
---
import { getEntryBySlug } from 'astro:content';
import Button from '../components/Button.astro';
import { getEntryBySlug } from 'astro:content';
const entry = await getEntryBySlug('en', 'endeavour');
const { Content } = await entry.render();

View file

@ -1,7 +1,7 @@
---
import Client2 from '../components/Client2.jsx';
import One from '../components/One.astro';
import Two from '../components/Two.astro';
import Client2 from '../components/Client2.jsx';
---
<html>
<head>

View file

@ -1,6 +1,6 @@
---
import Dedupe from '../components/Dedupe.jsx';
import '../styles/AstroJsx.css';
import Dedupe from '../components/Dedupe.jsx';
---
<html>
<head>

View file

@ -1,6 +1,6 @@
---
import Client1 from '../components/Client1.jsx';
import '../styles/base.css';
import Client1 from '../components/Client1.jsx';
---
<html>
<head>

View file

@ -1,6 +1,6 @@
---
import BlueButton from "../components/BlueButton.astro";
import MainHead from "../components/MainHead.astro";
import BlueButton from "../components/BlueButton.astro";
---
<html lang="en">

View file

@ -1,6 +1,6 @@
---
import BlueButton from "../components/BlueButton.astro";
import MainHead from "../components/MainHead.astro";
import BlueButton from "../components/BlueButton.astro";
---
<html lang="en">

View file

@ -1,6 +1,6 @@
---
import AlreadyImported from '../components/AlreadyImported.astro';
import Test from '../components/AstroComponent.astro';
import AlreadyImported from '../components/AlreadyImported.astro';
import CustomDeclaration from '../components/CustomDeclaration.astro';
import JsxComponent from '../components/JsxComponent.jsx';
import SvelteComponent from '../components/SvelteComponent.svelte';

View file

@ -1,6 +1,6 @@
---
import "@fontsource/monofett";
import "@fontsource/montserrat";
import "@fontsource/monofett";
---
<html lang="en">
<head>

View file

@ -1,6 +1,6 @@
---
import RegularSlot from "../components/RegularSlot.astro"
import Layout from "../components/SlotRenderLayout.astro";
import RegularSlot from "../components/RegularSlot.astro"
---
<Layout>
<RegularSlot>

View file

@ -1,6 +1,6 @@
---
import Component from "../components/SlotRenderComponent.astro"
import Layout from "../components/SlotRenderLayout.astro";
import Component from "../components/SlotRenderComponent.astro"
---
<Layout>
<Component>

View file

@ -1,7 +1,7 @@
---
import Default from '../components/Default.html';
import Inline from '../components/Inline.html';
import Named from '../components/Named.html';
import Inline from '../components/Inline.html';
---
<Default>Default</Default>

View file

@ -1,6 +1,6 @@
---
import Deeper from './Deeper.astro';
import One from './One.jsx';
import Deeper from './Deeper.astro';
---
<div>

View file

@ -1,6 +1,6 @@
---
import One from '../components/One.jsx';
import Wrapper from '../components/Wrapper.astro';
import One from '../components/One.jsx';
---
<html>
<head>

View file

@ -1,5 +1,5 @@
---
import { getAbsoluteLocaleUrl, getLocaleByPath, getPathByLocale, getRelativeLocaleUrl } from "astro:i18n";
import { getRelativeLocaleUrl, getAbsoluteLocaleUrl, getPathByLocale, getLocaleByPath } from "astro:i18n";
let absoluteLocaleUrl_pt = getAbsoluteLocaleUrl("pt", "about");
let absoluteLocaleUrl_it = getAbsoluteLocaleUrl("it");

View file

@ -1,5 +1,5 @@
---
import { getAbsoluteLocaleUrl, getLocaleByPath, getPathByLocale, getRelativeLocaleUrl } from "astro:i18n";
import { getRelativeLocaleUrl, getAbsoluteLocaleUrl, getPathByLocale, getLocaleByPath } from "astro:i18n";
let about = getRelativeLocaleUrl("pt", "about");
let spanish = getRelativeLocaleUrl("es", "about");

View file

@ -1,10 +1,10 @@
---
import FrameworkMDX from '../components/Content.mdx'
import FrameworkSvelte from '../components/SvelteCounter.svelte'
import FrameworkVue from '../components/VueCounter.vue'
import FrameworkSolid from '../components/solid/SolidCounter.jsx'
import FrameworkPreact from '../components/preact/PreactCounter.jsx'
import FrameworkReact from '../components/react/ReactCounter.jsx'
import FrameworkSolid from '../components/solid/SolidCounter.jsx'
import FrameworkSvelte from '../components/SvelteCounter.svelte'
import FrameworkVue from '../components/VueCounter.vue'
import FrameworkMDX from '../components/Content.mdx'
---
<div id="preact-wrapper">

View file

@ -1,5 +1,5 @@
---
function Component() {
function Component() {
return `<div id="component">works</div>`;
}
---

View file

@ -1,6 +1,6 @@
---
import ArrowFunctionComponent from '../components/ArrowFunction.jsx';
import FunctionComponent from '../components/Function.jsx';
import ArrowFunctionComponent from '../components/ArrowFunction.jsx';
---
<html>

View file

@ -1,6 +1,6 @@
---
import { signal } from '@preact/signals';
import Signals from '../components/Signals';
import { signal } from '@preact/signals';
const count = signal(1);
---
<html>

View file

@ -1,6 +1,6 @@
---
import {ConstDeclarationExport, FunctionDeclarationExport,LetDeclarationExport } from '../components/DeclarationExportTest'
import ListAsDefaultExport, {ListExport, RenamedListExport, ListExportTestComponent} from '../components/ListExportTest'
import {ConstDeclarationExport, LetDeclarationExport, FunctionDeclarationExport} from '../components/DeclarationExportTest'
import AnonymousArrowDefaultExport from '../components/defaultExport/AnonymousArrowDefaultExport'
import AnonymousFunctionDefaultExport from '../components/defaultExport/AnonymousFunctionDefaultExport'
import HocDefaultExport from '../components/defaultExport/HocDefaultExport'

View file

@ -1,5 +1,5 @@
---
export async function getStaticPaths() {
export async function getStaticPaths() {
return [
{ params: { lang: 'de', catchall: '1/2' } },
{ params: { lang: 'en', catchall: '1/2' } }

View file

@ -1,5 +1,5 @@
---
export async function getStaticPaths() {
export async function getStaticPaths() {
return [
{ params: { lang: 'de' } }, // always shadowed by /de/index.astro
{ params: { lang: 'en' } }

View file

@ -1,5 +1,5 @@
---
export async function getStaticPaths() {
export async function getStaticPaths() {
return [
{
params: { page: "page-1" }

View file

@ -1,5 +1,5 @@
---
export async function getStaticPaths() {
export async function getStaticPaths() {
return [
{
params: { slug: "slug-1" },

View file

@ -1,5 +1,5 @@
---
export async function getStaticPaths() {
export async function getStaticPaths() {
return [
{
params: { slug: "1/2" },

View file

@ -1,5 +1,5 @@
---
export async function getStaticPaths() {
export async function getStaticPaths() {
return [
{ params: { pid: 'post-1' } },
{ params: { pid: 'post-2' } }

View file

@ -1,9 +1,9 @@
---
import { Router } from "@solidjs/router";
import { Counter as DepCounter } from '@test/solid-jsx-component';
import Hello from '../components/Hello.jsx';
import ProxyComponent from '../components/ProxyComponent.jsx';
import WithNewlines from '../components/WithNewlines.jsx';
import { Router } from "@solidjs/router";
import ProxyComponent from '../components/ProxyComponent.jsx';
import { Counter as DepCounter } from '@test/solid-jsx-component';
---
<html>
<head><title>Solid</title></head>

View file

@ -1,6 +1,6 @@
---
import { LazyCounter } from '../components/LazyCounter.jsx';
import { AsyncComponent } from '../components/async-components.jsx';
import { LazyCounter } from '../components/LazyCounter.jsx';
---
<html>

View file

@ -1,11 +1,11 @@
---
import CaretCounter from '../components/^--with-carets/Counter';
import RocketCounter from '../components/and-rockets-🚀/Counter';
import RoundBracketCounter from '../components/with-(round-brackets)/Counter';
import SquareBracketCounter from '../components/with-[square-brackets]/Counter';
// Not supported in Vite
// import PercentCounter from '../components/now-100%-better/Counter';
import SpaceCounter from '../components/with some spaces/Counter';
import RoundBracketCounter from '../components/with-(round-brackets)/Counter';
import SquareBracketCounter from '../components/with-[square-brackets]/Counter';
---
<html>
<head>

View file

@ -1,6 +1,6 @@
---
import ExternalHoisted from '../components/ExternalHoisted.astro';
import InlineHoisted from '../components/InlineHoisted.astro';
import ExternalHoisted from '../components/ExternalHoisted.astro';
---
<html>

View file

@ -1,7 +1,7 @@
---
import { test as ssrConfigTest } from '@test/static-build-pkg';
import MainHead from '../components/MainHead.astro';
import Nav from '../components/Nav/index.jsx';
import { test as ssrConfigTest } from '@test/static-build-pkg';
let allPosts = await Astro.glob('./posts/*.md');
// Note that this just tests a warning

View file

@ -1,6 +1,6 @@
---
import AsyncEach from '../components/AsyncEach.astro';
import Header from '../components/Header.astro';
import AsyncEach from '../components/AsyncEach.astro';
import { wait } from '../wait';
async function * list() {

View file

@ -1,6 +1,6 @@
import { exec } from 'node:child_process';
/* eslint no-console: 'off' */
import { color, say as houston, label, spinner as load } from '@astrojs/cli-kit';
import { color, label, say as houston, spinner as load } from '@astrojs/cli-kit';
import { align, sleep } from '@astrojs/cli-kit/utils';
import stripAnsi from 'strip-ansi';
import { shell } from './shell.js';

View file

@ -1,5 +1,5 @@
import { column, defineDb, defineTable } from 'astro:db';
import { Themes } from './theme';
import { column, defineDb, defineTable } from 'astro:db';
const Author = defineTable({
columns: {

View file

@ -1,6 +1,6 @@
import { Author, db } from 'astro:db';
import { asDrizzleTable } from '@astrojs/db/utils';
import { Themes as ThemesConfig } from './theme';
import { Author, db } from 'astro:db';
const Themes = asDrizzleTable('Themes', ThemesConfig);
export default async function () {

View file

@ -1,6 +1,6 @@
---
/// <reference path="../../.astro/db-types.d.ts" />
import { Author, Themes, db } from 'astro:db';
import { Author, db, Themes } from 'astro:db';
const authors = await db.select().from(Author);
const themes = await db.select().from(Themes);

View file

@ -1,5 +1,5 @@
import { defineDb } from 'astro:db';
import { menu } from './shared';
import { defineDb } from 'astro:db';
export default defineDb({
tables: {

View file

@ -1,6 +1,6 @@
import { db } from 'astro:db';
import { asDrizzleTable } from '@astrojs/db/utils';
import { menu } from './shared';
import { db } from 'astro:db';
export default async function () {
const table = asDrizzleTable('menu', menu);

Some files were not shown because too many files have changed in this diff Show more