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

repl: multiple dots in filename not supported when reloading a saved project in REPL #4441

Merged
merged 1 commit into from
Feb 23, 2020
Merged

repl: multiple dots in filename not supported when reloading a saved project in REPL #4441

merged 1 commit into from
Feb 23, 2020

Conversation

AlexandreCantin
Copy link
Contributor

When reloading a saved project in the REPL with a file containing multiple dots (like example.store.js), the file will be reload with an uncomplete name (=> example.store) and imports will break.

Example REPL generating this error : https://svelte.dev/repl/e16ae6e77ec94412b296dc7af897ac85?version=3.18.2

This error can be fix by using the last dot in filename for splitting (lastIndexOf('.')) instead of let [name, type] = file.name.split('.'); 😊

…project

In REPL, if you reload a saved project with a file containing multiple dots (example.store.js), the file will be reload as 'example.store' and imports will break.
@Conduitry Conduitry merged commit 9a747e3 into sveltejs:master Feb 23, 2020
jesseskinner pushed a commit to jesseskinner/svelte that referenced this pull request Feb 27, 2020
taylorzane pushed a commit to taylorzane/svelte that referenced this pull request Dec 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants