fix broken svelte example#6
Conversation
|
@kenricqq is attempting to deploy a commit to the Vercel Labs Team on Vercel. A member of the Team first needs to authorize it. |
|
Hey @kenricqq - thanks for your contribution! Can you please sign your commit(s)? |
81b572b to
bfa9097
Compare
|
@ctate Commit signed! |
|
Hi, not sure if this is the right place to mention it, but I noticed the same pattern also exists in the project initializer template. Since this PR updates the Svelte example for Svelte 5 by switching from Specifically,
fn svelteMainJs() []const u8 {
return
\\import App from "./App.svelte";
\\import "./app.css";
\\
\\const app = new App({ target: document.getElementById("app") });
\\
\\export default app;
\\
;
}to fn svelteMainJs() []const u8 {
return
\\import { mount } from "svelte";
\\import App from "./App.svelte";
\\import "./app.css";
\\
\\const app = mount(App, { target: document.getElementById("app") });
\\
\\export default app;
\\
;
}Otherwise the checked-in example is fixed, but projects created through the initializer may still get the old Svelte 4-style bootstrap code. |
Summary
Fixes the Svelte example so it renders correctly.
Problem
Running
zig build runshowed a blank page despite a non-emptyApp.svelte.Changes
Before
After
Testing
zig build runsuccessfully