@parameter1/base-cms-marko-web 3.14.0 → 3.17.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,16 +1,19 @@
1
1
  const loadWebsite = require('@parameter1/base-cms-web-common/website-context');
2
2
  const { asyncRoute } = require('@parameter1/base-cms-utils');
3
+ const { setDayjsLocale } = require('@parameter1/base-cms-dayjs/utils');
3
4
 
4
5
  module.exports = coreConfig => asyncRoute(async (req, res, next) => {
5
6
  const { apollo } = res.locals;
6
7
  const websiteContext = await loadWebsite(apollo);
7
8
  coreConfig.setWebsiteContext(websiteContext);
8
9
 
10
+ const locale = coreConfig.website('date.locale');
9
11
  // Set marko core date config.
10
12
  req.app.locals.markoCoreDate = {
11
13
  timezone: coreConfig.website('date.timezone'),
12
- locale: coreConfig.website('date.locale'),
14
+ locale,
13
15
  format: coreConfig.website('date.format'),
14
16
  };
17
+ setDayjsLocale({ locale });
15
18
  next();
16
19
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parameter1/base-cms-marko-web",
3
- "version": "3.14.0",
3
+ "version": "3.17.0",
4
4
  "description": "Core Marko+Express components for BaseCMS websites",
5
5
  "author": "Jacob Bare <jacob@parameter1.com>",
6
6
  "main": "index.js",
@@ -16,6 +16,7 @@
16
16
  "dependencies": {
17
17
  "@godaddy/terminus": "^4.9.0",
18
18
  "@parameter1/base-cms-apollo-ssr": "^3.0.0",
19
+ "@parameter1/base-cms-dayjs": "^3.17.0",
19
20
  "@parameter1/base-cms-embedded-media": "^3.13.5",
20
21
  "@parameter1/base-cms-express-apollo": "^3.0.0",
21
22
  "@parameter1/base-cms-graphql-fragment-types": "^3.0.0",
@@ -47,5 +48,5 @@
47
48
  "publishConfig": {
48
49
  "access": "public"
49
50
  },
50
- "gitHead": "b0dea489d56baebedbf0ef1cb2f48673a6928fcd"
51
+ "gitHead": "07197c04a5e52edebb39e58b8574451f1390b3b1"
51
52
  }