I have typed in ‘npm install’, I have typed ‘npm run webpack’ both have worked fine. But how do I then open the index file? it says follow these commands with ‘open index.html’.
This is not working… How do I view it? I can click on the file in my file explorer but this opens the HTML file not on the localhost.

How do I check that the SQL functions are working?

1 Like

This took me a while to figure out and there’s probably a better way.

In server.js, I added:
app.use(express.static('public'); //line 13 below the CORS expression

I then made a new folder called /public

Then I moved /build, /css, /img, index.html, and index.js into the /public folder.

Open the recently moved index.js and add a period to the app import so it goes up one level:

import App from '../App'; // replace line 3

Reload the server, open localhost:3001, and it worked!

1 Like

I have also found it easy to test queries out using the DB Browser. Just open the sqlite data file and test queries there before saving the code.