Questions tagged [lite-server]

Lightweight development only node server that serves a web app, opens it in the browser, refreshes when html or javascript change, injects CSS changes using sockets, and has a fallback page when a route is not found.

125 questions
1
vote
1 answer

Node lite-server: how to route a request to the contents of an arbitrary file

I have an SPA that requests data at a specific REST url, say, "/things". In my production server, this request is handled by a query to a database and the construction of JSON to represent the result. Nothing fancy. How would I configure lite-server…
1
vote
0 answers

websockets with lite-server and http-proxy-middleware

In my development environment I have to proxy requests as well as websocket connections to the respective backend service. For this I am using lite-server and http-proxy-middleware. My lite server config file looks like this: var proxyMiddleware =…
newBee
  • 1,289
  • 1
  • 14
  • 31
1
vote
0 answers

Angular 2 forms

I am developing an application in angular 2 + typeScript+ lite server.I found a very rare behavior of it.I had developed a web page which includes text box.If I hit the web page in 2 different browsers of 2 different machines, my web page pops up…
Pavan Jois
  • 31
  • 5
1
vote
0 answers

Config lite-server special structure angular 2

I have a problem to start and debug due solution structure (And I can't modify it)! Here is my structure: In the tsconfig.json is configured to transcompile all files to dist/out-tsc and all typescript and html files are in src/app, except…
colau
  • 31
  • 3
1
vote
1 answer

lite-server pathing for local development

as long as i keep everything in my rootfolder, leveraging tsc/npm scripts and lite-server with JIT compiling works perfectly fine i.e. project_folder bs-config.js index.html //with ref to src/ main.ts //main.js //main.js.map app/ …
longbow
  • 1,593
  • 1
  • 16
  • 39
1
vote
2 answers

How to properly configure multiple routes in lite-server

I'm using the lite-server to develop an Angular application. I have the following project structure, very simple: build/ foo/ index.html (references foo.js script) bar/ index.html (references bar.js…
Bernardo Pacheco
  • 1,445
  • 1
  • 14
  • 23
1
vote
1 answer

lite-server does not load scripts from parent directory in Angular 2 app

I am trying to run my application using the lite-server node package but it won't load scripts from the parent directory. I want my index.html in the /src folder because it could be possible in the future to generate a different file to /dist.…
oddRaven
  • 672
  • 1
  • 7
  • 20
1
vote
0 answers

Different root for Node lite-server than the folder holding package.json?

Node newbie. I want to have Node's lite-server use a parent folder of my app as the http root, so that my app code can be saved within a subfolder from the html: /index.html -- want lite-server to serve this /js/angularApp/package.json -- location…
Ted Fitzpatrick
  • 910
  • 1
  • 8
  • 18
1
vote
1 answer

grunt in watch mode and node.js lite-server

Is there a way to start node.js's lite-server from grunt? I have grunt in watch mode and to use both at the same time I need to open two command prompt (windows). I'd prefer to start both with one grunt command - if possible.
hholtij
  • 2,906
  • 6
  • 27
  • 42
1
vote
0 answers

Angular2 - How to configure for lite-server to use F5 (refresh page)?

I have a problem with lite-server when run with angular2. First, i run command: npm run lite It worked on browser default. Second, i click Address link and redirect to URL: base_ULR/address and i press F5 key. It worked, but now, root URL alway is…
Nguyen
  • 425
  • 8
  • 18
1
vote
2 answers

How to run angular 2 app in background

i have already tried following solution but it is not working. sudo forever start -c "npm start" ./ and package.json file is something like this, look at the start command: (this is not full package.json) "name": "angular2-quickstart", …
Vinay Pandya
  • 3,020
  • 2
  • 26
  • 42
1
vote
1 answer

404 not found when posting data with angular2

I am currently developing a web application with angular2. I followed the Tour of Heroes tutorial to get the basics. So, my local server setup and application architecture is the same one. I now need to perform a POST request to a static file. I…
1
vote
1 answer

Angular2 Quickstart lite-server crashes

Good Morning people from the Internet, Intro While following the Angular2 Quickstart guide I have experienced many times issues where lite-server would crash just after executing npm start. Crash would look like this in your terminal: ERR! Linux…
oscaroscar
  • 1,158
  • 11
  • 16
0
votes
1 answer

wrong url in request by refreshing page in SPA/page.js working on dev lite-server

I have SPA with page.js for routing running localy on a dev server. the DB sever is runned on http://localhost:3030 port dev server: http://localhost:3000 If initiate page with params in its url for first time there is no problem: borwser loads…
0
votes
1 answer

Live Server vs Lite Server

Just starting with JavaScript. Do I have to have Lite Server or can I use VS Code's Liveserver extension instead? Any research I've done on the topic leads into node.js, package.json, and NPMs which I don't understand. If Lite Server is needed, do…
1 2 3
8 9