Skip to content
This repository was archived by the owner on Oct 20, 2024. It is now read-only.
This repository was archived by the owner on Oct 20, 2024. It is now read-only.

svelte-add not "smart" enough #312

@MrAmericanMike

Description

@MrAmericanMike

So I was following a guide on Skeleton website as to how to add their library to a Svelte Project.

In one of the steps they mention to add tailwind using npx svelte-add@latest tailwindcss

To my surprise svelte-add assumes project structure and placed a +layout.svelte in my src/routes folder with this contents:

<script>
  import "../app.postcss";
</script>

<slot />

However my svelte project isn't on src folder but on src/svelte as stated on the svelte.config.js file.

import { vitePreprocess } from "@sveltejs/kit/vite";
import adapter from "@sveltejs/adapter-static";

/** @type {import("@sveltejs/kit").Config} */
const config = {
	kit: {
		adapter: adapter({
			pages: "src/electron/songzilla",
			assets: "src/electron/songzilla",
			fallback: "index.html"
		}),
		files: {
			routes: "src/svelte/routes",
			assets: "src/svelte/static",
			appTemplate: "src/svelte/index.html"
		},
		prerender: { entries: [] }
	},
	preprocess: [vitePreprocess({})]
};

export default config;

Why doesn't svelte-add takes the routes from there?

Not sure if it's a "bug" if it was overlooked, or if it's a needed enhancement.

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions