node.js - How do I access sails.services.*? -


i using sails.js in node app. sails of course globally available default. however, want services , models non-global peace of mind. set default booleans in globals.js false , trying access specific services per sails.js documentation (sails.services.*) should work since sails still global, keeps throwing reference error. ideas why is? have experience mucking around global.js in sails , can confirm of documentation of sails.js innacurate? starting lean towards conclusion. note: using sails.js version 11

if accesss service trough sails.services.xxx make sure letters lower case, example if have myservice.js @ services folder, can call myservice or sails.service.myservice.


Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

php - Best Light server (Linux + Web server + Database) for Raspberry Pi -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -