Skip to content

Latest commit

 

History

History
15 lines (11 loc) · 661 Bytes

File metadata and controls

15 lines (11 loc) · 661 Bytes
title entry-client.tsx

entry-client.tsx is where an application starts in the browser. It does this by passing <StartClient> and a DOM Element (the mounting point), to the mount function.

import { mount, StartClient } from "@solidjs/start/client";

mount(() => <StartClient />, document.getElementById("app")!);

This file is an ideal place to run any client specific code that is needed on startup, such as registering service workers. This is important if you are performing client-only rendering or using other modes of server-side rendering.