- 
          
 - 
                Notifications
    
You must be signed in to change notification settings  - Fork 62
 
Closed
Labels
Description
- Use 
pnpx sv createto generate a Svelte project - Select the minimal template
 - Add lucia auth. While I don't think other addons will affect reproducing this, for full clarity I also added
- eslint
 - prettier
 - vitest
 - playwright
 - drizzle using postgres and Postgres.js
 - storybook
 - mcp (remote)
 
 - Say yes when prompted to add a demo for lucia
 - Install with 
pnpm - Finish the CLI prompts and open the project
 
At this stage, the following files should have a syntax error due to an incorrectly escaped closing </script> tag (see image).
- routes/demo/lucia/login/+page.svelte
 - routes/demo/lucia/+page.svelte
 
Looking at packages/addons/lucia/index.ts line 633, the string provided seems fine, so I can only assume there's an issue in dedent somewhere?:
return dedent`
	<script ${ts("lang='ts'")}>
		import { enhance } from '$app/forms';
		${ts("import type { PageServerData } from './$types';\n")}
		${s5(`let { data }${ts(': { data: PageServerData }')} = $props();`, `export let data${ts(': PageServerData')};`)}
	</script>     // The closing tag in question.
	<h1>Hi, {data.user.username}!</h1>
	<p>Your user ID is {data.user.id}.</p>
	<form method='post' action='?/logout' use:enhance>
		<button>Sign out</button>
	</form>
`;