- Tailwind CSS
- PostCSS to handle SASS processing & CSS Autoprefixing
- PurgeCSS to purge unused css at build
- cssnano for minifying css
-
Moved output path for CSS & JS files. Before
/styles.css
after/dist/css/styles.css
-
Moved clientJsDir Before
/js/dist/
after/dist/js/
-
Webpack now handles CSS loading, extracting
-
Changed stylesheet entrypoint to
app.scss
which imports the default node-starter styles and tailwind -
Renamed the node-starter class
container
toouter-container
due to a conflict with tailwindcss -
Fixed the infinite loop issue #116
- sassMiddleware
normalize.css
(tailwindcss already includes it)
- Added webpack-cli
- Added
{ required: true }
for form inputs which adds * required to the field label fixes #98
- Moved cross env to be a dev dependency to fix Heroku deployment
- cross env for proper support of Node environment variables on Windows
- Support for localized routes using
route.draw(app).get(...)
- BREAKING:
route.path
now returns an object with.en
,.fr
, etc keys.
- BREAKING:
route.applySchema(schema)
is a middleware that does the schema-related parts of what was formerlydefaultMiddleware
.route.doRedirect()
is a middleware that will redirect to the next route in the correct localeroute.doRedirect((req, res) => routeOrName)
is a middleware that will compute the next redirect route, and redirect there in the correct locale.
Linting rules + include utils directory
Don't save redirect
or csrf
form data to session
Husky git hooks
Refactored the route helpers - we now pass a Route
object into the controller alongside the app
.
Additional properties added:
- route.name
- route.defaultMiddleware
- route.next
- route.prev
- route.get('personal').path
app
.get(route.path, (req, res) => {
res.render(route.name, routeUtils.getViewData(req))
})
.post(
route.path,
route.defaultMiddleware({ schema: Schema }),
)
- getPreviousRoute()
- getNextRoute()
- getNextRouteURL()
- getDefaultMiddleware()
- validateRouteData(req, schema) allows a route data to be validated from another route
- added getNextRouteURL helper to get next route with query params
- updated nextRoute redirect to include query params
- refactored the textInput and textArea macros with better defaults, simpler use
{{ textInput('fullname', 'form.fullname', { class: "w-3-4" }) }}
{{ textArea('address', 'form.address', { hint: 'form.address.desc' }) }}
- filter spreadParams for future use see: cds-snc#69