cds-snc / node-starter-app

Quick start application setup.... because you have to start somewhere.
MIT License
5 stars 3 forks source link

Simplify getViewData + getDefaultMiddleware #65

Closed timarney closed 4 years ago

timarney commented 4 years ago

Simplify getViewData + getDefaultMiddleware to remove the JS spread operator from the route code

You can now use

routeUtils.getViewData(req, customVars)

vs

 { ...routeUtils.getViewData(req), jsFiles }

and

routeUtils.getDefaultMiddleware({ schema: Schema, name: name })

vs

[ ...routeUtils.getDefaultMiddleware({ schema: Schema, name: name }) ]

Closes https://github.com/cds-snc/node-starter-app/issues/64

lgtm-com[bot] commented 4 years ago

This pull request introduces 1 alert when merging 7e355c04de50bafeeca590255ea03da35286dc16 into 354deca23518856d2a3b0c3942530c20d37f11eb - view on LGTM.com

new alerts: