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

Major ?release? PITA #69

Closed
ghost opened this issue Jan 13, 2017 · 2 comments
Closed

Major ?release? PITA #69

ghost opened this issue Jan 13, 2017 · 2 comments

Comments

@ghost
Copy link

ghost commented Jan 13, 2017

Firstly, stoked for you guys to take the serve name space. As a long time user of npm serve, it's nice to see the package get some new owners and some new love.

That said, depending on async and await for this is a right pain in the ass for one major reason. You're forcing me to nvm use 7 everytime I want to use this library, which instead of meaning I can simply type cd blah/blah && serve I have to type cd blah/blah && nvm use 7 && serve. There in lies the PITA. Especially since most of my projects, and I have many (not publically on this github but on a private enterprise one) projects that are on LTS, switching is doable, but honestly a pain. I would hope you would consider potentially back porting if possible and if not, just supporting node LTS at the very most.

Phew I needed to say that. Now the important stuff.

Serving files like a webserver

I have an html page serving from a nested folder, and it references relative files that don't work.

An example

Html location: http://localhost:53058/some/folder
File location

<!doctype html>
<html>
  <head> <link rel="stylesheet" href="some.css" /> </head>
  <body />
</html>

The serve package currently tries to pull the file from http://localhost:53058/some/some.css, which is incorrect as my file is actually located in this location /some/folder/some.css.

I can work around this issue by appending an additional / to the url, e.g http://localhost:53058/some/folder/ and it fixes the issue but I would have expected this out of the box.

Recommendation

Update the route so that URL's are appended with / by default.

@ghost ghost changed the title Major ~~release~~ PITA Major ?release? PITA Jan 13, 2017
@leo
Copy link
Contributor

leo commented Jan 15, 2017

Works on Node LTS now. Please create a separate issue for the other problem (if still there)! 😊

@leo leo closed this as completed Jan 15, 2017
@ghost
Copy link
Author

ghost commented Jan 15, 2017

Thanks @leo that works on LTS now. I'll raise an issue for the other problem.

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

No branches or pull requests

1 participant