app.tsx

app.tsx is the resolved app root module.


Import

app.tsx is loaded as the virtual app module.


Type

export default function App(): JSX.Element;

Parameters

The default app component takes no required arguments.


Return value

  • Type: JSX.Element

Returns the root app element.


Behavior

  • The config aliases #start/app to the app module under appRoot.
  • Default appRoot is "./src".
  • Entry files use .jsx when ${appRoot}/app.jsx exists; otherwise they use .tsx.

Examples

Basic usage

import { Router } from "@solidjs/router";
import { FileRoutes } from "@solidjs/start/router";
export default function App() {
return (
<Router>
<FileRoutes />
</Router>
);
}

Last updated: 5/6/26, 4:10 AMEdit this pageReport an issue with this page