user1272597
user1272597

Reputation: 1335

Changing <html lang> in SvelteKit

how can I change the

 <html lang="en">

to

 <html lang="de">

with svelteKit? I build static pages:

 export default {
 kit: {
  adapter: adapter({
  // default options are shown
  pages: 'build',
  assets: 'build',
  fallback: '404.html',
  precompress: false
}),

prerender: {
  // This can be false if you're using a fallback (i.e. SPA mode)
  default: true
}
}
};

thanks for help

Upvotes: 1

Views: 1216

Answers (1)

Geoff Rich
Geoff Rich

Reputation: 5482

If it's static for the whole project, you can edit it in your app.html file.

<!DOCTYPE html>
<html lang="de">
    <head>
        <meta charset="utf-8" />
        <link rel="icon" href="%sveltekit.assets%/favicon.png" />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
        %sveltekit.head%
    </head>
    <body>
        <div>%sveltekit.body%</div>
    </body>
</html>

Upvotes: 7

Related Questions