on the React Native app i have an server.js for mySql activities. And i want to import react-native-router-flux inside of this but i'm facing with: SyntaxError: Cannot use import statement outside a module
server.js
import { Actions } from 'react-native-router-flux';
const MySQLEvents = require('@rodrigogs/mysql-events');
const express = require('express');
const mysql = require('mysql');
let bodyParser = require('body-parser');
const program = async () => {
const dbConfig = {
host: '',
port: '',
user: '',
password: '',
database: ''
}
.
.
.
I've already used the solutions about this error in the internet. However i've got nothing to solve this.