I have an entry point class called app.js. This loads various classes. In one of these classes I delcare a constant:
class Product{
constructor(){
const height = 100;
....
How can I access this variable from other classes without having to import the product class into each class that I wish to access it in?
Alternatively if this is not possible with a const how can it be done? How can I declare a var in a child class of app.js and access it in another child class of app.js without importing the class in which the vairable was declared?