07-01-2020 07:19 AM
Hello,
I have created my custom library in ACA project (I used this version of ACA: alfresco-content-app-1.11.0.zip) by following this tutorial:
https://alfresco-content-app.netlify.app/#/extending/redistributable-libraries
In my library I have created a component and in this component I have imported and used some stuff from alfresco/aca-shared library like this:
07-01-2020 07:32 AM
Can you please provide some example project to reproduce the issue? You can either link the .zip (without ".git" and "node_modules" folders) or create a github repo with that? Thanks.
07-01-2020 09:32 AM
When I try to reproduce it on a new project I get a different error:
BUILD ERROR
Error during template compile of 'SharedStoreModule'
Function calls are not supported in decorators but 'EffectsModule' was called.
Here is the zip file with the clean aca 1.11.0 and custom extension which is giving me this error when I try to run this build script npm run build:my-extension
https://www.dropbox.com/s/nqijoc28yutas0g/alfresco-content-app-1.11.0.zip?dl=0
07-01-2020 10:39 AM
I am able to reproduce this issue. We will try to fix it soon.
07-30-2020 07:22 AM
I was also facing the same issue in the ACA 1.11.0 version project while building my custom extension which was having an import statement "@alfresco/aca-shared/store".
In ACA 1.11.0 "aca-shared" is available as an extension project inside the "projects" folder of the main project instead of npm dependency registered in package.json file. Since it is an extension project so it was having an entry in the "path" object in "tsconfig.json" of the main project, as follows:
"@alfresco/aca-shared": [
"projects/aca-shared/src/public-api.ts"
],
"@alfresco/aca-shared/store": [
"projects/aca-shared/store/src/public-api.ts"
],
"@alfresco/aca-shared/rules": [
"projects/aca-shared/rules/src/public-api.ts"
],
From the custom extension, I'll not have access to the specified static path, so I have removed the above 3 entries & added the following 2 entries of the "@alfresco/aca-shared" as follows:
"@alfresco/aca-shared": [ "dist/@alfresco/aca-shared" ], "@alfresco/aca-shared/*": [ "dist/@alfresco/aca-shared/*" ],
After the above change, I have tried to build my custom extension which was successfully built with the "@alfresco/aca-shared" import. I hope this maybe work in your case too.
Note: Since "@alfrescco/aca-shared" is an extension so must build it before building your extension so that inside dist it has the "@alfresco/aca-shared" folders with their respective built code ready to use in any extension project.
Explore our Alfresco products with the links below. Use labels to filter content by product module.