0f415144dc
Reorganize many root config parameters
2021-06-01 14:38:53 +02:00
7ccd335649
Move route building to common subproject, fix Time export
2021-06-01 14:34:10 +02:00
13bd933b0b
svelte: allow locals function calls with no parameter
2021-05-13 17:38:48 +02:00
c9fed2d873
Use maintenance component to throw 503s when some components are unavailable
2021-05-13 16:26:27 +02:00
a3ebf46b54
Add ApplicationComponent init lifecycle step and unstatic globals
...
This renames ApplicationComponent (previous) init to initRoutes and handle to handleRoutes
2021-05-13 16:03:59 +02:00
6aa37eb9e4
Add two step pre-compile/compile asset processing
...
Reorganize views into new "assets" folder structure
Turn locals into a store so locals don't have to be passed through files that don't need them
Some fixes to previous commit (esm) 82ab0b963c
Remove afs in favor of fs.promises (renamed afs.exists to Utils.doesFileExist
Rename Utils.readdirRecursively to Utils.listFilesRecursively
2021-05-04 17:14:32 +02:00
82ab0b963c
Switch to esm and add import auto format
2021-05-03 20:52:52 +02:00
05d112a3b3
Remove NunjucksComponent
2021-04-30 13:59:22 +02:00
05069b15d8
Properly use promises in ViewEngine.render(), use ViewEngine for mail and add NunjucksViewEngine
2021-04-28 17:02:49 +02:00
a7f421d2f8
Move request context locals definition to FrontendToolsComponent
2021-04-28 14:10:29 +02:00
c93ea7691e
ViewEngine: demote buildDir and publicDir fields
2021-04-28 14:09:02 +02:00
58ea522593
Reorganize config params and use view.cache for caching instead of view.dev
2021-04-27 15:08:41 +02:00
053313002c
Move svelte compilation to external rollup and add pre-compile-views cli
2021-04-23 15:56:39 +02:00
e5a9b9908d
Refactor and make it nicer codewise
2021-04-23 15:56:39 +02:00
29fa5f4e38
Make svelte work
2021-04-23 15:56:06 +02:00
5f0e11efed
Add svelte pre-compilation
2021-04-23 15:56:06 +02:00
4cbc73a25f
Fix ServeStaticDirectoryComponent while developping swaf
...
Also move core version detection to Application
2021-03-30 12:03:26 +02:00
aed825c4d6
FormHelperComponent: don't flash empty previous form data
2021-01-25 17:26:42 +01:00
5caa0be862
FormHelperComponent: add field ID prefix to prevent conflicts
...
Fixes #20
2021-01-25 17:26:42 +01:00
4745ae4e17
Fix session id not available in websocket listeners
...
Fixes #21
2021-01-25 16:36:15 +01:00
e4768141bc
Simplify RedirectBackComponent into PreviousUrlComponent
...
Closes #12
2021-01-24 22:42:20 +01:00
19c8b86ff8
Fix express body parsing middlewares corrupting AsyncLocalStorage
...
Closes #17
2021-01-24 16:35:33 +01:00
1b8ff1428f
Add persist session checkbox on login
...
Makes session not persistent by default
Closes #11
2021-01-24 16:33:33 +01:00
94cb157520
Remove connect-redis that breaks context with RedisStore
2021-01-22 15:55:06 +01:00
8fab93e709
Use AsyncLocalStorage to provide requestId context
2021-01-22 15:54:26 +01:00
2c66c66a39
logging: add status code description for redirections
2021-01-21 15:45:20 +01:00
87b4facea0
Upgrade dependencies and update to express session new typings
2020-12-04 15:24:22 +01:00
b75b227ca1
Add required username to magic link authentication and fix many errors
2020-11-14 17:24:57 +01:00
efdd81b650
Auth: refactor to support multiple auth factors and add password factor
2020-11-11 19:30:30 +01:00
1fce157104
logging: prevent full logging of errors for silent logs
2020-11-11 19:29:23 +01:00
f20da06d43
logging: also log ip address
2020-11-11 19:29:23 +01:00
a09e92dd96
logging: make silent errors actually silent
2020-11-04 12:52:07 +01:00
c966536950
NunjucksComponent: fix view loaders using cache when in dev env
2020-11-03 17:46:04 +01:00
4d0c714dbd
Render emails using NunjucksComponent's environment
2020-11-03 10:29:36 +01:00
88e5e19730
Replace custom logging system with tslog
2020-11-02 17:50:12 +01:00
93bff1fdca
Nunjucks/globals: fix route() context
2020-10-02 12:13:48 +02:00
f41a456524
Improve typing precision of CacheProvider.get()
2020-10-01 13:58:50 +02:00
79d704083a
Add many eslint rules and fix all linting issues
2020-09-28 14:15:22 +02:00
b736f5f6cb
Improve middleware definition and cleanup code
2020-09-25 22:15:57 +02:00
5dc0bd710a
Make nunjucks and static file server compatible with pkg
2020-09-24 22:42:55 +02:00
87aae6bb33
Fix some nunjucks globals not properly set and make getCSRFToken dynamic
2020-09-23 16:11:51 +02:00
47e0756930
Add websocketUrl view local
2020-09-23 12:31:19 +02:00
79d3b51f90
Pass a whole Session to WebSocketListeners
2020-09-23 08:55:35 +02:00
dfee2645e1
Express: add custom bind address setting
2020-09-17 21:15:37 +02:00
3af1f4a4e5
Parse json bodies for application/*+json too
2020-08-28 17:40:04 +02:00
25b1e71784
CSRFProtectionComponent: give more room for excluding requests
2020-08-28 16:52:49 +02:00
84f2f7118a
Csrf protection test: migrate to supertest
2020-08-05 12:06:21 +02:00
31f974c0a6
Serve static files extra early to avoid useless middlewares execution
2020-07-28 12:11:41 +02:00
3a4755ce98
Give the redirectBack function its own Component back
2020-07-28 10:03:25 +02:00
b179afdaf5
nunjucks: override default dump filter to allow circular dependencies
2020-07-26 11:37:36 +02:00