cannot install BrainJS on ubuntu 20.04

Viewed 64

I am trying to create a neural network using javascript. So, I found brain JS, and I'm following this tutorial.

https://github.com/BrainJS/brain.js#brainjs

First of all, the installation : npm install brain.js Then I change it to npm install brain So the errors are fixed.

Now I'm using visual studio and I tryed to run this first line but :

const brain = require('brain.js'); 

I got

Uncaught ReferenceError ReferenceError: brain is not defined
1 Answers
Related