2

I suppose my question is basic but I'm new to Node.js infrastructure and feel very confused.

I have a simple web-site where all my js files are bundled by webpack into bundle.js that is available by /static/bundle.js path (according to webpack configuration).

But now I have another folder with static data in the root of my project and I want to make it publicly available by /static2/... address. How can I do this? Who is responsible for that (webpack, nodejs, etc.)?

1 Answer 1

2

If you use express - you can take a look here:

http://expressjs.com/en/starter/static-files.html

For example:

app.use(express.static('public'));
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.