Home > OS >  Unexpected token 'react' when using react-moralis
Unexpected token 'react' when using react-moralis

Time:06-13

I was able to install the package for react-moralis without any issues. When trying to import from the package I receive an "unexpected token failed to compile" syntax error. The simple code is this

import { Moralis} from react-moralis

Failed to compile error

CodePudding user response:

Put it in quotes like this:

import { Moralis } from 'react-moralis'
  • Related