ng-packagr: 'deflate' is not exported by node_modules\pako\dist\pako_deflate.js
Type of Issue
[x] Support Request
Description
After running npm run packagr I get this error
PS C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter> npm run packagr
> eyc.control.grid-filter@2.0.0 packagr C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter
> ng-packagr -p ng-package.json
Building Angular library
Generating bundle for eyc.control.grid-filter
Cleaning bundle build directory
Processing assets
Running ngc
Compiling to FESM15
BUILD ERROR
'deflate' is not exported by node_modules\pako\dist\pako_deflate.js
Error: 'deflate' is not exported by node_modules\pako\dist\pako_deflate.js
at error (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:185:14)
at Module.error (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:16526:3)
at Module.trace (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:16623:10)
at ModuleScope.findVariable (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:13965:22)
at Node._bindVariableIfMissing (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:12626:31)
at Node.bindNode (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:12621:8)
at Node.bind (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:11005:8)
at eachChild.child (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:11024:34)
at keys.forEach.key (C:\Projects\EYC\SDK\Eyc.Sdk.Ui\eyc.control.grid-filter\node_modules\rollup\dist\rollup.js:11041:5)
at Array.forEach (<anonymous>)
Version Information
ng-packagr: v1.6.0
node: v8.7.0
@angular: v5.0.2
rxjs: 5.5.2
zone.js: 0.8.18
please include any version information that might be relevant, e.g. other third-party libraries
Is it a problem with pako package?
Thank you.
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 23 (8 by maintainers)
Thank you, but still the same problem. I’ve solved this by changing the library creation method. I’ve followed this tutorial (https://www.usefuldev.com/blog/post/publishing-a-library-from-an-angular-cli-project) and everything worked perfectly.
You also might need to change your import to be: