Scatter fails at compile time in Angular project
See original GitHub issueI get the following error:
ERROR in ./node_modules/cipher-base/index.js
Module not found: Error: Can't resolve 'stream' in '/Users/mwawrusch/Dev/d1/node_modules/cipher-base'
ERROR in ./node_modules/hash-base/index.js
Module not found: Error: Can't resolve 'stream' in '/Users/mwawrusch/Dev/d1/node_modules/hash-base'
my versions:
"scatterjs-core": "2.7.7",
"scatterjs-plugin-eosjs2": "1.5.0",
"scatterjs-plugin-lynx": "1.5.0",
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:6 (2 by maintainers)
Top Results From Across the Web
Compiling Angular Libraries Properly in a Multi-Framework ...
In a nutshell, this is what causes the compiler error: at project compile time, the Angular compiler expects ngc -compiled JavaScript ...
Read more >Can I make the Angular Compiler throw an error when a non ...
It wont stop you from compiling but still show a error. TS Lint will validate method,property not found in the component.
Read more >Identify and Fix Build and Deployment Errors in Your Angular ...
In this guide, you will learn how to spot some of the most common build and deployment errors and how to resolve them...
Read more >Data visualization in Angular using D3.js - LogRocket Blog
Learn how to create bar charts, pie charts, and scatter plots in your Angular app using the data visualization library D3.js.
Read more >Ahead-of-time (AOT) compilation - Angular
There's no need to download the Angular compiler if the application is already compiled. The compiler is roughly half of Angular itself, so...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
For angular 6+ make sure to run npm i -D @babel/runtime
Create a patch.js file with the following: const fs = require(‘fs’); const f = ‘node_modules/@angular-devkit/build-angular/src/angular-cli-files/models/webpack-configs/browser.js’;
fs.readFile(f, ‘utf8’, function (err,data) { if (err) { return console.log(err); } let result = data.replace(/node: false/g, “node: {crypto: true, stream: true, fs: ‘empty’, net: ‘empty’}”);
fs.writeFile(f, result, ‘utf8’, function (err) { if (err) return console.log(err); }); });
Add to your package.json “scripts”: { “postinstall”: “node patch.js”,
Also, can you test without the lynx plugin? Perhaps there’s something in there which isn’t transpiling properly.