Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not watch for imported scripts and styles #96

Closed
JakubKoralewski opened this issue Dec 21, 2019 · 3 comments
Closed

Does not watch for imported scripts and styles #96

JakubKoralewski opened this issue Dec 21, 2019 · 3 comments
Labels

Comments

@JakubKoralewski
Copy link

🐛 Bug Report

Does not update when I change the the script.ts or style.scss files. Updates them if I also unnecessarily import those files inside the index.html file.

🎛 Configuration (.svelterc, package.json, cli command)

Windows WSL
cli: rm -rf dist && parcel src/index.html

\\ index.ts
import Svelte from './index.svelte';
new Svelte({
	target: document.body
});
<!-- index.html -->
<html lang="en">
	<head>
		<title>Go go go! Go A no go B!</title>
		<link rel="stylesheet" href="style.scss">
	</head>
	<body>

	<script src="index.ts"></script>
	</body>
</html>
// index.svelte
<style lang="scss" global>
	@import './style.scss';
</style>

<script lang="ts" src="script.ts">
</script>

package.json:

    "parcel-bundler": "^1.12.4",
    "parcel-plugin-svelte": "^4.0.5",
    "postcss-modules": "^1.4.1",
    "svelte": "^3.16.5",
    "svelte-preprocess": "^3.3.0"
@DeMoorJasper
Copy link
Owner

DeMoorJasper commented Dec 22, 2019

This is strange, I'll look into this when I find the time. Maybe tomorrow.

Contents should pass the html processor of parcel and get watched so in theory it should work... and it's the first time this error got reported so I guess it's an edge case or something idk seems strange that nobody else had this in about 2 years. Maybe it's related to a relatively recent commit and the new svelte version?

@JakubKoralewski
Copy link
Author

I'll try to create a minimal repo when I have the time if you can't reproduce 🤞

@JakubKoralewski
Copy link
Author

@DeMoorJasper while initially getting Svelte and Parcel to work I bumped into #44, then followed #44 (comment) these instructions and forgot about it. Rebumped into it when creating the example repo.

Seems like a duplicate :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants