Import modules from meteor still needed?


#1

Hi,

I just want to know if import of meteor sub-modules like below are still needed.
Can’t find a clear answer and it’s seems to me a little outdated.

Thanks.

import { Mongo } from 'meteor/mongo';
import { Meteor } from 'meteor/meteor';
import {Session} from 'meteor/session';
import {Template} from 'meteor/templating';

#2

Yes. I work with Meteor and React, I need to import all sub-modules before use them.


#3

I read somewhere that it is recommended to still do the imports as MDG might remove them as global variables in the future.


#4

No it is not needed.

These are considered pseudo-globals, which are both global and importable.
It’s recommended that you use import statements, but it is ultimately your choice