Skip to content

Commit

Permalink
added dependencies, updating razzle.extend.js
Browse files Browse the repository at this point in the history
  • Loading branch information
zotya committed Jun 3, 2022
1 parent 00eaaf6 commit 35bedb0
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
"plone",
"react"
],
"addons": [
"@eeacms/volto-eea-design-system"
],
"repository": {
"type": "git",
"url": "git@github.com:eea/volto-searchlib.git"
Expand All @@ -36,7 +39,8 @@
"react-masonry-component": "6.3.0",
"react-motion": "0.5.2",
"react-speech-recognition": "3.8.2",
"@eeacms/search": "0.2.3"
"@eeacms/search": "0.2.3",
"@eeacms/volto-eea-design-system": "0.3.1"
},
"devDependencies": {
"@cypress/code-coverage": "^3.9.5",
Expand Down
14 changes: 8 additions & 6 deletions razzle.extend.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@ const pkgs = ['@eeacms/search'];

const modify = (config, { target, dev }, webpack) => {
const projectRootPath = path.resolve('.');
return config;
const jsConfig = require(`${projectRootPath}/jsconfig.json`);
const searchlibConf = jsConfig.compilerOptions.paths.searchlib;
if (!searchlibConf) return config;

// return config;
// const jsConfig = require(`${projectRootPath}/jsconfig.json`);
// const searchlibConf = jsConfig.compilerOptions.paths.searchlib;
// if (!searchlibConf) return config;

// because we load @eeacms/search "through the back door" (via webpack
// aliases and jsconfig.json), we need to instruct babel to include this
Expand All @@ -19,9 +20,10 @@ const modify = (config, { target, dev }, webpack) => {
const { include } = babelLoader;

pkgs.forEach((name) => {
include.push(config.resolve.alias[name]);
incl = path.dirname(require.resolve(name));
include.push(incl)
});

console.log(config.module.rules[0])
return config;
};

Expand Down

0 comments on commit 35bedb0

Please sign in to comment.