Skip to content
This repository has been archived by the owner on Feb 15, 2023. It is now read-only.

Svelte default port conflict with ASP.NET Core default port. #181

Closed
Kuinox opened this issue Oct 29, 2020 · 4 comments · Fixed by #278
Closed

Svelte default port conflict with ASP.NET Core default port. #181

Kuinox opened this issue Oct 29, 2020 · 4 comments · Fixed by #278

Comments

@Kuinox
Copy link

Kuinox commented Oct 29, 2020

Is your feature request related to a problem? Please describe.
The problem is simple: out of the box, ASP.NET Core and Svelte both use port 5000.
This requires to configure one of them and it won't work out of the box.

Describe the solution you'd like
The solution is simple: the default should be something where it has less chance to conflict with a software used with svelte.

How important is this feature to you?
Not really important, I only want reduce friction in bootstraping a new app when you choose Svelte & ASP.NET Core.

@ceifa
Copy link

ceifa commented Oct 29, 2020

Maybe svelte should check if the port is taken, and if so, try to use the port 5001 and so on...

@Kuinox
Copy link
Author

Kuinox commented Oct 29, 2020

Taking a random port (which is current behavior) is better in case of conflict:
What if you start the svelte server before the ASP.NET Core server? Well, svelte will take the port 5000, but your front app is configured to hit... localhost:5000.

@antony
Copy link
Member

antony commented Oct 29, 2020

I'm confused by this issue - Svelte doesn't have a default port. Svelte is a compiler which produces Javascript and CSS. Did you mean to open this in one of the template apps? As far as I know they will all use an alternate port if the one they want is taken, and it's usually port 3000, not 5000.

@Kuinox
Copy link
Author

Kuinox commented Oct 29, 2020

Yes sorry, I just checked, the template use sirv which default to port 5000.

@Conduitry Conduitry transferred this issue from sveltejs/svelte Oct 29, 2020
lukeed added a commit that referenced this issue Dec 29, 2021
- Closes #181
- Closes #184
- Closes #277
Rich-Harris pushed a commit that referenced this issue Jan 6, 2022
* chore: bump `sirv-cli` version;

- Closes #181
- Closes #184
- Closes #277

* chore: update readme port
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants