@pega/custom-dx-components 0.242.2 → 0.242.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
"@babel/preset-env": "^7.23.3",
|
|
91
91
|
"@babel/preset-react": "^7.23.3",
|
|
92
92
|
"@pega/configs": "^0.6.0",
|
|
93
|
-
"@pega/custom-dx-components": "0.242.
|
|
93
|
+
"@pega/custom-dx-components": "0.242.4",
|
|
94
94
|
"@pega/pcore-pconnect-typedefs": "2.0.0",
|
|
95
95
|
"@storybook/addon-actions": "^7.6.7",
|
|
96
96
|
"@storybook/addon-essentials": "^7.6.7",
|
package/src/util.js
CHANGED
|
@@ -108,7 +108,15 @@ export const getLibraryBased = async () => {
|
|
|
108
108
|
const currentDirectory = process.cwd();
|
|
109
109
|
const pegaConfigJsonPath = join(currentDirectory, TASKS_CONFIG_JSON_FILENAME);
|
|
110
110
|
|
|
111
|
-
|
|
111
|
+
try {
|
|
112
|
+
// force to throw error and not console log
|
|
113
|
+
await checkPathAccess(pegaConfigJsonPath, {}, true);
|
|
114
|
+
}
|
|
115
|
+
catch (ex) {
|
|
116
|
+
// when can't find it, always be false, assume no library based.
|
|
117
|
+
// This is IMPORTANT for init (npx install)
|
|
118
|
+
return false;
|
|
119
|
+
}
|
|
112
120
|
|
|
113
121
|
let data = fs.readFileSync(pegaConfigJsonPath, { encoding: 'utf8' });
|
|
114
122
|
data = JSON.parse(data);
|