Hello. I am attempting to set up a remote mySQL database (on Amazon RDS) to contain sensitive shop-dependent data such as SHOPIFY_API_KEY, SHOPIFY_API_SECRET, GraphQL’s adminAccessToken, GraphQL’s url Endpoint, as well as some of my own shop-dependent data, etc.
I can do the import and access the database just fine from the web/index.js file, BUT I cannot get beyond the import statement in my page code located in the web/frontend/pages directory.
The import statement is this:
import mysql from 'mysql2';
The error message I see in the chrome console when this statement exists is this:
TypeError: Cannot read properties of undefined (reading ‘NODE_DEBUG’)> at mysql2.js?t=1689528236624&v=ab90f474:13449:24> at Array.forEach (
Can anyone shed some light on this? Thanks so much!
Cheers jb