trailsjs / trailpack-hapi

:package: Hapi.js Trailpack
MIT License
19 stars 9 forks source link

Express similar #77

Closed weyj4 closed 8 years ago

weyj4 commented 8 years ago

This is an effort to make config uniform between trailpack-hapi and trailpack-express4. trailpack-express4 has the user declare static directory in app.config.main.paths, so we should do that here as well.

See this issue: 75

Also, we need to decide if the user must use path.resolve(...) to declare the static directory. It is required by trailpack-express4 currently: 10

weyj4 commented 8 years ago

It sounds like it's best to just change the trailpack-hapi config to conform to the path.resolve(...) form used by trailpack-express, so I did that.

Summary-from now on instead of declaring a static dir in config.web.assets, we need to add path.resolve(__dirname, '..', {your_static_dir}) to config.main.paths.www

weyj4 commented 8 years ago

Good idea! Added.

jaumard commented 8 years ago

Ready to merge when travis/eslint is happy ;)