简体   繁体   中英

Storing Node.JS files Within a Meteor.JS Project

I have a meteor.js project directory (created from meteor create projectName ) and I have some regular node.js .js files related to this site that only needs to be run using node fileName.js or using forver .

Is there a way to store these .js files within the Meteor project directory without it being auto-run (like how it will be executed if placed in the /server directory)?

And is it more advisable to place these .js files outside of the Meteor project directory?

Taking a look at the meteor documentation, you could probably use the private folder. This should stop auto-execution as well.

http://docs.meteor.com/#/full/structuringyourapp

private: All files inside a top-level directory called private are only accessible from server code and can be loaded via the Assets API. This can be used for private data files and any files that are in your project directory that you don't want to be accessible from the outside.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM