-
-
Save obonyojimmy/85f2dd9a1d9a7bee371f7bbcdca50b57 to your computer and use it in GitHub Desktop.
A Meteor function that returns the path of the provided package asset
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var getAssetPath = function getAssetPath(packageName, assetPath) { | |
assetPath = assetPath || ''; | |
var meteor_root = Npm.require('fs').realpathSync(process.cwd() + '/../'); | |
var assets_folder = meteor_root + '/server/assets/packages/'+packageName.replace(':','_')+'/'+assetPath; | |
return assets_folder; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment