gulpwebserverbrowser-syncgulp-browser-sync

local web server can't see folder on level up entry point


I have output folder structure as:

assets
 - images
views
 - index.html

Assets and Views are siblings and entry point of web-server (browser sync) is views folder, so if it's root, it can't see level up folders, how to resolve it? (Config or folder structure?)


Solution

  • Start your web server or gulp task one parent directory above where you are currently starting it. A web server cannot go above its current directory other wise it would have access to your full system